(CNN): Iraqi Prime Minister Nuri al-Maliki urged parliament to declare a state of emergency Tuesday, hours after police said militants seized control of portions of Iraq's second-largest city, Mosul, and freed up to 1,000 prisoners.
Authorities said the militants were also in control of the Mosul airport, local TV stations and the governor's offices.
The gunmen are believed to be members of the extremist group the Islamic State in Iraq and Syria, an al Qaeda splinter group also known by its acronym ISIS. Many foreign fighters are believed to be among their number, senior police officials said.
In a live national address that aired on Iraqi state television, al-Maliki described the Mosul unrest as a dangerous security situation requiring immediate measures to protect civilians.
Gunman seize Iraqi university
Iraq violence leaves more than 100 dead He announced a "maximum alert," calling for all state resources to be mobilized against the fight against terrorism, and asked all men to volunteer to join the army.
"This requires all efforts, both civilian and official, to confront this ferocious attack that harms all Iraqis, from a deteriorating security situation to a humanitarian crisis," he said.
He also urged the international community, the United Nations and the Arab League to support Iraq in the fight against terror.
Speaker points finger at security forces
Earlier, the speaker of Iraq's parliament said that a "foreign invasion" of the country was under way by "terrorist groups" and that the northern province of Nineveh, of which Mosul is the capital, was under "total occupation."
Speaking at a news conference in Baghdad, Osama al-Nujaifi appeared to point the finger at the central government, accusing security forces of abandoning Mosul when the fighting began.
Al-Nujaifi said security forces "abandoned their weapons, their tanks and their bases and left them to terrorist groups, even Mosul airport." He also said gunmen had taken over ammunition storage facilities.
The speaker, whose brother Atheel al-Nujaifi is the governor of Nineveh province, said the central government had been warned over the past few weeks that militant groups were gathering but had taken no preventive action.
"The presence of these terrorists in the second-biggest province in Iraq threatens not only the security and unity of Iraq but all of the Mideast region and neighboring countries," he said.
"It will not stop at the borders of Nineveh but will reach all of Iraq."
Militant stronghold
The latest violence in Mosul, a predominantly Sunni city about 560 kilometers (350 miles) northwest of the capital, Baghdad, will surely be a blow to central authorities, who already are struggling to contain an insurgency in central Anbar province.
Mosul was called the last stronghold of al Qaeda in Iraq by the U.S. military and also is considered one of the main entry points for foreign fighters coming into the country by way of Syria.
Iraqi security forces said Saturday that they had killed more than 50 ISIS fighters in clashes in the west of the city.
Meanwhile, at least 31 people were killed and 28 others injured Tuesday when a series of roadside bombs detonated at a cemetery on the outskirts of the central city of Baquba, according to police officials.
Iraq has been beset with political and sectarian violence for months, often pitting Sunnis -- a minority in Iraq -- against Shiite Muslims, who came to dominate the government after Iraqi leader Saddam Hussein was overthrown in 2003.
Tensions are fueled by widespread discontent among the Sunnis, who say they are marginalized by the Shiite-led government and unfairly targeted by heavy-handed security tactics.
The United Nations said 2013 was the deadliest year in Iraq since 2008, with more than 8,800 people killed, most of them civilians.
Nearly 500,000 people are estimated to have been displaced this year in fighting, primarily in the Sunni-dominated Anbar province, the United Nations refugee agency said last week. That number is expected to climb.