WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: laptop energy-saving managment  (Read 8003 times)

Offline alexo

  • Jr. Member
  • **
  • Posts: 97
laptop energy-saving managment
« on: October 24, 2015, 08:51:34 AM »
Hello,
I've checked up and set some config parameters in /usr/local/etc/laptop-mode/laptop-mode.conf

I then executed the manager with the following:

Code: [Select]
tc@alexo:~$ sudo /usr/local/etc/init.d/laptop-mode start
but this message appears on the prompt, leaving the command line busy

Code: [Select]
Unhandled kernel version: 3.16 ('uname -r' = '3.16.6-tinycore')

is there anything that I did not set up?

thank you

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: laptop energy-saving managment
« Reply #1 on: October 24, 2015, 09:47:37 AM »
I'd guess that the version in the repo is too old for the tc-6.x kernel?

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11701
Re: laptop energy-saving managment
« Reply #2 on: October 24, 2015, 09:51:55 AM »

Offline alexo

  • Jr. Member
  • **
  • Posts: 97
Re: laptop energy-saving managment
« Reply #3 on: October 25, 2015, 08:21:55 AM »
Thank you for your replies, but now there's another problem:

the file laptop_mode is not in the folder /usr/sbin
but in /tmp/tcloop/laptop-mode-tools/usr/local/sbin

and if I try to modify it as root and save the changes I get the error that the filesystem is read-only.

So I copied the laptop_mode file in /usr/sbin and modified as required, but the same

Unhandled kernel version: 3.16 ('uname -r' = '3.16.6-tinycore') message appears.

how can I solve the problem?





Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: laptop energy-saving managment
« Reply #4 on: October 25, 2015, 08:39:12 AM »
I have laptop-mode-tools working, I can upload it once the server is back up.

Note that you should copy /tmp/tcloop/laptop-mode-tools/usr/local/sbin/laptop_mode to /usr/local/sbin, make the changes and then things will work.

Offline alexo

  • Jr. Member
  • **
  • Posts: 97
Re: laptop energy-saving managment
« Reply #5 on: October 25, 2015, 10:15:05 AM »
juanito,
the copy and modifications went well (I had to chmod the /usr/local/share/laptop_tool file to edit it)

Shouldn't be the package manager to do this task for the user?
Now when I start the laptop energy saving mode I get these messages:

Code: [Select]
tc@box:~$ sudo /usr/local/etc/init.d/laptop-mode start
device node not found
failed - udev not active?
failed - unknown name
hdparm: can't open '/dev/hda': No such device or address
device node not found
failed - udev not active?
failed - unknown name
hdparm: can't open '/dev/hda': No such device or address
device node not found
failed - udev not active?
failed - unknown name
hdparm: can't open '/dev/hdb': No such device or address
device node not found
failed - udev not active?
failed - unknown name
hdparm: can't open '/dev/hdb': No such device or address
device node not found
failed - udev not active?
failed - unknown name
hdparm: can't open '/dev/hdc': No such device or address
device node not found
failed - udev not active?
failed - unknown name
hdparm: can't open '/dev/hdc': No such device or address
device node not found
failed - udev not active?
failed - unknown name
hdparm: can't open '/dev/hdd': No such device or address
device node not found
failed - udev not active?
failed - unknown name
hdparm: can't open '/dev/hdd': No such device or address
failed - udev not active?
failed - udev not active?
failed - udev not active?
failed - udev not active?
Laptop mode
enabled, not active

what are those messages??

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: laptop energy-saving managment
« Reply #6 on: October 25, 2015, 10:34:40 AM »
It looks like you need to edit the config file to suit your hardware - i.e. only sdx and no hdx

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: laptop energy-saving managment
« Reply #7 on: October 28, 2015, 01:26:04 AM »
posted

Offline alexo

  • Jr. Member
  • **
  • Posts: 97
Re: laptop energy-saving managment
« Reply #8 on: October 29, 2015, 10:29:48 AM »
I uploaded laptop-tools from repo -> ok
Selected to load on boot -> ok
edited /usr/local/etc/laptop-mode/laptop-mode.conf to my needs -> ok
started laptop-mode with

Code: [Select]
sudo /usr/local/etc/init.d/laptop-mode start
...nothing happens

Maybe I'm dumb but even if I have choosen to start laptop-mode on AC power and when lid is closed nothing happens as time passes by or when I close the lid.

I noticed that after reboot changes to laptop-mode.conf are lost so I added it to /opt/.filetool.lst
and to start automatically the tool  after logging in I added

Code: [Select]
/usr/local/etc/init.d/laptop-mode start
in bootlocal.sh

cpu fan is always on and laptop doesn't go in suspend mode.

what's wrong?



Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: laptop energy-saving managment
« Reply #9 on: October 29, 2015, 11:05:34 AM »
Did you also load and start acpid as stated in the info file?

Offline alexo

  • Jr. Member
  • **
  • Posts: 97
Re: laptop energy-saving managment
« Reply #10 on: October 29, 2015, 04:32:53 PM »
acpid was not running, so I started it.
But laptop mode seems not to work.

This id the output of sudo /usr/local/etc/init.d/laptop-mode status
Code: [Select]
Laptop mode status:

Mounts:
   rootfs on / type rootfs (rw,size=1857104k,nr_inodes=681908)
   proc on /proc type proc (rw,relatime)
   sysfs on /sys type sysfs (rw,relatime)
   devpts on /dev/pts type devpts (rw,relatime,mode=600,ptmxmode=000)
   tmpfs on /dev/shm type tmpfs (rw,relatime)
   fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
   /dev/sdb1 on /mnt/sdb1 type ext4 (rw,relatime,commit=360,data=ordered)
   /dev/loop0 on /tmp/tcloop/libXdmcp type squashfs (ro,relatime)
   /dev/loop1 on /tmp/tcloop/libXau type squashfs (ro,relatime)
   /dev/loop2 on /tmp/tcloop/libxcb type squashfs (ro,relatime)
   /dev/loop3 on /tmp/tcloop/libX11 type squashfs (ro,relatime)
   /dev/loop4 on /tmp/tcloop/libXrender type squashfs (ro,relatime)
   /dev/loop5 on /tmp/tcloop/libXext type squashfs (ro,relatime)
   /dev/loop6 on /tmp/tcloop/libXrandr type squashfs (ro,relatime)
   /dev/loop7 on /tmp/tcloop/libXpm type squashfs (ro,relatime)
   /dev/loop8 on /tmp/tcloop/libSM type squashfs (ro,relatime)
   /dev/loop9 on /tmp/tcloop/libICE type squashfs (ro,relatime)
   /dev/loop10 on /tmp/tcloop/libXt type squashfs (ro,relatime)
   /dev/loop11 on /tmp/tcloop/libXmu type squashfs (ro,relatime)
   /dev/loop12 on /tmp/tcloop/libXi type squashfs (ro,relatime)
   /dev/loop13 on /tmp/tcloop/libfontenc type squashfs (ro,relatime)
   /dev/loop14 on /tmp/tcloop/freetype type squashfs (ro,relatime)
   /dev/loop15 on /tmp/tcloop/libXfont type squashfs (ro,relatime)
   /dev/loop16 on /tmp/tcloop/Xlibs type squashfs (ro,relatime)
   /dev/loop17 on /tmp/tcloop/libpng type squashfs (ro,relatime)
   /dev/loop18 on /tmp/tcloop/libjpeg-turbo type squashfs (ro,relatime)
   /dev/loop19 on /tmp/tcloop/imlib2 type squashfs (ro,relatime)
   /dev/loop20 on /tmp/tcloop/imlib2-bin type squashfs (ro,relatime)
   /dev/loop21 on /tmp/tcloop/fltk-1.3 type squashfs (ro,relatime)
   /dev/loop22 on /tmp/tcloop/Xprogs type squashfs (ro,relatime)
   /dev/loop23 on /tmp/tcloop/Xvesa type squashfs (ro,relatime)
   /dev/loop24 on /tmp/tcloop/aterm type squashfs (ro,relatime)
   /dev/loop25 on /tmp/tcloop/fltk-1.1.10 type squashfs (ro,relatime)
   /dev/loop26 on /tmp/tcloop/flwm_topside type squashfs (ro,relatime)
   /dev/loop27 on /tmp/tcloop/expat2 type squashfs (ro,relatime)
   /dev/loop28 on /tmp/tcloop/fontconfig type squashfs (ro,relatime)
   /dev/loop29 on /tmp/tcloop/libXft type squashfs (ro,relatime)
   /dev/loop30 on /tmp/tcloop/libXinerama type squashfs (ro,relatime)
   /dev/loop31 on /tmp/tcloop/libXfixes type squashfs (ro,relatime)
   /dev/loop32 on /tmp/tcloop/libXcursor type squashfs (ro,relatime)
   /dev/loop33 on /tmp/tcloop/liblzma type squashfs (ro,relatime)
   /dev/loop34 on /tmp/tcloop/libffi type squashfs (ro,relatime)
   /dev/loop35 on /tmp/tcloop/libtiff type squashfs (ro,relatime)
   /dev/loop36 on /tmp/tcloop/gamin type squashfs (ro,relatime)
   /dev/loop37 on /tmp/tcloop/glib2 type squashfs (ro,relatime)
   /dev/loop38 on /tmp/tcloop/gdk-pixbuf2 type squashfs (ro,relatime)
   /dev/loop39 on /tmp/tcloop/wbar type squashfs (ro,relatime)
   /dev/loop40 on /tmp/tcloop/libxml2 type squashfs (ro,relatime)
   /dev/loop41 on /tmp/tcloop/libcroco type squashfs (ro,relatime)
   /dev/loop42 on /tmp/tcloop/harfbuzz type squashfs (ro,relatime)
   /dev/loop43 on /tmp/tcloop/libxshmfence type squashfs (ro,relatime)
   /dev/loop44 on /tmp/tcloop/udev-lib type squashfs (ro,relatime)
   /dev/loop45 on /tmp/tcloop/libpciaccess type squashfs (ro,relatime)
   /dev/loop46 on /tmp/tcloop/libdrm type squashfs (ro,relatime)
   /dev/loop47 on /tmp/tcloop/libXxf86vm type squashfs (ro,relatime)
   /dev/loop48 on /tmp/tcloop/libXdamage type squashfs (ro,relatime)
   /dev/loop49 on /tmp/tcloop/libGL type squashfs (ro,relatime)
   /dev/loop50 on /tmp/tcloop/libEGL type squashfs (ro,relatime)
   /dev/loop51 on /tmp/tcloop/pixman type squashfs (ro,relatime)
   /dev/loop52 on /tmp/tcloop/cairo type squashfs (ro,relatime)
   /dev/loop53 on /tmp/tcloop/pango type squashfs (ro,relatime)
   /dev/loop54 on /tmp/tcloop/librsvg type squashfs (ro,relatime)
   /dev/loop55 on /tmp/tcloop/libstartup-notification type squashfs (ro,relatime)
   /dev/loop56 on /tmp/tcloop/libXcomposite type squashfs (ro,relatime)
   /dev/loop57 on /tmp/tcloop/atk type squashfs (ro,relatime)
   /dev/loop58 on /tmp/tcloop/gtk2 type squashfs (ro,relatime)
   /dev/loop59 on /tmp/tcloop/ttf-bitstream-vera type squashfs (ro,relatime)
   /dev/loop60 on /tmp/tcloop/libglade type squashfs (ro,relatime)
   /dev/loop61 on /tmp/tcloop/openbox type squashfs (ro,relatime)
   /dev/loop62 on /tmp/tcloop/wireless-3.16.6-tinycore type squashfs (ro,relatime)
   /dev/loop63 on /tmp/tcloop/libiw type squashfs (ro,relatime)
   /dev/loop64 on /tmp/tcloop/wireless_tools type squashfs (ro,relatime)
   /dev/loop65 on /tmp/tcloop/ncurses type squashfs (ro,relatime)
   /dev/loop66 on /tmp/tcloop/readline type squashfs (ro,relatime)
   /dev/loop67 on /tmp/tcloop/openssl type squashfs (ro,relatime)
   /dev/loop68 on /tmp/tcloop/libnl type squashfs (ro,relatime)
   /dev/loop69 on /tmp/tcloop/wpa_supplicant type squashfs (ro,relatime)
   /dev/loop70 on /tmp/tcloop/wifi type squashfs (ro,relatime)
   /dev/loop71 on /tmp/tcloop/wl-modules-3.16.6-tinycore type squashfs (ro,relatime)
   /dev/loop72 on /tmp/tcloop/iw type squashfs (ro,relatime)
   /dev/loop73 on /tmp/tcloop/libpci type squashfs (ro,relatime)
   /dev/loop74 on /tmp/tcloop/pci-utils type squashfs (ro,relatime)
   /dev/loop75 on /tmp/tcloop/firmware-atheros type squashfs (ro,relatime)
   /dev/loop76 on /tmp/tcloop/firmware-broadcom_bnx2 type squashfs (ro,relatime)
   /dev/loop77 on /tmp/tcloop/firmware-broadcom_bcm43xx type squashfs (ro,relatime)
   /dev/loop78 on /tmp/tcloop/firmware-ipw2100 type squashfs (ro,relatime)
   /dev/loop79 on /tmp/tcloop/firmware-ipw2200 type squashfs (ro,relatime)
   /dev/loop80 on /tmp/tcloop/firmware-iwlwifi type squashfs (ro,relatime)
   /dev/loop81 on /tmp/tcloop/firmware_iwlwifi-7260 type squashfs (ro,relatime)
   /dev/loop82 on /tmp/tcloop/firmware-libertas type squashfs (ro,relatime)
   /dev/loop83 on /tmp/tcloop/firmware-myri10ge type squashfs (ro,relatime)
   /dev/loop84 on /tmp/tcloop/firmware-netxen type squashfs (ro,relatime)
   /dev/loop85 on /tmp/tcloop/firmware-openfwwf type squashfs (ro,relatime)
   /dev/loop86 on /tmp/tcloop/firmware-radeon type squashfs (ro,relatime)
   /dev/loop87 on /tmp/tcloop/firmware-ti-connectivity type squashfs (ro,relatime)
   /dev/loop88 on /tmp/tcloop/firmware-ueagle-atm type squashfs (ro,relatime)
   /dev/loop89 on /tmp/tcloop/firmware-vxge type squashfs (ro,relatime)
   /dev/loop90 on /tmp/tcloop/firmware-iwimax type squashfs (ro,relatime)
   /dev/loop91 on /tmp/tcloop/firmware-zd1211 type squashfs (ro,relatime)
   /dev/loop92 on /tmp/tcloop/firmware type squashfs (ro,relatime)
   /dev/loop93 on /tmp/tcloop/kmaps type squashfs (ro,relatime)
   /dev/loop94 on /tmp/tcloop/nano type squashfs (ro,relatime)
   /dev/loop95 on /tmp/tcloop/hicolor-icon-theme type squashfs (ro,relatime)
   /dev/loop96 on /tmp/tcloop/obconf type squashfs (ro,relatime)
   /dev/loop97 on /tmp/tcloop/lcms2 type squashfs (ro,relatime)
   /dev/loop98 on /tmp/tcloop/gcc_libs type squashfs (ro,relatime)
   /dev/loop99 on /tmp/tcloop/dbus type squashfs (ro,relatime)
   /dev/loop100 on /tmp/tcloop/libavahi type squashfs (ro,relatime)
   /dev/loop101 on /tmp/tcloop/libcups type squashfs (ro,relatime)
   /dev/loop102 on /tmp/tcloop/ghostscript type squashfs (ro,relatime)
   /dev/loop103 on /tmp/tcloop/bzip2-lib type squashfs (ro,relatime)
   /dev/loop104 on /tmp/tcloop/pcre type squashfs (ro,relatime)
   /dev/loop105 on /tmp/tcloop/qpdf type squashfs (ro,relatime)
   /dev/loop106 on /tmp/tcloop/poppler type squashfs (ro,relatime)
   /dev/loop107 on /tmp/tcloop/ijs type squashfs (ro,relatime)
   /dev/loop108 on /tmp/tcloop/cups-filters type squashfs (ro,relatime)
   /dev/loop109 on /tmp/tcloop/cups type squashfs (ro,relatime)
   /dev/loop110 on /tmp/tcloop/net-snmp type squashfs (ro,relatime)
   /dev/loop111 on /tmp/tcloop/libieee1284 type squashfs (ro,relatime)
   /dev/loop112 on /tmp/tcloop/input-joystick-3.16.6-tinycore type squashfs (ro,relatime)
   /dev/loop113 on /tmp/tcloop/alsa-modules-3.16.6-tinycore type squashfs (ro,relatime)
   /dev/loop114 on /tmp/tcloop/i2c-3.16.6-tinycore type squashfs (ro,relatime)
   /dev/loop115 on /tmp/tcloop/v4l-dvb-3.16.6-tinycore type squashfs (ro,relatime)
   /dev/loop116 on /tmp/tcloop/libv4l type squashfs (ro,relatime)
   /dev/loop117 on /tmp/tcloop/libusb type squashfs (ro,relatime)
   /dev/loop118 on /tmp/tcloop/libsane type squashfs (ro,relatime)
   /dev/loop119 on /tmp/tcloop/gdbm type squashfs (ro,relatime)
   /dev/loop120 on /tmp/tcloop/sqlite3 type squashfs (ro,relatime)
   /dev/loop121 on /tmp/tcloop/python type squashfs (ro,relatime)
   /dev/loop122 on /tmp/tcloop/dbus-glib type squashfs (ro,relatime)
   /dev/loop123 on /tmp/tcloop/dbus-python type squashfs (ro,relatime)
   /dev/loop124 on /tmp/tcloop/hplip type squashfs (ro,relatime)
   /dev/loop125 on /tmp/tcloop/libasound type squashfs (ro,relatime)
   /dev/loop126 on /tmp/tcloop/alsa type squashfs (ro,relatime)
   /dev/loop127 on /tmp/tcloop/nspr type squashfs (ro,relatime)
   /dev/loop128 on /tmp/tcloop/nss type squashfs (ro,relatime)
   /dev/loop129 on /tmp/tcloop/libgpg-error type squashfs (ro,relatime)
   /dev/loop130 on /tmp/tcloop/libgcrypt type squashfs (ro,relatime)
   /dev/loop131 on /tmp/tcloop/libssh2 type squashfs (ro,relatime)
   /dev/loop132 on /tmp/tcloop/libidn type squashfs (ro,relatime)
   /dev/loop133 on /tmp/tcloop/curl type squashfs (ro,relatime)
   /dev/loop134 on /tmp/tcloop/flash11 type squashfs (ro,relatime)
   /dev/loop135 on /tmp/tcloop/acpid type squashfs (ro,relatime)
   /dev/loop136 on /tmp/tcloop/laptop-mode-tools type squashfs (ro,relatime)
   /dev/loop137 on /tmp/tcloop/man-pages type squashfs (ro,relatime)
   /dev/loop138 on /tmp/tcloop/groff type squashfs (ro,relatime)
   /dev/loop139 on /tmp/tcloop/less type squashfs (ro,relatime)
   /dev/loop140 on /tmp/tcloop/man type squashfs (ro,relatime)
   /dev/loop141 on /tmp/tcloop/xscreensaver-base type squashfs (ro,relatime)
 
