supervision - discussion about system services, daemon supervision, init, runlevel management, and tools such as s6 and runit
 help / color / mirror / Atom feed
From: "xavier dutoit" <xavier@sydesy.com>
Subject: pownernowd run script
Date: Mon, 3 Jul 2006 10:32:26 +0200	[thread overview]
Message-ID: <afacabbe0607030132u584dbdr924fde09ee45a66d@mail.gmail.com> (raw)

Hello,

I've written a run script for powernowd (tested on a sarge with
standard package):

#! /bin/sh
modprobe cpufreq-userspace
if [ -f /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor ]
  then
    exec /usr/sbin/powernowd -d
  else
    echo "required sysfs objects not found!"
    echo -e "\tRead /usr/share/doc/powernowd/README.Debian for more
information."
fi


I wasn't sure about how to deal with error messages if the proc can't
change its frequency. I kept what the init.d script did.

I hope it might be useful to someone, and forgive me if the code
doesn't do it the runit way, that's my first run script.

Any suggestion to improve more than welcome.


Xavier


             reply	other threads:[~2006-07-03  8:32 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-03  8:32 xavier dutoit [this message]
2006-07-04 14:46 ` Gerrit Pape

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=afacabbe0607030132u584dbdr924fde09ee45a66d@mail.gmail.com \
    --to=xavier@sydesy.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).