(CNN) -- Thousands of people were protesting Tuesday outside the Romanian Parliament against an unpopular austerity plan presented by the government, the Romanian Interior Ministry said.

Organizers and local police said there were about 5,000 people in front of Parliament. Romanian national police told CNN the crowd burned effigies of government ministers and that a crew of firemen had to put out the fire.

Some 1,000 Romanian policemen were trying to keep the protesters from entering the building, the ministry said.

The center-right Romanian government survived a confidence vote Tuesday in relation to the austerity measures by 8 votes, the Agerpress national news agency reported.

CNN's Laura Perez-Maestro in London, England, contributed to this report.