running powernowd on debian lenny

2009-12-26 Thread Umarzuki Mochlis
I have a cq40-115au latop with AMD Turion x2 RM-70 processor.

I want to enable powernowd. After i compiled it from source, when i ran
# powernowd

here are the output:

powernowd: PowerNow Daemon v1.00, (c) 2003-2008 John Clemens
/sys/devices/system/cpu/cpu0/cpufreq/affected_cpus: No such file or
directory
powernowd: err=2
powernowd: Found 2 scalable units:  -- 1 'CPU' per scalable unit
/sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq: No such file or
directory

PowerNowd encountered and error and could not start.
Please make sure that:
 - You are running a v2.6.7 kernel or later
 - That you have sysfs mounted /sys
 - That you have the core cpufreq and cpufreq-userspace
   modules loaded into your kernel
 - That you have the cpufreq driver for your cpu loaded,
   (for example: powernow-k7), and that it works. Check
   'dmesg' for errors.

# uname -r
2.6.26-2-686-bigmem

# df -h
FilesystemSize  Used Avail Use% Mounted on
/dev/sda1  11G  4.4G  5.5G  45% /
tmpfs 1.9G 0  1.9G   0% /lib/init/rw
udev   10M  824K  9.2M   9% /dev
tmpfs 1.9G  524K  1.9G   1% /dev/shm
/dev/sda2 131G  115G  9.9G  93% /home

It seems that i did not satisfy condition number 2. What should I do next?

-- 
Regards,

Umarzuki Mochlis
http://debmal.my


Re: running powernowd on debian lenny

2009-12-26 Thread Artur Frydel
On Sat, Dec 26, 2009 at 3:59 PM, Umarzuki Mochlis umarz...@gmail.com wrote:
 I have a cq40-115au latop with AMD Turion x2 RM-70 processor.
 I want to enable powernowd. After i compiled it from source, when i ran
 # powernowd

Why you don't use powernowd from debian repositories?
Have you cpufreqd?

-- 
Best regards.
Artur 'Bzyk' Frydel
Always look on the bright side of life.


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Re: running powernowd on debian lenny

2009-12-26 Thread Umarzuki Mochlis
2009/12/27 Artur Frydel artur.fry...@gmail.com

 On Sat, Dec 26, 2009 at 3:59 PM, Umarzuki Mochlis umarz...@gmail.com
 wrote:
  I have a cq40-115au latop with AMD Turion x2 RM-70 processor.
  I want to enable powernowd. After i compiled it from source, when i ran
  # powernowd

 Why you don't use powernowd from debian repositories?


i don't remember what got me to compiling or maybe i just forgot to search
for it


 Have you cpufreqd?


# dpkg -l cpufreqd
Desired=Unknown/Install/Remove/Purge/Hold
|
Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err:
uppercase=bad)
||/ Name   VersionDescription
+++-==-==-
rc  cpufreqd   2.3.3-4fully configurable daemon for dynamic
freque



 --
 Best regards.
 Artur 'Bzyk' Frydel
 Always look on the bright side of life.




-- 
Regards,

Umarzuki Mochlis
http://debmal.my


Re: running powernowd on debian lenny

2009-12-26 Thread Dave Witbrodt

Umarzuki Mochlis wrote:
2009/12/27 Dave Witbrodt dawit...@sbcglobal.net 
Umarzuki Mochlis wrote:


I have a cq40-115au latop with AMD Turion x2 RM-70 processor.

I want to enable powernowd. After i compiled it from source


Because you built your own, it becomes more difficult for the rest
of us to help you.  The Debian 'powernowd' package has been altered
from upstream to put its configuration options in
/etc/default/powernowd.  My answers below are from my own
experiences using the Debian 'powernowd' package; you will have to
read the documentation in the source code, and figure out how to
translate my answers to work for your own setup.  (In my view, it
was a waste of time for you to compile your own 'powernowd', since
Debian already has the package.)


i had removed it (now) with 
#make clean

