Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

On my macbook pro the screen brightness key doesn't work. For it to work I have to type in sudo modprobe -r apple_gmux sudo modprobe apple_gmux Everytime I start up ubuntu. Is there anyway to fix this or auto run it.

share|improve this question
up vote 1 down vote accepted

To run a script as root on startup, simple edit /etc/rc.local file and add the script as separate lines to it, before the exit 0 line. Remember that you need root privileges to edit that file.

gksudo gedit /etc/rc.local

and note that sudo is not needed when inserting commands in this file, i.e. only add:

modprobe -r apple_gmux
modprobe apple_gmux
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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