LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 11-07-2012, 09:56 AM   #1
slackuser998
LQ Newbie
 
Registered: Sep 2009
Posts: 3

Rep: Reputation: 1
KDE changing hard disk parameters on start up - ala hdparm


I have Slackware 14 on my Asus laptop. The default disk spin down is way too aggressive. I've been trying to change this. I used hdparm on boot, in rc.local as follows:

hdparm -B 255 -S 251 /dev/sda

This appear to work fine, I verify it with "# hdparm -I /dev/sda". The output indicates "Advanced power management level: disabled". Great.

Then I start KDE. All the sudden the hard disk parameters are changed, as I see when I run hdparm (as root) in a console. WTF?

If I manually run (as root) /etc/rc.d/rc.local (with the hdparm stuff) again, in a console, then the hard disk is reset as I intended. So far KDE doesn't seem to reset the hard disk parameters while it is running. So the changes appear to be made only on KDE startup.

Does anyone know about this, where it happens or how to disable it conveniently. Manually running hdparm in a console after KDE is started is a pain. I could put the hdparm stuff in a KDE startup script (for a single user laptop), however this is hackish. Is there a better way? Thanks.
 
Old 11-07-2012, 10:33 AM   #2
guanx
Senior Member
 
Registered: Dec 2008
Posts: 1,014

Rep: Reputation: 146Reputation: 146
Are you on AC power? Did you try to tune the pm-utils parameters?
 
1 members found this post helpful.
Old 11-08-2012, 09:38 AM   #3
slackuser998
LQ Newbie
 
Registered: Sep 2009
Posts: 3

Original Poster
Rep: Reputation: 1
guanx,

First, I'm definitely on battery, and not AC. Also, no, I'm not using the pm-utils to tune the parameters. I've not manually set up the pm-utils to run, and they don't appear to be setup by default in Slackware 14.

All,

In addition, a bit more testing has disclosed some more information. If I start Fluxbox (and X11), rather than KDE (and X11), then the hard disk parameters are not changed. Thus it appears that this is a KDE thing and not an X11 thing.
 
Old 11-08-2012, 02:59 PM   #4
guanx
Senior Member
 
Registered: Dec 2008
Posts: 1,014

Rep: Reputation: 146Reputation: 146
I think pm-utils is taking care of your hard disk. This is my config for pm-utils:
Code:
$ cat /etc/pm/config.d/harddrive 
#!/bin/sh

# Default values on AC
DRIVE_SPINDOWN_VALUE_AC="${DRIVE_SPINDOWN_VALUE_AC:-0}"
DRIVE_WRITE_CACHE_AC="${DRIVE_WRITE_CACHE_AC:-1}"
DRIVE_POWER_MGMT_AC="${DRIVE_POWER_MGMT_AC:-254}"
DRIVE_ACOUSTIC_MGMT_AC="${DRIVE_ACOUSTIC_MGMT_AC:-0}"

# Default values on battery
DRIVE_SPINDOWN_VALUE_BAT="${DRIVE_SPINDOWN_VALUE_BAT:-60}"
DRIVE_WRITE_CACHE_BAT="${DRIVE_WRITE_CACHE_BAT:-1}"
DRIVE_POWER_MGMT_BAT="${DRIVE_POWER_MGMT_BAT:-252}"
DRIVE_ACOUSTIC_MGMT_BAT="${DRIVE_ACOUSTIC_MGMT_BAT:-254}"
Now my hard disk spins down much less frequently than by default (when on battery). If in question, see comments in pm-utils scripts, and man hdparm.

.

Last edited by guanx; 11-08-2012 at 05:09 PM.
 
1 members found this post helpful.
  


Reply

Tags
hard disk, hdparm, kde


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] changing GRUB from an external hard disk to the internal hard disk of my lap eco123 Linux - Newbie 2 05-15-2010 12:20 PM
hdparm parameters trent1980 Linux - Hardware 2 11-02-2009 03:27 PM
My hard disk won't spin down using hdparm -S24 /dev/hdb mesh2005 Linux - General 0 06-13-2007 02:23 AM
Hard disk parameters arunka Linux - Hardware 8 02-09-2006 04:43 AM
Hard Disk Timeout/Standby BIOS/hdparm win32sux Linux - Hardware 4 02-01-2005 12:05 AM


All times are GMT -5. The time now is 02:03 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration