Is there a way to turn off the display (enter power saving mode) using a command?

For example, when the computer is inactive for a specific interval, the screen turns off to conserve energy. Is there a way to manually turn off the screen, yet keep the computer running normally?

This is a notebook, so there's no 'power-off' button on the monitor itself.

link|improve this question

feedback

2 Answers

up vote 18 down vote accepted

I think you are looking for

xset dpms force off

However, you need to make sure that your acpi is enabled. You can check this with

cat /proc/acpi/info

Another option could be

setterm -powersave powerdown
link|improve this answer
2  
The first command didn't require sudo for me. – DoR Oct 14 '10 at 21:22
Me neither. ` ` ` ` – George Edison Oct 14 '10 at 21:38
3  
Sometimes the Enter keypress as you execute the command can be enough to immediately wake the computer back up again. I usually go with sleep 0.2s && xset dpms force off just to be safe. Also, this makes for a nice replacement for locking your screen: gnome-screensaver-command --lock && sleep 2s && xset dpms force off – ændrük Oct 14 '10 at 22:01
ok.. took the sudo advisory out :D – txwikinger Oct 14 '10 at 23:27
feedback

i have made a unity launcher to turnoff the lcd u can also try this

sudo apt-get install --no-install-recommends gnome-panel

gnome-desktop-item-edit ~/Desktop/ --create-new

it will open a small windows

in name type : turnofflcd

in command type :gnome-screensaver-command --lock && sleep 2s && xset dpms force off

u can also choose icon by clicking the icom on the left

for more on making launcher see : http://www.ubuntugeek.com/how-to-create-desktop-launchers-in-ubuntu-11-10oneiric.html

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

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