Drive power status:
   
   /dev/sdb:
    drive state is:  unknown
 
(NOTE: drive settings affected by Laptop Mode cannot be retrieved.)
 
Laptop Mode Tools is allowed to run: /var/run/laptop-mode-tools/enabled exists.
 
/proc/sys/vm/laptop_mode:
   0
 
/proc/sys/vm/dirty_ratio:
   20
 
/proc/sys/vm/dirty_background_ratio:
   10
 
/proc/sys/vm/dirty_expire_centisecs:
   3000
 
/proc/sys/vm/dirty_writeback_centisecs:
   500
 
/proc/acpi/button/lid/LID0/state:
   state:      open
 
/proc/acpi/ac_adapter/AC/state:
   state:                   on-line
 
/proc/acpi/battery/BAT0/state:
   present:                 yes
   capacity state:          ok
   charging state:          charged
   present rate:            0 mA
   remaining capacity:      1320 mAh
   present voltage:         12478 mV
 
/sys/class/power_supply/AC/online:
   1


My laptop is an old Acer Aspire 5315
TC 6.4 is installed on a 2GB USB pen drive
formatted as ext4

no swap partition on the drive

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: laptop energy-saving managment
« Reply #11 on: October 30, 2015, 02:31:15 AM »
As far as I remember, if you see this:
Code: [Select]
Laptop Mode Tools is allowed to run: /var/run/laptop-mode-tools/enabled exists.
..things are working.

