The Soviet Union placed 350 missiles in Eastern Europe and invaded Afghanistan. They installed a new dictator as President of Afghanistan. Early in 1980, the Soviet Union escalated this war. In spite of this, the Afghan rebels still controlled most of the country. From 1980 to 1988, a vicious war followed there, creating an enormous refugee problem for neighbouring states. Finally, by 1988, the Soviets agreed to withdraw from Afghanistan, due to the problems they were having at home.