How to automate keyboard backlight ON at boot












2














Right now I am running a cooler Master keyboard on Kubuntu 16.04. At present I have to run



xset led 3 


in Konsole in order to turn the keyboard on, which is a PITA.



How can I instruct the system to light the keyboard at boot, particularly before and after the login screen?










share|improve this question






















  • I would put the command in /etc/rc.local but you can also use a cron job with @reboot. See: askubuntu.com/questions/228304/…
    – WinEunuuchs2Unix
    Jan 7 at 19:31










  • Can I enter the command as is, or should I enter a pathway for an *.sh file?
    – Timbot2000
    Jan 7 at 20:12










  • You can enter the command as is. A *.sh (script) file is typically only used for multi-line commands. When using cron you must find out the directory name to prefix the command. ie use which xset returns: /usr/bin/xset which is the exact command format you need to use. The simpler method is just to put the command in /etc/rc.local rather than using cron.
    – WinEunuuchs2Unix
    Jan 7 at 20:23










  • Sorry WinEunuuchs2Unix, entering it in the rc.local file failed to enact the command at startup. What do we try next?
    – Timbot2000
    Jan 8 at 2:49










  • Sorry the rc.local didn't work out. I've posted an answer which I hope does work.
    – WinEunuuchs2Unix
    Jan 8 at 3:42
















2














Right now I am running a cooler Master keyboard on Kubuntu 16.04. At present I have to run



xset led 3 


in Konsole in order to turn the keyboard on, which is a PITA.



How can I instruct the system to light the keyboard at boot, particularly before and after the login screen?










share|improve this question






















  • I would put the command in /etc/rc.local but you can also use a cron job with @reboot. See: askubuntu.com/questions/228304/…
    – WinEunuuchs2Unix
    Jan 7 at 19:31










  • Can I enter the command as is, or should I enter a pathway for an *.sh file?
    – Timbot2000
    Jan 7 at 20:12










  • You can enter the command as is. A *.sh (script) file is typically only used for multi-line commands. When using cron you must find out the directory name to prefix the command. ie use which xset returns: /usr/bin/xset which is the exact command format you need to use. The simpler method is just to put the command in /etc/rc.local rather than using cron.
    – WinEunuuchs2Unix
    Jan 7 at 20:23










  • Sorry WinEunuuchs2Unix, entering it in the rc.local file failed to enact the command at startup. What do we try next?
    – Timbot2000
    Jan 8 at 2:49










  • Sorry the rc.local didn't work out. I've posted an answer which I hope does work.
    – WinEunuuchs2Unix
    Jan 8 at 3:42














2












2








2


1





Right now I am running a cooler Master keyboard on Kubuntu 16.04. At present I have to run



xset led 3 


in Konsole in order to turn the keyboard on, which is a PITA.



How can I instruct the system to light the keyboard at boot, particularly before and after the login screen?










share|improve this question













Right now I am running a cooler Master keyboard on Kubuntu 16.04. At present I have to run



xset led 3 


in Konsole in order to turn the keyboard on, which is a PITA.



How can I instruct the system to light the keyboard at boot, particularly before and after the login screen?







boot keyboard backlight






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Jan 7 at 18:56









Timbot2000

162




162












  • I would put the command in /etc/rc.local but you can also use a cron job with @reboot. See: askubuntu.com/questions/228304/…
    – WinEunuuchs2Unix
    Jan 7 at 19:31










  • Can I enter the command as is, or should I enter a pathway for an *.sh file?
    – Timbot2000
    Jan 7 at 20:12










  • You can enter the command as is. A *.sh (script) file is typically only used for multi-line commands. When using cron you must find out the directory name to prefix the command. ie use which xset returns: /usr/bin/xset which is the exact command format you need to use. The simpler method is just to put the command in /etc/rc.local rather than using cron.
    – WinEunuuchs2Unix
    Jan 7 at 20:23










  • Sorry WinEunuuchs2Unix, entering it in the rc.local file failed to enact the command at startup. What do we try next?
    – Timbot2000
    Jan 8 at 2:49










  • Sorry the rc.local didn't work out. I've posted an answer which I hope does work.
    – WinEunuuchs2Unix
    Jan 8 at 3:42


















  • I would put the command in /etc/rc.local but you can also use a cron job with @reboot. See: askubuntu.com/questions/228304/…
    – WinEunuuchs2Unix
    Jan 7 at 19:31










  • Can I enter the command as is, or should I enter a pathway for an *.sh file?
    – Timbot2000
    Jan 7 at 20:12










  • You can enter the command as is. A *.sh (script) file is typically only used for multi-line commands. When using cron you must find out the directory name to prefix the command. ie use which xset returns: /usr/bin/xset which is the exact command format you need to use. The simpler method is just to put the command in /etc/rc.local rather than using cron.
    – WinEunuuchs2Unix
    Jan 7 at 20:23










  • Sorry WinEunuuchs2Unix, entering it in the rc.local file failed to enact the command at startup. What do we try next?
    – Timbot2000
    Jan 8 at 2:49










  • Sorry the rc.local didn't work out. I've posted an answer which I hope does work.
    – WinEunuuchs2Unix
    Jan 8 at 3:42
















