Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 21 Oct 2002 11:40:08 +0100
From:      Matthew Seaman <m.seaman@infracaninophile.co.uk>
To:        freebsd-questions@FreeBSD.ORG
Subject:   Re: So, tell us what happened!
Message-ID:  <20021021104008.GA27016@happy-idiot-talk.infracaninophi>
In-Reply-To: <20021020205105.6828.qmail@web14702.mail.yahoo.com>
References:  <200210201807.g9KI7DOm035193@adsl-64-174-159-18.dsl.sntc01.pacbell.net> <20021020205105.6828.qmail@web14702.mail.yahoo.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Oct 20, 2002 at 01:51:05PM -0700, Wayne Lubin wrote:

> And dmesg indicates that everything is now being
> detected. Below are the pertinent entries from dmesg
> 
> apm0: <APM BIOS> on motherboard
> apm: found APM BIOS v1.2, connected at v1.2
> viapropm0: SMBus I/O base at 0x5000
> viapropm0: <VIA VT82C686A Power Management Unit> port
> 0x5000-0x500f at device 7.4 on pci0
> viapropm0: SMBus revision code 0x40
> smb0: <SMBus general purpose I/O> on smbus0
> 
> I also added apm_enable="YES" to /etc/rc.conf
> 
> The VT82c686A Power Management Unit is an ACPI Power
> Management Controler. I also have set my cmos to go
> into standby after 10 mins., shut the hdd after ten
> mins., screen blanking after 10 mins., etc..... But I
> don't think my system is ever going into any such
> modes. What I know is that after 5 mins. the screen
> saver comes on and I have left it alone for as much as
> an hour and the screen saver was still on, i.e. the
> screen never went to blank mode, and the power fan
> seemed to still be on at full speed. I think this
> means that power management is not working as it
> should. Am I supposed to have enabled it in some way
> beyond just setting it in the bios/cmos?  Any way for
> me to check if all this power management stuff is
> working as it should? Thanks.

I'm not sure that a FreeBSD machine would ever go into hibernation in
the way you expect.  Even when the machine seems quiescent, there's
still activity happening behind the scenes.  For instance, cron(8)
will call stat(2) on all of the various crontab files on the machine
once a minute.  Other daemon processes will similarly wake up at
regular intervals, grunt, roll over and go back to sleep again.

What all of that effort to get the right devices into the kernel will
have gained you is the ability to monitor the state (temperature, fan
speed, voltages) of your hardware, and presumably, to run 'shutdown
-p' and have the machine power-off automatically.  The ACPI support in
4.x is not as comprehensive as it might be: 5.0 has some significant
improvements in the pipeline.

I've found that installing and running fvcool(8) --
ports/sysutils/fvcool --- has made the greatest difference to power
consumption: since the heat output of the CPU is now significantly
lower, the power usage must be lower too.

When you say 'screensaver' are you talking about the console screen
saver or an X based screen saver?  To the best of my knowlege, you
can't power down the console screen, other than by using the 'blank'
screensaver module, which isn't really that effective, power-wise.

In X windows however, you can use the dpms facility most modern video
cards support to turn your monitor to standby mode.  These settings in
/etc/X11/XF86Config should set the default timings for closing down
the display when idle:

    Section "ServerFlags"
            Option       "BlankTime" "10"
            Option       "StandbyTime" "20"
            Option       "SuspendTime" "30"
            Option       "OffTime" "30"
    EndSection

    [...]

    Section "Monitor"
            Identifier   "Monitor0"
            [...]
            Option       "DPMS"
    EndSection
    
but they can easily be overriden from a user session using xset(1)

The easiest way to use DPMS however is to install
ports/x11/xscreensaver or ports/x11/xscreensaver-gnome and set the
timeouts using the xscreensaver-demo program.  If you use xdm(1) or
the like, you can modify the configuration to run xscreensaver while
the system is sitting at the login prompt.  What you have to do is
described in the xscreensaver(1) man page, but with xdm(1) it boils
down to these changes to files in /usr/X11R6/lib/X11/xdm

    happy-idiot-talk:...lib/X11/xdm:% diff -u Xsession{.orig,}
    --- Xsession.orig       Fri Mar 22 18:31:44 2002
    +++ Xsession    Thu Oct 17 22:43:24 2002
    @@ -18,6 +18,9 @@
            fi
     done
     
    +# Kill off any stray copies of xscreensaver run by xdm
    +xscreensaver-command -exit
    +
     case $# in
     1)
            case $1 in
    
    happy-idiot-talk:...lib/X11/xdm:% diff -u Xsetup_0{.orig,}
    --- Xsetup_0.orig       Fri Mar 22 18:33:08 2002
    +++ Xsetup_0    Thu Oct 17 22:43:24 2002
    @@ -1,3 +1,7 @@
     #!/bin/sh
     # $Xorg: Xsetup_0,v 1.3 2000/08/17 19:54:17 cpqbld Exp $
    +xhost +local:
    +xsetroot -solid black
    +xscreensaver-command -exit
    +xscreensaver &
     xconsole -geometry 480x130-0-0 -daemon -notify -verbose -fn fixed -exitOnFail

Remember to keep backup copies of your modifications as those files
will be wiped out the next time you update the XFree86-clients
port. The xsetroot part is entirely optional --- I just happen to think
a black background works better.

Also you need to set up /root/.xscreensaver with appropriate entries,
probably by running xscreensaver-demo(1) as root.  Particularly you
want to disable the screen locking functionality when running over
xdm(1).

	Cheers,

	Matthew

-- 
Dr Matthew J Seaman MA, D.Phil.                       26 The Paddocks
                                                      Savill Way
                                                      Marlow
Tel: +44 1628 476614                                  Bucks., SL7 1TH UK

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021021104008.GA27016>