Suicide attackers have targeted Afghan military bases in two cities, leaving 13 members of the security forces dead, along with at least five assailants.
In the northern city of Kunduz, suicide bombers stormed an army recruitment centre, sparking a long gun battle.
On the outskirts of Kabul, attackers ambushed an army bus outside the country's main recruitment centre.
The Taliban claimed responsibility for the attacks, which President Hamid Karzai called "criminal".
Correspondents say the attacks were clearly aimed at deterring Afghans from joining the huge drive currently under way to build up the domestic security forces.
The recruitment centre in Kunduz came under attack from at least four suicide bombers - who early reports suggested were dressed in army uniforms, AP news agency quoted the provincial deputy governor Hamdullah Danishi as saying.
Foreign and Afghan soldiers surrounded the building, in which about 100 people were trapped.
"There are gun shots, heavy machine gun fire and RPGs [rocket-propelled grenades]," a local trader told the BBC. He said the base was on fire.
Local police sources say that five Afghan soldiers and three policemen were killed, along with at least three of the attackers. About 20 recent army recruits were wounded.
"The enemy came prepared,'' the police chief of Kunduz province, Mawlana Sayed Khel, told the BBC.
In Kabul the attackers opened fire on a bus filled with Afghan army soldiers.
Security forces at a nearby checkpoint opened fire on the attackers. One was shot dead.
But a suicide bomber then detonated explosives, killing five soldiers.
The assault took place outside the Kabul military training centre on the outskirts of the city - the country's main base for the training of recruits.
The "criminal" attacks were carried out by "the enemies of the Afghan people", said President Karzai in a statement.
In another incident, a Nato service member was killed in southern Afghanistan, the international force said, without providing more details.
The recruitment centre in Kunduz is situated in the heart of the city, about 100m (330 feet) from the police chief's office and key government buildings.
Questions will be asked as to how the attackers managed to get past many police checkpoints on the outskirts of the city, says the BBC's Bilal Sarwary in Kabul.
"The police must have been asleep," Haji Bahadur Shah, a shopkeeper in Kundoz city, told the BBC.
"How did Taliban attackers on motorbikes manage to get into the heart of the city? This is not a remote district. This is 100m from the police chief's office. The government should get serious.''
Kunduz, once a relatively quiet part of the country, is becoming much more unstable.
Afghan and American forces have killed dozen of Taliban commanders in recent weeks in the province.
German Chancellor Angela Merkel visited Kunduz on Saturday, to see German troops who have a base there.
Her visit was referred to by Taliban spokesman Zaibullah Mujahid as he claimed Taliban militants were behind the attack.
"The purpose of her trip was to give morale to her soldiers. But today the successful attack is shaking the hearts of the occupation soldiers," Mr Mujahid said, according to AP news agency.
Correspondents say the attacks aim to disrupt a huge recruitment effort in the Afghan security forces, which now number some 250,000.