I would put the command in /etc/rc.local but you can also use a cron job with @reboot. See: askubuntu.com/questions/228304/…
– WinEunuuchs2Unix
Jan 7 at 19:31




I would put the command in /etc/rc.local but you can also use a cron job with @reboot. See: askubuntu.com/questions/228304/…
– WinEunuuchs2Unix
Jan 7 at 19:31












Can I enter the command as is, or should I enter a pathway for an *.sh file?
– Timbot2000
Jan 7 at 20:12




Can I enter the command as is, or should I enter a pathway for an *.sh file?
– Timbot2000
Jan 7 at 20:12












You can enter the command as is. A *.sh (script) file is typically only used for multi-line commands. When using cron you must find out the directory name to prefix the command. ie use which xset returns: /usr/bin/xset which is the exact command format you need to use. The simpler method is just to put the command in /etc/rc.local rather than using cron.
– WinEunuuchs2Unix
Jan 7 at 20:23




You can enter the command as is. A *.sh (script) file is typically only used for multi-line commands. When using cron you must find out the directory name to prefix the command. ie use which xset returns: /usr/bin/xset which is the exact command format you need to use. The simpler method is just to put the command in /etc/rc.local rather than using cron.
– WinEunuuchs2Unix
Jan 7 at 20:23












Sorry WinEunuuchs2Unix, entering it in the rc.local file failed to enact the command at startup. What do we try next?
– Timbot2000
Jan 8 at 2:49




Sorry WinEunuuchs2Unix, entering it in the rc.local file failed to enact the command at startup. What do we try next?
– Timbot2000
Jan 8 at 2:49












Sorry the rc.local didn't work out. I've posted an answer which I hope does work.
– WinEunuuchs2Unix
Jan 8 at 3:42




Sorry the rc.local didn't work out. I've posted an answer which I hope does work.
– WinEunuuchs2Unix
Jan 8 at 3:42










1 Answer
1






active

oldest

votes


















1














Using "Startup Applications" instead of /etc/rc.local




  • Select the first option on your Launcher called Dash. Then type "startup" and a screen similar to this will appear:
    Dash Startup applications.png


  • Select the option "Startup Applications" and a screen similar to this will appear:
    Startup Applications 2.png


  • Select Add and this screen will appear:
    Startup Applications 3.png


  • Make sure you enter the command as: /usr/bin/xset led 3


  • I entered the comment as: Ubuntu 16.04 regular crash, Compiz segfault, error 4 in i965_dri.so, Fresh install but you don't need to.


Notes



I can't test this on my system because the Laptop's built-in keyboard and wireless keyboard both light up automatically.



You can't put xrandr commands in /etc/rc.local because it runs before a user logs in. xrandr commands can only be used after the user logs on.






share|improve this answer























  • I can confirm, this actually works on Linux Mint 19.1
    – Ronald
    Dec 27 at 23:37






  • 1




    @Ronald Thank you for confirming. If I may be so bold it is customary to upvote answers you find helpful...
    – WinEunuuchs2Unix
    Dec 27 at 23:58











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f993311%2fhow-to-automate-keyboard-backlight-on-at-boot%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









1














Using "Startup Applications" instead of /etc/rc.local




  • Select the first option on your Launcher called Dash. Then type "startup" and a screen similar to this will appear:
    Dash Startup applications.png


  • Select the option "Startup Applications" and a screen similar to this will appear:
    Startup Applications 2.png


  • Select Add and this screen will appear:
    Startup Applications 3.png


  • Make sure you enter the command as: /usr/bin/xset led 3


  • I entered the comment as: Ubuntu 16.04 regular crash, Compiz segfault, error 4 in i965_dri.so, Fresh install but you don't need to.


Notes



I can't test this on my system because the Laptop's built-in keyboard and wireless keyboard both light up automatically.



You can't put xrandr commands in /etc/rc.local because it runs before a user logs in. xrandr commands can only be used after the user logs on.






