A man in an Afghan army uniform turned his weapon on American trainers working with him in the country's east, killing three of them, while an attacker with a grenade killed an Italian soldier in the west.
The shooting in Paktika province was the latest in a string of so-called insider attacks in which Afghan forces open fire on their own comrades or international troops.
The incidents threaten to shake the confidence and trust of the two sides as the 2014 withdrawal of most of the international forces approaches.
An argument between the Afghan soldier and his trainers appeared to have led to Saturday's shooting on an Afghan National Army base in Paktika's Kher Qot district, according to a statement from the provincial governor's office.
The international military coalition in Afghanistan said two American service members and one US civilian died.
The angry Afghan soldier opened fire during the argument, killing the three foreign trainers and wounding three others, according to the governor's statement. The foreigners returned fire and killed the Afghan soldier, who had no known connection to the insurgency.
So far this year, there have been five insider attacks on foreign forces, with a total of eight troops and one US contractor killed. However, the number of such attacks has eased after soaring last year - in 2012, there were at least 29 insider attacks, killing 62 international troops.
Afghan security forces are also targets of such attacks. Last month, two recently rehired Afghan police opened fire on their commander at a checkpoint in a remote district in the country's south, killing him and six of his men.
The Taliban insurgents claim most of the insider attacks, saying they have infiltrated Afghan security forces or persuaded soldiers and police to join their side. However, the international coalition has said many of them are sparked by personal disputes.
In the western province of Farah, meanwhile, an Italian soldier was killed and three others wounded in a grenade attack on their armoured vehicle in western Afghanistan. The Italian Defence Ministry said the attack in Farah province came as the Italian soldiers were returning to their base from training Afghan security forces.