From abfdc877c6bae63381d01345462002eff496fd7b Mon Sep 17 00:00:00 2001 From: Jamie Gritton Date: Sat, 23 Apr 2016 16:23:01 +0000 Subject: [PATCH] Don't remove the /var/run/jail_name.id file if a jail fails to start. This messes up ezjail (and possibly others), when attempting to start a jail that already exists. PR: 208806 Reviewed by: tj MFC after: 5 days --- etc/rc.d/jail | 2 -- 1 file changed, 2 deletions(-) diff --git a/etc/rc.d/jail b/etc/rc.d/jail index 5e2c66aa082a..a42e450d2cd1 100755 --- a/etc/rc.d/jail +++ b/etc/rc.d/jail @@ -489,7 +489,6 @@ jail_start() if _jid=$($jail_jls -j $_j jid); then echo "$_jid" > /var/run/jail_${_j}.id else - rm -f /var/run/jail_${_j}.id echo " cannot start jail " \ "\"${_hostname:-${_j}}\": " fi @@ -513,7 +512,6 @@ jail_start() _jid=$($jail_jls -j $_j jid) echo $_jid > /var/run/jail_${_j}.id else - rm -f /var/run/jail_${_j}.id echo " cannot start jail " \ "\"${_hostname:-${_j}}\": " cat $_tmp