12

I recently was messing around with my Pi when I accidentally deleted the taskbar. I cannot figure out how to bring it back.

I was on the desktop when I highlighted two icons on the left side of the taskbar, one called "Panel 1" and the other called "Panel 2". I figured I didn't want two panels, so I right clicked Panel 2 and deleted it. That ended up deleting my taskbar!

How can I bring it back? I'm using the latest version of Raspbian.

Ghanima
  • 15,958
  • 17
  • 65
  • 125
taskbar
  • 129
  • 1
  • 1
  • 3

5 Answers5

18

I did exactly the same thing. You can fix it by copying a default panel back:

(adapted from https://askubuntu.com/questions/64631/how-to-restore-the-default-lubuntu-panel)

cd ~/.config/lxpanel/LXDE/panels
cp /usr/share/lxpanel/profile/default/panels/panel .
sudo reboot

Cheers!

With Raspbian Jessie (2016-11-25), it would be

cd ~/.config/lxpanel/LXDE-pi/panels
curl -O https://gist.githubusercontent.com/ColinNg/9ed317308a9a0f75824f828e75c8469c/raw/a72176416201a0e6ebbce30608e6f7eceb379e0e/panel
sudo reboot

And with Raspbian Buster (2019-07-10):

cp /etc/xdg/lxpanel/LXDE-pi/panels/panel /home/pi/.config/lxpanel/LXDE-pi/panels/panel
sudo reboot
Martin
  • 145
  • 4
Colin
  • 281
  • 2
  • 6
1

Restart your Pi. The deletion is only temporary and will be returned.

Beta Decay
  • 400
  • 4
  • 14
0

Try creating a new user and logging in as that user, then start lxde and see if that user has a panel. If that works, maybe you can copy the lxde config file from that user to your pi user.

francis
  • 765
  • 8
  • 21
0

I also Deleted accidentally but recovered this way There was one more task-bar on top of Screen right click on top taskbar>>Panel Setting>>Gemetry tab>>Make postion Bottom

right click on top taskbar>>Add/Remove panel Item select Panel Applets Tab >> Add >> Select Task Bar(Window list) >> Click Add Now you can all apps open.

0

I haven't found the corrrect fix yet, but if I type "lxpanel &" in a terminal emulator I get a working taskbar again. (logout doesn't work) You can also put a line "lxpanel &" in /etc/X11/xinit/xinitrc to make it more permanent.

From this you should have figured out that lxpanel is just a program that runs, what you have to do to start it is more an annoyance than anything.

I had been logged in via VNC (and installed tightvncserver remotely via ssh) and when I came back to the physical machine the taskbar was gone, so I started Googling. VNC maintains a set of preferences files which mostly parallel X(org) in ~/$HOME/.vnc/xstartup and it's possible something went in there by accident. The more normal config files are in ~/$HOME/.config/lxpanel and lxsession, then some system-wide ones in /etc/xdg/lxpanel and lxsession. But it's quite a maze, the lazy fix would be to experiment with replacing those files with ones from another machine. Just remember you can run lxpanel from multiple places if you get stuck. I can get to obconf just fine but I don't see anything in there that looks like a fix. You want a default set of config files. And you'll need to get out of X and back in, or reboot, to be sure you've cured it.

And BTW this is in 64 bit Debian Stretch on a Rock64, looks about the same as the Raspberry Pi I'm typing this on. And the same as LXDE in Wheezy on an amd64 machine, it's not at all peculiar to a Raspberry Pi.

When you're poking around in there (I used mc) look for files with recent dates. But maybe they got deleted too. I see changes in ~/$HOME/.config/lxpanel/LXDE/panels/panel and ~/$HOME/.config/lxpanel/default/panels/panel. I've replaced those 2 files with an original panel file from another arm64 machine. Now when it's booting I see the taskbar flash twice but then it goes away. Still a work in progress. Keep notes, one of the principle Lnux trade secrets.

Alan Corey
  • 201
  • 1
  • 6