On 09/02/2017 11:05 PM, b17 wrote:
> Package: hdparm
> Version: 9.51+ds-1
> Severity: wishlist
>
> Dear Maintainer,
> I know I must be missing something, but I just can't find the way to get
> hdparm to return to /etc/hdparm.conf initial state.
>
> There is no init script, no service file?

There is no need in a service or init script, because hdparm options are
handled by udev on system start.

Having an init script will not help reseting any manually set options,
unless these options are defined in the hdparm.conf and the default
hdparm.conf comes without any special option set.

>
> I have looked at the man pages for hdparm and hdparm.conf and read
> what's available in /usr/share/doc/hdparm.  Looked at some closed bugs
> from the changelog, and i see when the init script was removed, but
didn't
> understand exactly why.
>
> Also I used find and located the /lib/udev/hdparm script and also the
> /lib/systemd/system-sleep/hdparm script, which runs the
> /usr/lib/pm-utils/power.d/95hdparm-apm script...
>
> but holy cow, I'm not sure I want to go around popping scripts by trial
> and error with a util like hdparm, sounds risky.
>
> There must be a simple way, after adjusting settings with /sbin/hdparm to
> return to default initialization found in /etc/hdparm.conf but I can't
find
> it.

I see, yes this is a useful feature and should be documented.
As the workaround for the absent init script one can use the following
command to reset settings defined in the hdparm.conf:

  DEVNAME=/dev/<DISK> /lib/udev/hdparm

Hope this helps.
Alex

Reply via email to