What happens if you then disconnect from a/c power?

Offline alexo

  • Jr. Member
  • **
  • Posts: 97
Re: laptop energy-saving managment
« Reply #12 on: October 31, 2015, 05:48:54 AM »
Hi Juanito,

laptop mode seems not to work even on battery usage.
I have found two directories where laptop-tool seem to reside:
/usr/local/etc/laptop-mode, where I set laptop-mode.config to my wishes
and
/tmp/tcloop/laptop-mode-tools/usr/local/share/laptop-mode-tools and its subfolders, where there is no trace of my changes.
I don't know where to put my hands because there are too many folders related to this service.

By the way, I installed xscreensaver and set it to activate the energy saving mode, but it cannot start it.






Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: laptop energy-saving managment
« Reply #13 on: October 31, 2015, 05:58:50 AM »
The correct location for the laptop-mode-tools config is in /usr/local/etc/laptop-mode - you need to add this to your backup if you want  it to persist across re-boots.

Offline alexo

  • Jr. Member
  • **
  • Posts: 97
Re: laptop energy-saving managment
« Reply #14 on: October 31, 2015, 05:51:00 PM »
/usr/local/etc/laptop-mode is already in my /opt/.filetool.lst

when I told you that I saw two folders in which exists laptop-tools config file is because one of the two - the one in /usr/local/etc/laptop-mode - is the one that should be correct.
The other config file in /tmp/tcloop/laptop-mode-tools/usr/local/share/laptop-mode-tools/files/laptop-mode differs from the former and there is no way to modify it neither as root.