The Faina, with a crew of 17 Ukrainians, three Russians and one Latvian, was hijacked off the Horn of Africa on September 25, 2008. The vessel's Russian captain died of a heart attack soon after the hijacking.
All 65 pirates that had been on board the hijacked vessel left on Thursday having divvied up the $3.2 million ransom. The pirates initially demanded a $35 million ransom for the vessel, which was carrying 33 T-72 tanks and other heavy weaponry.
Spokeswoman Irina Vannikova also said President Viktor Yushchenko intends to personally meet the crew of the released vessel.
The Faina is expected to arrive in the Kenyan port of Mombasa next week.
According to the UN, Somali pirates carried out at least 120 attacks on ships in 2008, resulting in a yield of around $150 million.
Around 20 warships from the navies of at least 10 countries, including Russia, are involved in anti-piracy operations off Somalia. The East African country, ravaged by years of civil war, has no functioning government.