Already posted in Community, but got locked and moved, and got lost, sorry.

Here's the issue:

I'm using Ubuntu in a Sony Vaio SVF15A17CLB, which has a backlit keyboard, but it's not turned on by the System by default, so, every time I want to turn it on I have to manually change the value in: /sys/devices/platform/sony-laptop/kbd_backlight from -1 to 1 with sudo vi

But that resets every time I restart the computer.

Is it a setting somewhere else handling that? Can I make it permanent?

  • That looks like the answer. But now I have the problem that I don't have a rc.local file – Mauricio Machado May 2 '18 at 13:16
  • Just added the file and boom! like a charm. Thanks! One detail, though, changed the >> operator to a >, since I want to write, not append. – Mauricio Machado May 2 '18 at 13:44
  • 1
    Thank you very much for the way the question was posed, helped me with my VAIO too!! – Ruggi Jan 9 '19 at 1:43

To put the comment into an actual answer, you can create an rc.local file or add it to the end of your existing file. It should look something like this:

echo 1 > /sys/devices/platform/sony-laptop/kbd_backlight
exit 0

You want to make sure you're using > and not >>, since you want to overwrite the backlight value, not append to it.

You could probably create a systemd service file that would do the same thing, but I'm not sure if that's really necessary.

  • I get a permission denied message when I try to execute the "echo 1 ..." command as a root user. How to overcome this? – Indrajit Mar 23 '20 at 13:46
  • I'm not sure. You might just have the the wrong libraries installed. – Wayne Werner Mar 23 '20 at 22:31

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