Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
baselayout1.start commands NOT executing [SOLVED]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
albright
Advocate
Advocate


Joined: 16 Nov 2003
Posts: 2588
Location: Near Toronto

PostPosted: Tue Jul 23, 2013 2:46 pm    Post subject: baselayout1.start commands NOT executing [SOLVED] Reply with quote

/etc/local.d/baselayout1.start runs a script which
sets powertop recommended parameters of
various kinds

here is the script:
Code:
#!/bin/bash
# powertop recommended power saving tweaks
echo '1500' > '/proc/sys/vm/dirty_writeback_centisecs'
echo 'min_power' > '/sys/class/scsi_host/host0/link_power_management_policy'
echo 'min_power' > '/sys/class/scsi_host/host1/link_power_management_policy'
echo 'min_power' > '/sys/class/scsi_host/host2/link_power_management_policy'
echo '1' > '/sys/module/snd_hda_intel/parameters/power_save'
echo 'auto' > '/sys/bus/usb/devices/usb6/power/control'
echo 'auto' > '/sys/bus/usb/devices/1-2/power/control'
echo 'auto' > '/sys/bus/usb/devices/usb1/power/control'
echo 'auto' > '/sys/bus/usb/devices/usb2/power/control'
echo 'auto' > '/sys/bus/usb/devices/usb5/power/control'
echo 'auto' > '/sys/bus/usb/devices/usb3/power/control'
echo 'auto' > '/sys/bus/usb/devices/usb7/power/control'
echo 'auto' > '/sys/bus/usb/devices/usb4/power/control'
iw dev wlan0 set power_save on


most of these commands are executed but some are not,
namely
Code:
echo '1500' > '/proc/sys/vm/dirty_writeback_centisecs'
echo 'min_power' > '/sys/class/scsi_host/host0/link_power_management_policy'
echo 'min_power' > '/sys/class/scsi_host/host1/link_power_management_policy'
echo 'min_power' > '/sys/class/scsi_host/host2/link_power_management_policy'
echo '1' > '/sys/module/snd_hda_intel/parameters/power_save'

If I run the script manually all commands are executed.
Do I have to run the "bad" commands later ... or what?
_________________
.... there is nothing - absolutely nothing - half so much worth
doing as simply messing about with Linux ...
(apologies to Kenneth Graeme)


Last edited by albright on Wed Jul 24, 2013 12:42 pm; edited 1 time in total
Back to top
View user's profile Send private message
broken_chaos
Guru
Guru


Joined: 18 Jan 2006
Posts: 370
Location: Ontario, Canada

PostPosted: Tue Jul 23, 2013 11:22 pm    Post subject: Reply with quote

How can you tell they're not executed? The parameters aren't set properly later?

If that's the case, are you running any power management software? pm-utils, laptop-mode-tools, or anything similar? If so, it likely has a script somewhere which gets executed later than your local script, which sets those values itself.
Back to top
View user's profile Send private message
albright
Advocate
Advocate


Joined: 16 Nov 2003
Posts: 2588
Location: Near Toronto

PostPosted: Wed Jul 24, 2013 12:41 pm    Post subject: Reply with quote

thanks for the clue, broken-chaos

laptop-mode tools was set to not enable power saving
on usb when on AC and it rewrote the values after
my baselayout.start script ran
_________________
.... there is nothing - absolutely nothing - half so much worth
doing as simply messing about with Linux ...
(apologies to Kenneth Graeme)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum