Mogadishu is the capital and largest city of Somalia on the Indian Ocean, with about 2.1 million people. An ancient East African trading port, it has suffered from years of civil war and attacks by al-Shabaab.