3

I am new to Linux and just started using ubuntu 14.04. I'm trying to run imwheel process on startup by editing rc.local file. Perhaps I'm doing something wrong and I need to type a path to a program apart just the name like in terminal?

when i try to do a check by running:

sudo service rc.local start

I get below message:INFO:

imwheel started (pid=4906)
Could not open display, check shell DISPLAY variable, and export or setenv it!

rc.local file:

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

imwheel

exit 0
L. D. James
  • 25,444
Trm
  • 1,035

1 Answers1

6

The imwheel is a GUI application that runs under X. You don't have X running, nor an X DISPLAY available when the rc.local file is run.

You'll have an X DISPLAY after you log in. So to have this automatically run you should set it up as one of your startup application.

You can get to your Startup Applications configuration by typing "Startup Applications" in the Ubuntu Launch button search field.

Just click Add, then for the three fields put:

  • A name for the entry (any that you choose)
  • The command (in this case) imwheel
  • A comment (optional - to remind you what it does)

Click Add to save the new startup application, then close the window.

L. D. James
  • 25,444