<P> Although Libya was not as firm a Soviet ally as many Third World Marxist regimes were, Moscow developed close ties with the anti-Western regime of Qadhafi, who had overthrown Libya's pro-Western monarchy in 1969 . The number - two Soviet leader at that time, Alexei Kosygin, went to Libya in 1975, and Qadhafi visited Moscow in 1976, 1981 and 1985 . Soviet - Libyan trade volume during the 1970s and 1980s was approximately $100 million per year and relations between the two accelerated between the years 1981 and 1982 . During this period, Moscow also supplied $4.6 billion in weaponry to Libya, providing about 90 percent of that country's arms inventory, and the Gaddafi regime assisted the Soviet Union by playing a key role in preserving the Communist regimes in both Angola and Ethiopia . According to Kommersant, "Libya was one of the Soviet Union's few partners that paid in full for the military equipment it purchased from the USSR," though the Gaddafi regime still maintained good relations with the Western nations of France and Italy and refused to sign a Treaty of Friendship and Cooperation with the Soviet Union . Libya, however, did run up a debt to Moscow during those years . </P> <P> Throughout much of the Cold War, Syria and Iraq were each ruled by rival fractions of the pan-Arab Baath Party and the two nations were often tense towards one another despite their close relations with the Soviet Union . Their relationship, which had been lukewarm at best since 1963, started to change in a dramatic fashion when Mohammad Reza Pahlavi, the Shah of Iran, was overthrown in February 1979 and replaced with the pro-Islamist regime of Ayatollah Ruhollah Khomeini . After seizing power, Khomeini established a system of laws which required the mostly Shiite population of Iran to follow strict adherence to the Twelver school of thought . Assad, himself a Shiite, soon formed a strong alliance with Iran and sought to use this new relationship to greatly weaken Iraq . On July 16, 1979, Ahmed Hassan al Bakr, who had ruled Iraq following a coup in 1968, stepped down from power and appointed his cousin Saddam Hussein, a strongly anti-Shiite Sunni, to be his successor and the Syrian government officially closed its embassy in Baghdad soon afterwards . In 1980, relations between Iraq and Syria officially broke apart when Syria declared its support for Iran during the Iran--Iraq War and Hussein, hoping to gain the advantage over Iran, expanded relations with the Western nations and recanted Iraq's previous position towards Israel . </P> <P> In December 1979, relations between the Soviet Union and Iraq, though still very strong in private, soured greatly in public when Iraq condemned the Soviets' invasion of Afghanistan . After Iraq invaded Iran in September 1980, the Soviet Union, hoping to make Iran a new ally, cut off arms shipments to Iraq (and to Iran) as part of its efforts to induce a cease - fire . However, it also allowed Syria to continue to back Iran and ship Libyan and Eastern Bloc weapons to the country as well . While Khomeini was strongly anti-American and had demonstrated this sentiment by calling United States "the Great Satan" and taking US embassy workers hostage, he also strongly opposed the Soviet Union, labeling the Communist belief a threat to Islam; and efforts by the Soviets to make Iran an ally further soured when Khomeini openly declared support the Afghan Mujahideen during the Soviet--Afghan War and refused to crack down on pro-Afghan protesters who consistently attacked the USSR embassy in Tehran . In 1982, when it became clear that Iran would not align with the USSR after the Khomeini regime gained the upper hand in the Iran--Iraq War and invaded Iraqi territory, the Soviets resumed regular arm shipments to Iraq, but relations between the two nations were still politically strained and would not become strong in public again until early 1988 . </P> <P> After 1966, a large Soviet military presence developed in Syria . Syria eventually became the Soviet military's most favored client not only in the Middle East, but throughout the Third World as well . By mid-1984, there were an estimated 13,000 Soviet and East European advisers in Syria . Though relations still remained strong, the Soviets' stance towards Syria's support for Iran changed dramatically when Iran further advanced into Iraqi territory and drew strong ire from the Soviets as it continued to suppress members of the pro-communist Tudeh Party of Iran . As a result, many of the advisers were withdrawn in 1985 and between 2,000 and 5,000 remained by 1986 . In February 1986, Iran successfully captured the Al - Faw Peninsula and the Soviet Union's stance in the Iran--Iraq War completely shifted towards Iraq . </P>

Who did the ussr support in the cold war