#!/bin/sh # # xfs: Run the devfsd actions # # Version: @(#) /etc/rc.d/init.d/devfsd 1.4 # # chkconfig: 2345 99 10 # description: Cleaunup dynamic desktop directories and call devfsd actions. # # processname: devfsd # config: /etc/devsfsd.config # Source function library. . /etc/rc.d/init.d/functions subsys=/var/lock/subsys/devfsd start () { # Restart devfsd actions now that the filesystems are ready if [ -c /dev/.devfsd ]; then if [ -x /sbin/devfsd ]; then [[ -e $subsys ]] && return # cleanup dynamic desktop directories before calling devfsd actions rm -f /usr/share/gnome/desktop/* /usr/share/apps/kdesktop/Desktop/* pid=`pidof devfsd` [[ -z $pid ]] && return action "Running devfsd actions: " kill -HUP $pid # We don't want to run this on random runlevel changes. touch $subsys fi fi } #stop () #{ #} #{ killall -TERM devfsd; } # See how we were called. case "$1" in start) start ;; stop) rm -f $subsys ;; status) status devfsd ;; restart) # stop start ;; reload) # stop start ;; *) gprintf "*** Usage: devfsd {start|stop|status|restart}\n" exit 1 esac exit 0