Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:12.2:PowerPC
ushare
ushare-init_d-fix.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File ushare-init_d-fix.patch of Package ushare
--- ushare-1.1a/scripts/ushare.old 2008-10-26 14:32:49.000000000 +0100 +++ ushare-1.1a/scripts/ushare 2008-10-26 14:35:07.000000000 +0100 @@ -4,12 +4,12 @@ # ### BEGIN INIT INFO # Provides: ushare -# Required-Start: $local_fs $syslog $network +# Required-Start: $local_fs $remote_fs $syslog $network # Should-Start: -# Required-Stop: +# Required-Stop: $local_fs $remote_fs $syslog $network # Should-Stop: -# Default-Start: 2 3 4 5 -# Default-Stop: 0 1 6 +# Default-Start: 3 4 5 +# Default-Stop: 0 1 2 6 # Short-Description: uShare # Description: uShare UPnP (TM) A/V & DLNA Media Server # You should edit configuration in /etc/ushare.conf file @@ -24,18 +24,13 @@ CONFIGFILE=/etc/ushare.conf # abort if no executable exists -[ -x $DAEMON ] || exit 0 +[ -x $DAEMON ] || exit 5 # Get lsb functions . /lib/lsb/init-functions -. /etc/default/rcS [ -f /etc/default/ushare ] && . /etc/default/ushare -checkpid() { - [ -e $PIDFILE ] || touch $PIDFILE -} - check_shares() { if [ -r "$CONFIGFILE" ]; then . $CONFIGFILE @@ -46,35 +41,36 @@ case "$1" in start) - log_daemon_msg "Starting $DESC: $NAME" + echo -n "Starting $DESC: $NAME" if ! $(check_shares); then log_warning_msg "No shares avalaible ..." - log_end_msg 0 - else - checkpid - start-stop-daemon --start --quiet --background --oknodo \ - --make-pidfile --pidfile $PIDFILE \ - --exec $DAEMON -- $USHARE_OPTIONS - log_end_msg $? + rc_status -v1 fi + [ -e $PIDFILE ] || touch $PIDFILE + start_daemon -p $PIDFILE $DAEMON $USHARE_OPTIONS + rc_status -v ;; stop) - log_daemon_msg "Stopping $DESC: $NAME" - start-stop-daemon --stop --signal 2 --quiet --oknodo --pidfile $PIDFILE - log_end_msg $? + echo -n "Stopping $DESC: $NAME" + killproc -2 -p $PIDFILE $DAEMON + rc_status -v ;; reload|force-reload) - log_daemon_msg "Reloading $DESC: $NAME" - start-stop-daemon --stop --signal 1 --quiet --oknodo --pidfile $PIDFILE --exec $DAEMON - log_end_msg $? + echo -n "Reloading $DESC: $NAME" + killproc -1 -p $PIDFILE $DAEMON + rc_status -v ;; restart) $0 stop $0 start + rc_status + ;; + status) + checkproc -k -p $PIDFILE $DAEMON + rc_status -v ;; *) - N=/etc/init.d/$NAME - log_success_msg "Usage: $N {start|stop|restart|reload|force-reload}" + echo "Usage: $0 {start|stop|restart|reload|force-reload}" exit 1 ;; esac
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor