Date: Fri, 11 Sep 2015 15:42:18 +0100 (BST) From: Kevin Golding <kpg@caomhin.org> To: freebsd-ports@freebsd.org Subject: rc script problem - pidfile not being recognised Message-ID: <441028827.153.1441982537926.JavaMail.Kevin@Thoth> In-Reply-To: <425887562.141.1441981537083.JavaMail.Kevin@Thoth>
next in thread | previous in thread | raw e-mail | index | archive | help
I've been trying to work on a new port and it's my first that uses an rc script so I've been expecting a few bumps, but there's one thing I can't seem to fix and it's a blocker. I can't stop the daemon! It dopes create a pidfile so I have the following line in my script: pidfile="/var/run/${name}.pid" Alas... # service fuglu stop fuglu not running? (check /var/run/fuglu.pid). # cat /var/run/fuglu.pid 24013 I don't get it. It is the right process ID: # ps -waux | grep fuglu nobody 24013 0.0 0.5 139532 37372 - I 3:57PM 0:01.03 /usr/local/bin/python2.7 /usr/local/bin/fuglu --pidfile /var/r root 26179 0.0 0.0 18824 1976 0 S+ 4:30PM 0:00.00 grep fuglu I'm at a loss as to what to try, I feel I'm missing something blindingly obvious but it's a mystery to me so if anyone can wave the big red arrow at my mistake I'd be a happy chappy! Full fuglu.in below: #!/bin/sh # $FreeBSD$ # # PROVIDE: fuglu # REQUIRE: LOGIN # KEYWORD: shutdown # # Add these lines to /etc/rc.conf.local or /etc/rc.conf # to enable this service: # # fuglu_enable (bool): Set to NO by default. # Set it to YES to enable fuglu. . /etc/rc.subr name="fuglu" rcvar=fuglu_enable load_rc_config $name : ${fuglu_enable:=no} command=%%PREFIX%%/bin/${name} pidfile="/var/run/${name}.pid" run_rc_command "$1"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?441028827.153.1441982537926.JavaMail.Kevin>