old-www/HOWTO/Ecology-HOWTO/c91.htm

430 lines
9.2 KiB
HTML

<HTML
><HEAD
><TITLE
>Reduction of Power Consumption</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"><LINK
REL="HOME"
TITLE="Linux Ecology-HOWTO"
HREF="book1.htm"><LINK
REL="PREVIOUS"
TITLE="About the Document and the Authors"
HREF="x68.htm"><LINK
REL="NEXT"
TITLE="Power Management Unit - PMU (Apple PowerBook)"
HREF="x165.htm"></HEAD
><BODY
CLASS="chapter"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><DIV
CLASS="NAVHEADER"
><TABLE
SUMMARY="Header navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TH
COLSPAN="3"
ALIGN="center"
>Linux Ecology-HOWTO</TH
></TR
><TR
><TD
WIDTH="10%"
ALIGN="left"
VALIGN="bottom"
><A
HREF="x68.htm"
ACCESSKEY="P"
>Prev</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
></TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="x165.htm"
ACCESSKEY="N"
>Next</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><DIV
CLASS="chapter"
><H1
><A
NAME="ecology-howto-power-consumption"
></A
>Chapter 1. Reduction of Power Consumption</H1
><DIV
CLASS="TOC"
><DL
><DT
><B
>Table of Contents</B
></DT
><DT
><A
HREF="c91.htm#ecology-howto-power-management"
>Advanced Power Management (APM/ACPI)</A
></DT
><DT
><A
HREF="x165.htm"
>Power Management Unit - PMU (Apple PowerBook)</A
></DT
><DT
><A
HREF="x170.htm"
>Turn Monitor off, use Keyboard LEDs</A
></DT
><DT
><A
HREF="x187.htm"
>Screensavers</A
></DT
><DT
><A
HREF="x209.htm"
>Energy Star Label</A
></DT
><DT
><A
HREF="x221.htm"
>Miscellaneous Power Saving Techniques</A
></DT
></DL
></DIV
><P
>&#13;There are some means to save power when using a computer which are supported by Linux: Advanced Power Management, certain harddisk settings, working without monitor and others.
</P
><DIV
CLASS="sect1"
><H1
CLASS="sect1"
><A
NAME="ecology-howto-power-management"
></A
>Advanced Power Management (APM/ACPI)</H1
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="AEN96"
></A
>Linux Compatibility Check</H2
><P
>&#13;From the
<A
HREF="http://tldp.org/HOWTO/Battery-Powered/index.html"
TARGET="_top"
>Battery-Powered-mini-HOWTO</A
>
" .. for APM to work on any notebook or energy-conscious desktop, the system BIOS ROM in the machine must support the APM standard. Furthermore, for APM to work with the Linux operating system, the system BIOS ROM must support either the 1.0 or 1.1 version of the APM standard, and it must also support 32-bit protected mode connections. A system that supports APM 1.1 is preferred, as it provides more features that the device driver and supporting utilities can take advantage of."
You may get information about the APM version with the <B
CLASS="command"
>dmesg</B
> command and in the <TT
CLASS="filename"
>/proc/apm</TT
> file.
</P
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="AEN102"
></A
>Introduction</H2
><P
>&#13;When you first install Linux, you will probably have to recompile the kernel. The kernel that came with your distribution probably does not have APM enabled.
</P
><P
>&#13;APM support consists of two parts: <B
CLASS="command"
>kernel</B
> support and <B
CLASS="command"
>user-land</B
> support.
</P
><P
>&#13;For <B
CLASS="command"
>kernel</B
> support, enable the parameters in the corresponding kernel section. AFAIK not all features work with laptops. AFAIK the feature <B
CLASS="command"
>CONFIG_APM_POWER_OFF</B
> works with most laptops.
</P
><P
>&#13;The utilities for <B
CLASS="command"
>userland</B
> support may be found at <A
HREF="http://www.worldvisions.ca/~apenwarr/apmd/"
TARGET="_top"
>WorldVisions</A
>. APMD is a set of programs that control the Advanced Power Management system found in most modern laptop computers. If you run a 2.2.x kernel and want to experiment, Gabor Kuti &#60;seasons at falcon.sch.bme.hu&#62; has made a kernel patch that allows you to <B
CLASS="command"
>hibernate</B
> any Linux system to disk, even if your computers APM BIOS doesn't support it directly.
</P
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="AEN115"
></A
>Caveats</H2
><P
>&#13;If you have another operating system preinstalled or use another operating system at the same disk, make sure there is no "hibernation" or "suspend" tool installed, which could severely interfere with Linux, e.g. it might use disk space which is occupied by Linux or vice versa.
</P
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="AEN118"
></A
>Troubleshooting</H2
><P
>&#13;If your machine worked with 2.0.x kernels but not with the 2.2.x series, take this advice from Klaus Franken kfr at klaus.franken.de : "The default changed in 2.2. Search in the init-scripts for <B
CLASS="command"
>halt</B
> and change it to <B
CLASS="command"
>halt -p</B
> or <B
CLASS="command"
>poweroff</B
>. See <B
CLASS="command"
>man halt</B
> , if you don't have this option you need a newer version of <B
CLASS="command"
>halt</B
>." You may find it in the <B
CLASS="command"
>SysVinit</B
> package.
</P
><P
>&#13;Sometimes X windows and APM don't work smoothly together, the machine might even hang. A recommendation from Steve Rader: Some Linux systems have their X server hang when doing <B
CLASS="command"
>apm -s</B
>. Folks with this affliction might want switch to the console virtual terminal then suspend <B
CLASS="command"
>chvt 1; apm -s</B
> as root, or, more appropiately.<B
CLASS="command"
>sudo chvt 1; sudo apm -s</B
>. I have these commands in a script, say, <B
CLASS="command"
>my-suspend</B
> and then do <B
CLASS="command"
>xapmload --click-command my-suspend</B
> .
</P
><P
>&#13;On some new machines (for instance HP Omnibook 4150 - 366 MHz model) when accessing <TT
CLASS="filename"
>/proc/apm</TT
>, you may get a kernel fault <B
CLASS="command"
>general protection fault: f000</B
>. Stephen Rothwell &#60;Stephen.Rothwell at canb.auug.org.au&#62; <A
HREF="http://www.canb.auug.org.au/~sfr/"
TARGET="_top"
>http://www.canb.auug.org.au/~sfr/</A
> explaines: "This is your APM BIOS attempting to use a real mode segment while in protected mode, i.e. it is a bug in your BIOS. .. We have seen a few of these recently, except all the others are in the power off code in the BIOS wher we can work around it by returning to real mode before attempting to power off. Here we cannot do this."
</P
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="AEN137"
></A
>ACPI</H2
><P
>&#13;The latest standard is ACPI. The
<A
HREF="http://acpi.sourceforge.net/wiki"
TARGET="_top"
>ACPI4Linux</A
> project is a kernel driver project aimed at implementing full ACPI support for Linux, including fan control, dock/undock detection and a WindowMaker dockable temperature meter.
</P
><P
>&#13;
<P
></P
><UL
><LI
><P
>&#13;<A
HREF="ftp://tsx-11.mit.edu/pub/linux/sources/sbin/hdparm-3.0.tar.gz"
TARGET="_top"
>hdparm</A
> <B
CLASS="command"
>hdparm</B
> is a Linux IDE disk utility that lets you set spin-down timeouts and other disk parameters. It works also for some SCSI features.
</P
></LI
><LI
><P
>&#13;<A
HREF="http://www.complang.tuwien.ac.at/ulrich/linux/tips.html"
TARGET="_top"
>Mobile Update Daemon</A
> This is a drop-in replacement for the standard <B
CLASS="command"
>update</B
> daemon, <B
CLASS="command"
>mobile-update</B
> minimizes disk spin ups and reduces disk uptime. It flushes buffers only when other disk activity is present. To ensure a consistent file system call <B
CLASS="command"
>sync</B
> manually. Otherwise files may be lost on power failure. <B
CLASS="command"
>mobile-update</B
> does not use APM. So it works also on older systems.
</P
></LI
><LI
><P
>&#13;
<A
HREF="http://www.buzzard.me.uk/toshiba/index.html"
TARGET="_top"
>Toshiba Linux Utilities</A
>:
This is a set of Linux utilities for controlling the fan, supervisor passwords, and hot key functions of Toshiba Pentium notebooks. There is a KDE package <B
CLASS="command"
>Klibreta</B
>, too.
</P
></LI
><LI
><P
>&#13;
<A
HREF="http://lcdproc.omnipotent.net/"
TARGET="_top"
>LCDproc</A
> .
"LCDproc is a small piece of software that will enable your Linux box
to display live system information on a 20x4 line backlit LCD display.
AFAIK it connects only to the external Matrix-Orbital 20x4 LCD display
<A
HREF="http://www.matrixorbital.com/"
TARGET="_top"
>MatrixOrbital</A
>,
which is a LCD display connected to a serial port.
</P
></LI
><LI
><P
>&#13;
<A
HREF="http://www.loonie.net/~eschenk/diald.html"
TARGET="_top"
>Dial Daemon</A
> . The Diald daemon provides on demand Internet connectivity using the SLIP or PPP protocols. Diald can automatically dial in to a remote host when needed or bring down dial-up connections that are inactive.
</P
></LI
></UL
>
</P
></DIV
></DIV
></DIV
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
SUMMARY="Footer navigation table"
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="x68.htm"
ACCESSKEY="P"
>Prev</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="book1.htm"
ACCESSKEY="H"
>Home</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="x165.htm"
ACCESSKEY="N"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>About the Document and the Authors</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
>&nbsp;</TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
>Power Management Unit - PMU (Apple PowerBook)</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>