share|improve this answer























  • I can confirm, this actually works on Linux Mint 19.1
    – Ronald
    Dec 27 at 23:37






  • 1




    @Ronald Thank you for confirming. If I may be so bold it is customary to upvote answers you find helpful...
    – WinEunuuchs2Unix
    Dec 27 at 23:58
















1














Using "Startup Applications" instead of /etc/rc.local




  • Select the first option on your Launcher called Dash. Then type "startup" and a screen similar to this will appear:
    Dash Startup applications.png


  • Select the option "Startup Applications" and a screen similar to this will appear:
    Startup Applications 2.png


  • Select Add and this screen will appear:
    Startup Applications 3.png


  • Make sure you enter the command as: /usr/bin/xset led 3


  • I entered the comment as: Ubuntu 16.04 regular crash, Compiz segfault, error 4 in i965_dri.so, Fresh install but you don't need to.


Notes



I can't test this on my system because the Laptop's built-in keyboard and wireless keyboard both light up automatically.



You can't put xrandr commands in /etc/rc.local because it runs before a user logs in. xrandr commands can only be used after the user logs on.






share|improve this answer























  • I can confirm, this actually works on Linux Mint 19.1
    – Ronald
    Dec 27 at 23:37






  • 1




    @Ronald Thank you for confirming. If I may be so bold it is customary to upvote answers you find helpful...
    – WinEunuuchs2Unix
    Dec 27 at 23:58














1












1








1






Using "Startup Applications" instead of /etc/rc.local




  • Select the first option on your Launcher called Dash. Then type "startup" and a screen similar to this will appear:
    Dash Startup applications.png


  • Select the option "Startup Applications" and a screen similar to this will appear:
    Startup Applications 2.png


  • Select Add and this screen will appear:
    Startup Applications 3.png


  • Make sure you enter the command as: /usr/bin/xset led 3


  • I entered the comment as: Ubuntu 16.04 regular crash, Compiz segfault, error 4 in i965_dri.so, Fresh install but you don't need to.


Notes



I can't test this on my system because the Laptop's built-in keyboard and wireless keyboard both light up automatically.



You can't put xrandr commands in /etc/rc.local because it runs before a user logs in. xrandr commands can only be used after the user logs on.






share|improve this answer














Using "Startup Applications" instead of /etc/rc.local




  • Select the first option on your Launcher called Dash. Then type "startup" and a screen similar to this will appear:
    Dash Startup applications.png


  • Select the option "Startup Applications" and a screen similar to this will appear:
    Startup Applications 2.png


  • Select Add and this screen will appear:
    Startup Applications 3.png


  • Make sure you enter the command as: /usr/bin/xset led 3


  • I entered the comment as: Ubuntu 16.04 regular crash, Compiz segfault, error 4 in i965_dri.so, Fresh install but you don't need to.


Notes



I can't test this on my system because the Laptop's built-in keyboard and wireless keyboard both light up automatically.



You can't put xrandr commands in /etc/rc.local because it runs before a user logs in. xrandr commands can only be used after the user logs on.







share|improve this answer














share|improve this answer



share|improve this answer








edited Dec 27 at 23:57

























answered Jan 8 at 3:41









WinEunuuchs2Unix

43.4k1075164




43.4k1075164












  • I can confirm, this actually works on Linux Mint 19.1
    – Ronald
    Dec 27 at 23:37






  • 1




    @Ronald Thank you for confirming. If I may be so bold it is customary to upvote answers you find helpful...
    – WinEunuuchs2Unix
    Dec 27 at 23:58


















  • I can confirm, this actually works on Linux Mint 19.1
    – Ronald
    Dec 27 at 23:37






  • 1




    @Ronald Thank you for confirming. If I may be so bold it is customary to upvote answers you find helpful...
    – WinEunuuchs2Unix
    Dec 27 at 23:58
















I can confirm, this actually works on Linux Mint 19.1
– Ronald
Dec 27 at 23:37




I can confirm, this actually works on Linux Mint 19.1
– Ronald
Dec 27 at 23:37




1




1




@Ronald Thank you for confirming. If I may be so bold it is customary to upvote answers you find helpful...
– WinEunuuchs2Unix
Dec 27 at 23:58




@Ronald Thank you for confirming. If I may be so bold it is customary to upvote answers you find helpful...
– WinEunuuchs2Unix
Dec 27 at 23:58


















draft saved

draft discarded




















































Thanks for contributing an answer to Ask Ubuntu!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f993311%2fhow-to-automate-keyboard-backlight-on-at-boot%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Human spaceflight

Can not write log (Is /dev/pts mounted?) - openpty in Ubuntu-on-Windows?

File:DeusFollowingSea.jpg