How To Restore The Original Panel And Menu Bar in Ubuntu

New Solution

Note: The old solution no longer worked for me, I found a new solution and posted it here.

Open Terminal: Ctrl+Shift+T

Execute these three commands:

gconftool-2 --shutdown
rm -rf ~/.gconf/apps/panel
pkill gnome-panel

The panels should reappear without logging out.

Old Solution

Note: This no longer works for me, but I leave it here for those who would like to try. After all, this solution saved me once, and it once worked just fine.

Well, I deleted my top panel by accident today. When I create a new one, some of the original items such as wire network connection, PMC volume control, notification area, date and time… are not there any more. Some of them are no where to be found in the items listed for adding new items onto panels. Anyhow, a quick Google search let me to the solution, found here and quoted below.

Open Terminal: Ctrl+Shift+T

Execute these three commands:

gnome-session-remove gnome-panel
gconftool-2 --recursive-unset /apps/panel
gnome-panel &

Then logout and log back in, or restart you X server with CTRL+ALT+BACKSPACE , everything should be fine.

Note: During this process, all panels, including the top and bottom, will be deleted and restore to the default settings. So, if you delete the bottom panel, this also restores it.