Red Hat Bugzilla – Bug 108048
failed start shouldn't touch(1) /var/lock/subsys/...
Last modified: 2007-04-18 12:58:47 EDT
Description of problem:
I use a makefile in /etc/sysconfig that restarts services if their configs have
changed, using /var/lock/subsys/... as the build target and the config as the
input like so:
/var/lock/subsys/iptables : iptables
only it doesn't work so well with the current startup scripts if there is a
config problem because the lockfile gets touched even if the init failed.
Here's one [partial?] fix to get you started...
--- iptables~ 2003-08-25 22:02:39.000000000 -0700
+++ iptables 2003-10-26 18:24:11.000000000 -0800
@@ -78,11 +78,13 @@
for i in $chains; do iptables -t $i -Z; done
echo -n $"Applying iptables firewall rules: "
grep -v "^[[:space:]]*#" $IPTABLES_CONFIG | grep -v
'^[[:space:]]*$' | /sbin/iptables-restore -c && \
success || \
+ ) &&
Fixed since fc1.