Militia commander Yuri Bereza and his 150 Ukrainian irregulars were closing in on pro-Moscow separatists in their last stronghold in this eastern city when Russian troops and armor thundered in out of nowhere to cut them off in the suburb of Ilovaisk.
No satellite or drone surveillance detected the sudden movement of the Russian columns. No word of the impending attack had been radioed from the border guard base the invaders had to have passed. Neither did any of the allied soldiers who were supposed to be bringing up the rear inform Bereza's fighters that they had been cut off. In fact, the 700-strong contingent of government recruits had deserted en masse.
The unit's calls to Kiev, the Ukrainian capital, to say it was surrounded brought promises of a reinforcements, food and ammunition, none of which came to the rescue of the men, who survived on grass and rainwater as they braved five days of incessant sniper fire, "like game at a hunting range," Bereza said bitterly of the battle two months ago.
It was at Ilovaisk, where 107 irregulars died and at least 700 recruits and volunteers were taken captive, that the Ukrainian military's post-independence disintegration was most painfully on display.
A standing army of 1 million inherited by Ukraine after the 1991 breakup of the Soviet Union has dwindled to barely 100,000. Analysts say even that figure is inflated. At the time the Russia-backed separatists began grabbing territory in March, then-Defense Minister Ihor Tenyukh told the parliament that Ukraine had no more than 6,000 combat-ready troops to repel the aggression.
The Ukraine contingent of the once-fearsome Soviet Red Army rotted from the top after independence, when senior posts became cushy rewards for political supporters of the ruling party. Since the overthrow of Kremlin-allied President Viktor Yanukovich in February, the military leadership has been a revolving door. The fourth defense minister in eight months, Stepan Poltorak, was appointed by President Petro Poroshenko this week and confirmed Tuesday.
Defense funding has declined to a fraction of its Soviet-era support. Ukraine last year allocated $1.9 billion for the armed forces, Defense Ministry figures show, only 10% of it earmarked for modernizing training and weapons. Russia, by contrast, spent $4.47 billion and has a standing force and conscription-age population three times larger than Ukraine's, the CIA World Factbook estimates.
Ukraine's last significant military exercises took place nine years ago, said Ihor Smeshko, former security services chief and now head of Poroshenko's intelligence committee.
Not a single new combat aircraft has been commissioned since independence, and the country's air power has shrunk to about three dozen fighter jets and a diminishing fleet of antiquated helicopters from the 1,500 acquired with the Soviet breakup, said Yuri Biryukov, a presidential aide in charge of fund-raising for militias.
But perhaps the most serious blunder, analysts say, was the failure of successive Ukrainian leaders to see their Russian neighbors as a potential threat.
"As the army shrank rapidly over the years, everybody thought it was such a good thing," Biryukov recalled. "They thought, 'Who could threaten us if our friends and allies are Russia, the United States and Europe?'"
Some of the erosion of defenses has been by design. Ukraine's share of the Soviet nuclear stockpile, nearly 1,300 intercontinental ballistic missiles, was handed over to Russia for dismantling in 1994 when Kiev signed the Nuclear Nonproliferation Treaty. In exchange, Russia, the United States and Britain pledged to respect Ukraine's borders.
Russian President Vladimir Putin violated that agreement when he launched his campaign of territorial plunder in February by first seizing Ukraine's Crimea region. But more than two decades of corruption, misguided strategy and squandered resources had left Ukraine woefully unable to respond when Russian brothers turned hostile.
"We should have fought this war from Day 1 in Crimea," said Maxim Dubovsky, deputy commander of the Dnipro-1 regiment humiliated in Ilovaisk. Russia's seizure of the peninsula, home to its Black Sea fleet, robbed Ukraine of its own naval bases.
Ukraine's abysmal economy has led to deep cuts in weapons production, which was the lifeblood of the eastern regions, feeding the unemployment and discontent there that led to the current conflict. What is still produced is usually sold to other countries, including Russia.
Even if Kiev's Western allies were to provide more sophisticated weaponry to Ukraine, which isn't a member of the North Atlantic Treaty Organization and thus not entitled to the bloc's protection, the armaments couldn't be integrated into Ukraine's obsolete, Soviet-designed arsenals and fleets without massive and costly retrofitting, said Vladimir Grek, a former Defense Ministry weapons designer.
Ukraine needs to invest at least $5 billion a year to upgrade its defenses, Grek said. "We need to put our military industrial complex in war mode, with 24-hour-a-day production so that we can get new weapons to the army as soon as possible."
The regular army's deterioration has given rise to an array of volunteer units. Some, like Bereza's regiment, coordinate with commanders in Kiev, gaining access to the army's tanks and artillery. Others, like the rogue nationalist Right Sector militia, are fighting for their own agenda, often with brutality that gives credence to Moscow's claims that Ukraine is awash with "neo-fascists."
Underarmed and underfed, Ukrainian troops have fled some battles before shots were fired, as in the Sector D retreat at Ilovaisk. Another army unit camped near the remote border with Russia along the Sea of Azov fled in late August when two armored columns burst through a checkpoint and overran the town of Novoazovsk.
"We don't have hot food. We eat dry rations, and when they run out we start looking for something in the fields," said Ondriy, a 21-year-old soldier on leave in Kiev who didn't want to give his last name for fear of retribution for complaining. He said his commander had advised him when he left on furlough not to come back, that there was "no point in dying for a country that doesn't care for you."
Ukrainians far from the war zones acknowledge that the conflict doesn't seem real to them. In Kiev, there is little evidence of a war an hour's flight east. Political ads for the Oct. 26 parliamentary elections dominate billboards and television talk shows, and few without family members at the front seem willing to let the war intrude on their worries.
"Our best and bravest young men die every day in eastern Ukraine and I am already wondering whether they should really stay there and fight," said Anzhella Polovinko, 43, a Kiev clothing designer.
Though the sorry state of the military is dispiriting for many, Ukrainian officials say they have the advantage of soldiers and volunteers more committed than their adversaries to a fight for the country's very existence.
Hundreds of Russian soldiers have been killed in Ukraine on missions the Kremlin denies any role in, and their returning coffins have been "an icy shower for their mothers and many of those who used to support Putin's policy toward Ukraine," said Andriy Parubiy, former secretary of the National Security and Defense Council and now head of a Kiev agency coordinating support for volunteer militias.
Putin was able to score successes against troops loyal to the Kiev government when he had 40,000 Russian soldiers on Ukraine's border, Parubiy said. "The deeper Putin pushes into Ukraine, the harder it will be for him to count on his supremacy in arms, technology and manpower, while the Ukrainian people will all rise like one to defend their motherland."
But the brave and patriotic are finite in number. Fighters like Volodymyr Tugai, a 38-year-old former paratrooper who battled alongside Bereza at Ilovaisk, said he feels betrayed but he doesn't know by whom.
Tugai, who was bleeding from a shrapnel wound to his neck during the mid-August battle, later recalled a young soldier with one of his legs blown off reaching for him in the bed of a pickup truck serving as a first-aid station.
"He was screaming, 'Mama! Mama! Mama! Help please! Take me home!' " said Tugai, still emotionally numbed by the desperate soldier's cries. "I wished I could be his mother there and then. But he was gone in a minute."
Loiko reported from Donetsk and Williams from Kiev.