From a military point of view, needed in Somalia and the surrounding states affected by Al-Shabab and Al-Qaeda is a highly coordinate and concentrated initiative to scrub the country of terrorists. That would require a door-to-door, neighborhood-by-neighborhood effort to squeeze them into visible targets for elimination. The strategy may well require the Lawrence of Arabia approach of taking no prisoners.
From a US foreign policy perspective, this requires continued support from air intelligence and drone strikes in support of an African-led ground coalition.
From a US and free-world diplomatic point of view, needed is to assist Somalia and affected nations and regions with aid to produce sustainable local economies complete with democratically elected governments with police and military security.
There is an excellent Fox News report this morning describing “10 things to know about al-Shabab”: http://www.foxnews.com/world/2013/09/22/10-things-to-know-about-al-shabab/
“Al-Shabab is inspired by the Saudi Arabian Wahabi version of Islam though most Somalis belong to the more moderate Sufi strain. While they initially won popularity with Somalis by promising security and stability after years of lawlessness and violence, al-Shabab's destruction of Sufi shrines has cost them much support among locals.”
“ It is a religious movement among fundamentalist Islamic believers, with an aspiration to return to the earliest fundamental Islamic sources of the Quran and Hadith, with inspiration from the teachings of Medieval theologian Ibn Taymiyyah and early jurist Ahmad ibn Hanbal.”
The root of the problem is radical Islam.