I am trying to execute a simple script lxterminal -e "/home/pi/superscript.sh" in a normal terminal it works perfectly. But if i try putting it in to /etc/xdg/lxsession/LXDE-pi/autostart witch looks like this after this procedure:

@lxpanel --profile LXDE-pi
@pcmanfm --desktop --profile LXDE-pi
@xscreensaver -no-splash
@lxterminal -e "/home/pi/superscript.sh"

Nothing happens after start up. What could be the error here?

  • Tried it without the @? Sep 30, 2018 at 21:00
  • @AndyAnderson Yes.
    – Coder_fox
    Oct 1, 2018 at 11:42
  • How about: sh /home/pi/superscript.sh Oct 1, 2018 at 19:14

2 Answers 2


The global LXDE autostart file is ignored if there is a local autostart.

In Raspbian there is a local file: /home/pi/.config/lxsession/LXDE-pi/autostart.

Adding the command to that file should start it when you log in to the GUI.


If using lxterminal Don't forget to set the working directory with --working-directory="/home/pi/somedirectory", specially if you try to call some program not in standard path!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.