summaryrefslogtreecommitdiff
path: root/ezjail-admin
diff options
context:
space:
mode:
authorerdgeist <erdgeist@erdgeist.org>2012-01-14 20:00:55 +0000
committererdgeist <erdgeist@erdgeist.org>2012-01-14 20:00:55 +0000
commitcea94f977ddbc4964c2d20927cf287807377bc7f (patch)
tree68de740d0af12f2a08c8da53ffcc3d62897f0669 /ezjail-admin
parent6b516a39054040795a2c73d97e2c196e1fb29dbf (diff)
Fix regex to grep for pids in a running Jail. Thanks to Thomas Steen Rasmussen.
Diffstat (limited to 'ezjail-admin')
-rwxr-xr-xezjail-admin4
1 files changed, 2 insertions, 2 deletions
diff --git a/ezjail-admin b/ezjail-admin
index c923506..1748436 100755
--- a/ezjail-admin
+++ b/ezjail-admin
@@ -729,10 +729,10 @@ EOF
729 jail_pids=`pgrep $jail_ids` 729 jail_pids=`pgrep $jail_ids`
730 730
731 # expand pids to form a greppable expression 731 # expand pids to form a greppable expression
732 jail_grep=`echo $jail_pids | sed -E -e"s/ /)|(/g" -e"s/^/(/" -e"s/$/)/"` 732 jail_grep=`echo $jail_pids | sed -E -e"s/ / )|( /g" -e"s/^/( /" -e"s/$/ )/"`
733 733
734 IFS=_ 734 IFS=_
735 ezjail_listener=`sockstat -46l | grep -E -e "\*:[[:digit:]]" | grep -E -e " ${jail_grep} "` 735 ezjail_listener=`sockstat -46l | grep -E -e "\*:[[:digit:]]" | grep -E -e "${jail_grep}"`
736 [ $? -eq 0 ] && echo -e "Warning: Some services already seem to be listening on all IP, (including ${ezjail_ip})\n This may cause some confusion, here they are:\n${ezjail_listener}" 736 [ $? -eq 0 ] && echo -e "Warning: Some services already seem to be listening on all IP, (including ${ezjail_ip})\n This may cause some confusion, here they are:\n${ezjail_listener}"
737 IFS=, 737 IFS=,
738 done 738 done