# Screen blacking out

## doro1211

My computer seems to have some sort of a power saving feature where it blacks out the screen if I don't type something for a certain period of time.  I would like to disable this "feature".  It is not an x screensaver, as it occurs in both X and at the CLI.  This computer is used as a PVR to play videos and stream live TV to my television, so it's really annoying that it keeps blacking out.  Any ideas how to stop that?

----------

## null__

Try adding

```
setterm -blank 0
```

to your /etc/profile to disable blanking on the console and add

```
BlankTime 0
```

to the Serverflags section of your /etc/X11/xorg.conf to disable blanking in X.

Then do

```
source /etc/profile

/etc/init.d/xdm restart
```

and it should be fixed.

----------

## hpestilence

Putting

```
xset s off
```

in a console

works for me when I need to turn it off in X.

----------

## Eagle3386

Putting

```
setterm -blank 0
```

into /etc/profile and afterwards doing

```
source /etc/profile
```

results in

```
eagle # source /etc/profile

bash: setterm: command not found
```

The fix for this seems to be:

```
/usr/bin/setterm -blank 0
```

But I don't know why the BASH doesn't know that command?! O.o  :Shocked:   :Sad: 

----------

## mattsk

How about to disable it for the virtual consoles at startup?

I currently have 

```
/usr/bin/setterm -powersave off -blank 0
```

 in my /etc/conf.d/local.start (as sugested at http://www.gentoo.org/doc/en/faq.xml?style=printable)

This *should* (I hope) work fine for my main virtual console, but I wouldn't mind doing it for all the consoles. The above link suggests I should be able to do 

```
/usr/bin/setterm -powersave off -blank 0 > /dev/tty1
```

 but that doesn't seem to work properly - plus setterm doesn't actually seem to output to standard output anyway, so I don't see how that command does anything that the non redirected one doesn't.

My problem is that my gentoo box is a server, and it crashes from time to time. I'd like to see the crash dump (as much as possible) in order to help track down the problem, but usually the console is blanked, and because the machine is crashed I can't unblank the screen to see the dump.

Presumably the /etc/profile suggestion above only disables blanking once a user logs in, not before. Right?

----------

## Lloeki

and be sure that other stuff like kpowersaved, kscreensaver or the likes don't have some settings set too.

----------

## BillyBoy

I had a similar problem on my laptop just now. It started when I moved to the 4.1.2 gcc/2007.0 profile. It was driving me nuts. I also started with a new kernel, so it took forever to figure out what was causing it. I did not have APM in the kernel, but after enabling APM as a module, the screen behaves like it should. I also noticed I was unable to press the power button and have it shut down. I haven't had the chance to shut down yet, but I'll use the power button and see if that fixed it. I suspect it will.

----------