#rm -f /usr/bin/powernowd
 
and installed powernowd package, enabled needed modules


#modprobe cpufreq_userspace powernow-k8


So, did that work or not?



, when i ran
# powernowd
here are the output:

powernowd: PowerNow Daemon v1.00, (c) 2003-2008 John Clemens
/sys/devices/system/cpu/cpu0/cpufreq/affected_cpus: No such file
or directory
powernowd: err=2
powernowd: Found 2 scalable units:  -- 1 'CPU' per scalable unit
/sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq: No such
file or directory

PowerNowd encountered and error and could not start.
Please make sure that:
 - You are running a v2.6.7 kernel or later
 - That you have sysfs mounted /sys
 - That you have the core cpufreq and cpufreq-userspace
  modules loaded into your kernel
 - That you have the cpufreq driver for your cpu loaded,
  (for example: powernow-k7), and that it works. Check
  'dmesg' for errors.

# uname -r
2.6.26-2-686-bigmem


I assume that is a Debian kernel?  The default CPU_FREQ_GOV*
settings have changed over time.  What do you get if you run this:

   grep CPU_FREQ /boot/config-2.6.26-2-686-bigmem


CONFIG_CPU_FREQ=y

[...]

CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE=y
# CONFIG_CPU_FREQ_DEFAULT_GOV_POWERSAVE is not set
# CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE is not set
# CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND is not set
# CONFIG_CPU_FREQ_DEFAULT_GOV_CONSERVATIVE is not set
CONFIG_CPU_FREQ_GOV_PERFORMANCE=y
CONFIG_CPU_FREQ_GOV_POWERSAVE=m
CONFIG_CPU_FREQ_GOV_USERSPACE=m
CONFIG_CPU_FREQ_GOV_ONDEMAND=m
CONFIG_CPU_FREQ_GOV_CONSERVATIVE=m


So, you have an old kernel that defaults to performance.  That will 
cause your CPU to run at full speed, instead of cycling down when not 
needed.



What is in /etc/fstab?  If you installed using a
Debian installer, you should have a line like this:

   sysfs  /sys  sysfs  defaults  0  0


# file system mount point   type  options   dump  pass
proc/proc   procdefaults0   0
/dev/sda1   /   ext3errors=remount-ro 0   1
/dev/sda2   /home   ext3defaults0   2
/dev/sda5   noneswapsw  0   0
/dev/scd0   /media/cdrom0   udf,iso9660 user,noauto 0   0
sysfs /sys sysfs defaults 0 0


Looks OK.



# mount -t sysfs none /sys
mount: none already mounted or /sys busy
mount: according to mtab, sysfs is already mounted on /sys


Yep, you already had /sys... no need to try to mount it again.



 What should I do next?

If the 'sysfs' line is missing from /etc/fstab, add it then mount it
using 'mount /sys'.

With Debian kernels, you need to add two lines to /etc/modules to
make it possible for 'powernowd' to run with recent AMD CPUs:

  cpufreq_userspace
  powernow-k8

You can load these without rebooting using 'modprobe'.  (I build my
own kernels, so when I _used_ to use 'powernowd', I simply built
these options directly into the kernel.)

