Late last month, a German convoy of 1,000 troops with tanks, drones and armored vehicles made its way some 750 miles to a Lithuanian military compound in Pabrade in three days, using trains, ferries, trucks and planes — all NATO practice for a possible incursion by foreign (read: Russian) troops.

The huge military exercise, integrating German and Lithuanian troops, began with reconnaissance and turned into a noisy, dusty battle that, not surprisingly, NATO won. Leopard tanks covered in camouflage raced back and forth in a haze of dirt, firing as they went; drones buzzed in the air; armored infantry vehicles spun through battlefield; soldiers covered with brush advanced slowly, weapons blazing.

The NATO exercise was meant to convince Lithuania and other countries bordering Russia that the promise of rapid reinforcement and collective defense was a reality. It was also intended to demonstrate the alliance’s new commitment to countering a more dangerous Russia, which argues that its war in Ukraine is a necessary response to what it considers NATO’s effort to dismantle Moscow’s sphere of influence.

As NATO leaders prepare to gather in nearby Vilnius, the Lithuanian capital, on Tuesday, the Baltic nations and the others on Europe’s eastern flank are feeling especially vulnerable.

In the early days of the Russian invasion of Ukraine, which began in February 2022, the Russians seized more territory than the entire country of Estonia, notes Juri Luik, Estonia’s ambassador to NATO and a former defense minister.

What happened on that territory, before Russian troops were forced to pull back, has become a symbol of wanton destruction and possible war crimes. Citing the devastation in the Ukrainian cities of Bucha, Irpin and Kherson, NATO’s frontline states have convinced allies that collective defense means vastly enhanced deterrence.

The military alliance is responding, developing detailed war plans and a commitment of troops, equipment and money not seen since the end of the Cold War. Political approval of those plans is at the center of the annual summit meeting.

While political language about Ukraine’s future relationship with the alliance and the practical military help promised in the current conflict are likely to dominate coverage, NATO’s main task is to defend its 31 members.

Speaking in Pabrade alongside the Lithuanian president and German defense minister, the NATO secretary general, Jens Stoltenberg, insisted that NATO was a purely defensive alliance, but with a sharper sense of the threat it faced.

“This exercise sends a clear message: NATO is ready to defend every inch of allied territory,” he said, adding, “We are demonstrating that we can also reinforce quickly, whenever needed.”

As it evolves strategically and operationally, NATO is moving to what the military calls “deterrence by denial,” which in practical terms means more troops along the Russian border.

At the moment, the total number of troops for the eight battle groups along the eastern flank is only 10,232, NATO says. The leaders at Vilnius are expected to approve plans on how to scale up to 4,000 to 5,000 troops — a brigade — in each of those eight countries, with clearly defined tasks and pre-positioned equipment.

Separately, since the Russian invasion began, around 40,000 troops drawn from member nations were put on standby under NATO command, but officials admit that the forces it can quickly send to battle are currently nowhere near that level. Under its new plans, NATO aims, at least, to have up to 300,000 troops ready to move to its eastern flank within 30 days, though officials call that number “aspirational.”

The main point, Mr. Stoltenberg said, is that the new regional plans detail what each country must do to help defend its assigned territory, and with what equipment. Those troops will exercise regularly with allies on the territory they are assigned to defend.

NATO also plans to transition from the kind of air policing now done over the Baltics to keep an eye on Russian warplanes to active air defense. And NATO is coming to understand the sophistication and the vulnerability of its modern equipment.

A modern Leopard 2A6 tank, the best of those provided to Ukraine, has excellent speed and armor and runs on most any fuel. But it needs two hours of complicated maintenance for every hour on the battlefield, said Captain Moritz, who commands one but was not allowed to divulge his surname as per NATO rules.

As NATO changes, Adm. Rob Bauer, the chairman of NATO’s Military Committee, was blunt about what needed to be done. “We have to go and do our work to reach the higher number of forces with a higher readiness,” he said. “We need to exercise against the plans. We need to buy the capabilities that we require.”

“It is not a switch,” he added. “That will take a considerable number of years to get there.”

It will also take convincing the leaders and voters of larger allies farther away from Russia that their own security is at risk, and that they are going to have to pay the considerable price of a more militarized Europe for decades to come. And that means being truly prepared to come to the aid of smaller countries bordering Russia, like Lithuania, while rebuilding their weak militaries and learning to rely less on the United States.

For Lithuania, a country of 2.7 million people that borders Russia and Belarus, getting Germany to commit to permanently stationing a brigade inside its borders became a domestic political issue. But Lithuania is not ready to host a brigade, and after this exercise, the Germans took their troops and equipment back home.

Still, at Pabrade, Germany’s defense minister, Boris Pistorius, promised to station a brigade of 4,000 troops in the country — once Lithuania constructed the necessary infrastructure, including housing, schools and warehouses for ammunition and vehicles.

“Germany used to be NATO’s eastern flank, and we could always rely on our NATO allies,” he said. Three decades later, “the eastern flank is the Baltics, Poland, Slovakia.”

As the largest economy in Europe and a vital member of NATO, Mr. Pistorius said, “Germany, of course, is willing and will be able to take responsibility now for the new eastern flank.”

Lithuania’s president, Gitanas Nauseda, praised the German decision and said his country had started building for the brigade and hoped to finish by 2025 or 2026. “The alliance is as strong as its most exposed spots,” he said.

Lithuania now spends 2.5 percent of its gross domestic product on defense, above the NATO target, and is working to increase its own active-duty forces in the next seven years to one division of 17,000 to 18,000 troops.

NATO supports Germany’s decision for a brigade in Lithuania, Admiral Bauer said. But he added that most allies would continue to plan for rapid deployment of more forces in a crisis rather than stationing them permanently at the front, partly because of expense and partly out of caution — a war could start with troops in the wrong place, and massed troops could be exposed to a first attack.

Despite all of the reassurances, the Balts feel vulnerable, given their size and their neighbor. And they feel that their past warnings about the imperial intentions of President Vladimir V. Putin of Russia were played down by larger, more distant allies, like Germany. One of those most outspoken early about the Russian threat and NATO complacency was the former president of Lithuania, Dalia Grybauskaite.

So it was a strong and symbolic gesture that after the exercise, Mr. Pistorius presented a special award named after Manfred Wörner, the only German to be secretary general of NATO, to Ms. Grybauskaite.

Known for outspokenness, Ms. Grybauskaite did not disappoint in her acceptance speech. Her warnings about Russian revanchism had gone largely unheeded, even after the annexation of Crimea in 2014, she said.

“We tried to warn our allies about Russia,” she said. “People listened, but they did not hear.”

Perhaps now they will hear, Ms. Grybauskaite said, urging the rapid integration of Ukraine into NATO as a full member.

“We must not wait until the end of the war,” she said. “If we declare Ukraine must not be a member until the end of the war, the war will never end.”