Eliminate 'try' command

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@5029 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2006-12-01 16:36:17 +00:00
parent 9e81065809
commit 5af734ca77
3 changed files with 18 additions and 25 deletions

View File

@ -12,6 +12,8 @@ Changes in 3.3.6
6) Fix safe- commands. 6) Fix safe- commands.
7) Remove 'try' command.
Changes in 3.3.5 Changes in 3.3.5
1) Restore default route when there are no 'balance' providers. 1) Restore default route when there are no 'balance' providers.

View File

@ -66,6 +66,10 @@ Other Changes in 3.3.6
Shorewall will use that support for the destination port when Shorewall will use that support for the destination port when
generating rules from entries in the /etc/shorewall/tcrules file. generating rules from entries in the /etc/shorewall/tcrules file.
5) The 'try' command has been removed. See the Migration
Considerations for information about how to accomplish the same
thing as 'try' in a better way.
Migration Considerations: Migration Considerations:
1) Shorewall supports the notion of "default actions". A default 1) Shorewall supports the notion of "default actions". A default
@ -106,6 +110,18 @@ Migration Considerations:
/etc/shorewall/action.Limit and/or /etc/shorewall/Limit if you have /etc/shorewall/action.Limit and/or /etc/shorewall/Limit if you have
them. them.
3) The 'shorewall try' command has been eliminated. The syntax of
'try' was:
shorewall try <config-dir> [ <timeout> ]
A better way to accomplish the same thing is:
shorewall save #Do this only once before you start testing
shorewall restart <config-dir> [ && sleep <timeout> && \
shorewall restore ]
New Features: New Features:
1) In order to accomodate small embedded applications, Shorewall 3.3 1) In order to accomodate small embedded applications, Shorewall 3.3

View File

@ -64,13 +64,6 @@
# shorewall show capabilities Display iptables/kernel capabilities # shorewall show capabilities Display iptables/kernel capabilities
# shorewall version Display the installed version id # shorewall version Display the installed version id
# shorewall check [ -e ] [ <directory> ] Dry-run compilation. # shorewall check [ -e ] [ <directory> ] Dry-run compilation.
# shorewall try <directory> [ <timeout> ] Try a new configuration and if
# it doesn't work, revert to the
# standard one. If a timeout is supplied
# the command reverts back to the
# standard configuration after that many
# seconds have elapsed after successfully
# starting the new configuration.
# shorewall logwatch [ refresh-interval ] Monitor the local log for Shorewall # shorewall logwatch [ refresh-interval ] Monitor the local log for Shorewall
# messages. # messages.
# shorewall drop <address> ... Temporarily drop all packets from the # shorewall drop <address> ... Temporarily drop all packets from the
@ -922,7 +915,6 @@ usage() # $1 = exit status
echo " start [ -f ] [ -n ] [ <directory> ]" echo " start [ -f ] [ -n ] [ <directory> ]"
echo " stop" echo " stop"
echo " status" echo " status"
echo " try <directory> [ <timeout> ]"
echo " version" echo " version"
echo " safe-start" echo " safe-start"
echo " safe-restart" echo " safe-restart"
@ -1199,23 +1191,6 @@ case "$COMMAND" in
version) version)
echo $version echo $version
;; ;;
try)
[ -n "$SHOREWALL_DIR" ] && startup_error "ERROR: -c option may not be used with \"try\""
[ $# -lt 2 -o $# -gt 3 ] && usage 1
VERBOSE=$(make_verbose)
[ -n "$NOROUTES" ] && NOROUTES=-n
export -n CONFIG_PATH
if ! $0 $debugging $VERBOSE -c $2 restart; then
if ! $IPTABLES -L shorewall > /dev/null 2> /dev/null; then
$0 $VERBOSE $NOROUTES start
fi
elif ! $IPTABLES -L shorewall > /dev/null 2> /dev/null; then
$0 $VERBOSE $NOROUTES start
elif [ $# -eq 3 ]; then
sleep $3
$0 $VERBOSE $NOROUTES restart
fi
;;
logwatch) logwatch)
logwatch_command $@ logwatch_command $@
;; ;;