Tajikistan's relations with the new Taliban leadership in Kabul have been strained from the start and reports of troop build-up on both sides of the border have alarmed Moscow, which operates a military base in the former Soviet republic.
The exercise, carried out by the Collective Security Treaty Organisation (CSTO), which also includes Belarus, Armenia, Kazakhstan, and Kyrgyzstan, involved more than 4,000 troops as well as tanks, artillery and assault aircraft.
CSTO Secretary General Stanislav Zas said the war games were aimed at showing "that no incursions into Tajikistan's territory will be allowed," adding "we will not leave Tajikistan alone in the face of danger."
Millions of Tajiks live in Afghanistan, comprising its second largest ethnic group, and Tajikistan's President Emomali Rakhmon has criticized the predominantly Pashtun Taliban for failing to set up an ethnically diverse cabinet.
The Taliban has forged an alliance with an ethnic Tajik militant group seeking to overthrow Rakhmon, according to Russian media reports.