The snap election was called by Prime Minister Alexis Tsipras as he stepped down following a referendum opposing an EU bailout plan his government had negotiated.
More than 6,000 so far have entered the Balkan nation from neighboring Serbia after Hungary cracked down at its border, erecting a fence and turning back refugees with tear gas and water cannons.
Hours before a Tuesday deadline, Hungarian soldiers and police formed a human chain to prevent refugees from crossing, as they erected a fence along their southern border with Serbia.
Interior Minister Thomas de Maiziere said trains between Austria and Germany would be suspended for 12 hours "to return to orderly procedures" for entering the country.
So far in 2015, more than 200,000 people have reached Greece and another 100,000 reached Italy, the U.N. says. Germany expects as many as 800,000 new arrivals this year.
Groups of the refugees earlier had left a rail station and stopped train and begun walking toward Austria. Also: The father of a 3-year-old Syrian boy who drowned in the Aegean Sea buries his family.