If you were using 'powernowd' packages from Debian, you could edit
/etc/default/powernowd to enable loading the program during the boot
sequence and to customize its settings.  Since you built your own
'powernowd', tweaking the configuration may involve editing a
bootscript or something.  (You're on your own here:  RTF docs.)


One last thought.  I played with 'powernowd' for a while.  I liked
it well enough.  Then I found out that the Linux kernel has the
CPU_FREQ_GOV_ONDEMAND driver, which can be built into the kernel or
used as a loadable module.  Debian kernels began defaulting to it a
while ago, though your kernel may be old enough that it was not yet
using it by default.  I decided that 'powernowd' was superfluous,
and began using 'cpufreq_ondemand' and never looked back.  My advice
would be that you do the same.


So, did any of this work?  After letting the machine idle for a few 
seconds, run this:


  

Re: running powernowd on debian lenny

2009-12-26 Thread Umarzuki Mochlis
2009/12/27 Dave Witbrodt dawit...@sbcglobal.net

 Umarzuki Mochlis wrote:

 2009/12/27 Dave Witbrodt dawit...@sbcglobal.netUmarzuki Mochlis
 wrote:

I have a cq40-115au latop with AMD Turion x2 RM-70 processor.

I want to enable powernowd. After i compiled it from source


Because you built your own, it becomes more difficult for the rest
of us to help you.  The Debian 'powernowd' package has been altered
from upstream to put its configuration options in
/etc/default/powernowd.  My answers below are from my own
experiences using the Debian 'powernowd' package; you will have to
read the documentation in the source code, and figure out how to
translate my answers to work for your own setup.  (In my view, it
was a waste of time for you to compile your own 'powernowd', since
Debian already has the package.)


 i had removed it (now) with #make clean
 #rm -f /usr/bin/powernowd
  and installed powernowd package, enabled needed modules

 #modprobe cpufreq_userspace powernow-k8


 So, did that work or not?


i'm still having the same failure message, there's something amiss from what
i had done?




 , when i ran
# powernowd
here are the output:

powernowd: PowerNow Daemon v1.00, (c) 2003-2008 John Clemens
/sys/devices/system/cpu/cpu0/cpufreq/affected_cpus: No such file
or directory
powernowd: err=2
powernowd: Found 2 scalable units:  -- 1 'CPU' per scalable unit
/sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq: No such
file or directory

PowerNowd encountered and error and could not start.
Please make sure that:
 - You are running a v2.6.7 kernel or later
 - That you have sysfs mounted /sys
 - That you have the core cpufreq and cpufreq-userspace
  modules loaded into your kernel
 - That you have the cpufreq driver for your cpu loaded,
  (for example: powernow-k7), and that it works. Check
  'dmesg' for errors.

# uname -r
2.6.26-2-686-bigmem


I assume that is a Debian kernel?  The default CPU_FREQ_GOV*
settings have changed over time.  What do you get if you run this:

   grep CPU_FREQ /boot/config-2.6.26-2-686-bigmem


 CONFIG_CPU_FREQ=y

 [...]

 CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE=y

 # CONFIG_CPU_FREQ_DEFAULT_GOV_POWERSAVE is not set
 # CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE is not set
 # CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND is not set
 # CONFIG_CPU_FREQ_DEFAULT_GOV_CONSERVATIVE is not set
 CONFIG_CPU_FREQ_GOV_PERFORMANCE=y
 CONFIG_CPU_FREQ_GOV_POWERSAVE=m
 CONFIG_CPU_FREQ_GOV_USERSPACE=m
 CONFIG_CPU_FREQ_GOV_ONDEMAND=m
 CONFIG_CPU_FREQ_GOV_CONSERVATIVE=m


 So, you have an old kernel that defaults to performance.  That will cause
 your CPU to run at full speed, instead of cycling down when not needed.


this had caused my laptop to shutdown when playing games like secret maryo
chronicles



 What is in /etc/fstab?  If you installed using a
Debian installer, you should have a line like this:

   sysfs  /sys  sysfs  defaults  0  0


 # file system mount point   type  options   dump  pass
 proc/proc   procdefaults0   0
 /dev/sda1   /   ext3errors=remount-ro 0   1
 /dev/sda2   /home   ext3defaults0   2
 /dev/sda5   noneswapsw  0   0
 /dev/scd0   /media/cdrom0   udf,iso9660 user,noauto 0   0
 sysfs /sys sysfs defaults 0 0


 Looks OK.


the last line was just added by me




  # mount -t sysfs none /sys
 mount: none already mounted or /sys busy
 mount: according to mtab, sysfs is already mounted on /sys


 Yep, you already had /sys... no need to try to mount it again.



  What should I do next?

If the 'sysfs' line is missing from /etc/fstab, add it then mount it
using 'mount /sys'.

With Debian kernels, you need to add two lines to /etc/modules to
make it possible for 'powernowd' to run with recent AMD CPUs:

  cpufreq_userspace
  powernow-k8

You can load these without rebooting using 'modprobe'.  (I build my
own kernels, so when I _used_ to use 'powernowd', I simply built
these options directly into the kernel.)

If you were using 'powernowd' packages from Debian, you could edit
/etc/default/powernowd to enable loading the program during the boot
sequence and to customize its settings.  Since you built your own
'powernowd', tweaking the configuration may involve editing a
bootscript or something.  (You're on your own here:  RTF docs.)


One last thought.  I played with 'powernowd' for a while.  I liked
it well enough.  Then I found out that the Linux kernel has the
CPU_FREQ_GOV_ONDEMAND driver, which can be built into the kernel or
used as a loadable module.  Debian kernels began defaulting to it a
while ago, though your kernel may be old 

Re: running powernowd on debian lenny

2009-12-26 Thread Osamu Aoki
On Sat, Dec 26, 2009 at 10:59:32PM +0800, Umarzuki Mochlis wrote:
 I have a cq40-115au latop with AMD Turion x2 RM-70 processor.
 
 I want to enable powernowd. After i compiled it from source, when i ran
 # powernowd

Do you need user spece tool even now?

Why not use kernel module since you have new enough kernel and it comes
with modules for it.

I have /etc/modules:
speedstep_centrino
acpi_cpufreq
cpufreq_ondemand
#cpufreq_userspace
#cpufreq_conservative
#cpufreq_powersave

Since you have AMD, you may need to use powernow-k8 instead of
speedstep_centrino.

Please google for details.

Osamu



-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Re: running powernowd on debian lenny

2009-12-26 Thread Umarzuki Mochlis
2009/12/27 Osamu Aoki os...@debian.org

 On Sat, Dec 26, 2009 at 10:59:32PM +0800, Umarzuki Mochlis wrote:
  I have a cq40-115au latop with AMD Turion x2 RM-70 processor.
 
  I want to enable powernowd. After i compiled it from source, when i ran
  # powernowd

 Do you need user spece tool even now?

 Why not use kernel module since you have new enough kernel and it comes
 with modules for it.

 I have /etc/modules:
 speedstep_centrino
 acpi_cpufreq
 cpufreq_ondemand
 #cpufreq_userspace
 #cpufreq_conservative
 #cpufreq_powersave

 Since you have AMD, you may need to use powernow-k8 instead of
 speedstep_centrino.

 Please google for details.


thanks for the hints

by following tutorial from
http://technowizah.com/2007/01/debian-how-to-cpu-frequency-management.html i
set my cpufreq to conservative but does this setup shuts down wireless
card from time to time because my wireless connection sometimes goes on and
off?

# cpufreq-info
cpufrequtils 004: cpufreq-info (C) Dominik Brodowski 2004-2006
Report errors and bugs to cpuf...@lists.linux.org.uk, please.
analyzing CPU 0:
  driver: powernow-k8
  CPUs which need to switch frequency at the same time: 0
  hardware limits: 500 MHz - 2.00 GHz
  available frequency steps: 2.00 GHz, 1000 MHz, 500 MHz
  available cpufreq governors: powersave, conservative, performance
  current policy: frequency should be within 500 MHz and 2.00 GHz.
  The governor conservative may decide which speed to use
  within this range.
  current CPU frequency is 500 MHz (asserted by call to hardware).
  cpufreq stats: 2.00 GHz:32.50%, 1000 MHz:0.08%, 500 MHz:67.42%  (2)
analyzing CPU 1:
  driver: powernow-k8
  CPUs which need to switch frequency at the same time: 1
  hardware limits: 500 MHz - 2.00 GHz
  available frequency steps: 2.00 GHz, 1000 MHz, 500 MHz
  available cpufreq governors: powersave, conservative, performance
  current policy: frequency should be within 500 MHz and 2.00 GHz.
  The governor conservative may decide which speed to use
  within this range.
  current CPU frequency is 500 MHz (asserted by call to hardware).
  cpufreq stats: 2.00 GHz:45.84%, 1000 MHz:0.08%, 500 MHz:54.08%  (2)



 Osamu





-- 
Regards,

Umarzuki Mochlis
http://debmal.my


Re: running powernowd on debian lenny

2009-12-26 Thread Osamu Aoki
On Sun, Dec 27, 2009 at 08:07:39AM +0800, Umarzuki Mochlis wrote:
 2009/12/27 Osamu Aoki os...@debian.org
 
 set my cpufreq to conservative but does this setup shuts down wireless
 card from time to time because my wireless connection sometimes goes on and
 off?

I do not know exactly your situation but wireless connection breakage
may be different issue.  I have backported network-manager installed.
This type of software should reconnect.  If you are using barebone
ifupdown and /etc/network/interfaces, this may not respond to breakage
easily unless you dd very fancy set-up.

Osamu


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Re: running powernowd on debian lenny

2009-12-26 Thread Dave Witbrodt

Umarzuki Mochlis wrote:
2009/12/27 Dave Witbrodt dawit...@sbcglobal.net 
Umarzuki Mochlis wrote:

2009/12/27 Dave Witbrodt dawit...@sbcglobal.net
Umarzuki Mochlis wrote:

   I have a cq40-115au latop with AMD Turion x2 RM-70 processor.

   I want to enable powernowd. After i compiled it from source


   Because you built your own, it becomes more difficult for the
rest
   of us to help you.  The Debian 'powernowd' package has been
altered
   from upstream to put its configuration options in
   /etc/default/powernowd.  My answers below are from my own
   experiences using the Debian 'powernowd' package; you will
have to
   read the documentation in the source code, and figure out how to
   translate my answers to work for your own setup.  (In my view, it
   was a waste of time for you to compile your own 'powernowd',
since
   Debian already has the package.)


i had removed it (now) with #make clean
#rm -f /usr/bin/powernowd
 and installed powernowd package, enabled needed modules

#modprobe cpufreq_userspace powernow-k8


So, did that work or not?


i'm still having the same failure message, there's something amiss from 
what i had done?


Definitely.  If your setup was correct, it would be working.

I would like to see the output from the following commands:

ls  -dl  /s*

mount

lsmod

cat /etc/default/powernowd



So, you have an old kernel that defaults to performance.  That
will cause your CPU to run at full speed, instead of cycling down
when not needed.

this had caused my laptop to shutdown when playing games like secret 
maryo chronicles


That would be an overheating issue.  You have a hardware problem with 
your laptop not keeping itself cool.  CPU frequency controlling software 
is meant to extend your battery life, not to act as a bandaid for 
inadequate CPU cooling.  Any time that you start using your laptop 
heavily, the software will boost the frequency and you will have the 
same problems with shutdowns anyway.


The only problems that will be solved by running 'powernowd' (or 
switching to CPU_FREQ_ONDEMAND) are longer battery life and lower temps 
when not being used for demanding tasks.




   What is in /etc/fstab?  If you installed using a
   Debian installer, you should have a line like this:

  sysfs  /sys  sysfs  defaults  0  0


# file system mount point   type  options   dump
 pass
proc/proc   procdefaults0   0
/dev/sda1   /   ext3errors=remount-ro 0   1
/dev/sda2   /home   ext3defaults0   2
/dev/sda5   noneswapsw  0   0
/dev/scd0   /media/cdrom0   udf,iso9660 user,noauto 0  
0

sysfs /sys sysfs defaults 0 0

Looks OK.

the last line was just added by me


Oh, I misinterpreted your response as meaning it was already in 'fstab'. 
 How did you install Debian, so that the sysfs line was _not_ in 
'fstab' to begin with?



DW


--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org