Skip to content
Snippets Groups Projects
Commit 70b7a615 authored by Andrea Ieri's avatar Andrea Ieri
Browse files

Fixed misleading comment: the iptables rules for rfio are modified by...

Fixed misleading comment: the iptables rules for rfio are modified by castor-lib and not by CASTOR-client (which was dropped in 2.1.9-0)
parent 40623bb9
Branches
Tags
No related merge requests found
......@@ -7,10 +7,10 @@ if [ -e /etc/sysconfig/iptables ]; then
chain="RH-Firewall-1-INPUT"
%endif
# Update the iptables sysconfig file if necessary.
if ! /bin/grep -q "controlled by CASTOR-client RPM" /etc/sysconfig/iptables; then
if ! /bin/grep -q "controlled by castor-lib RPM" /etc/sysconfig/iptables; then
/bin/cat <<EOFiptable |\
/bin/sed -i.castor -e "/-A $chain -m state --state ESTABLISHED,RELATED -j ACCEPT/r /dev/stdin" /etc/sysconfig/iptables
# controlled by CASTOR-client RPM
# controlled by castor-lib RPM
# allow callbacks for RFIO, port range corresponds to default callback range
-A $chain -m state --state NEW -m tcp -p tcp --dport 30000:30100 -j ACCEPT
# end of CASTOR-client RPM modifications
......
if [ "$1" = 0 ]; then
# IP tables modification to allow the castor client to open ports
if [ -e /etc/sysconfig/iptables ]; then
/bin/sed -i.castor -e '/controlled by CASTOR-client RPM/,/end of CASTOR-client RPM modifications/d' /etc/sysconfig/iptables
/bin/sed -i.castor -e '/controlled by castor-lib RPM/,/end of CASTOR-client RPM modifications/d' /etc/sysconfig/iptables
/sbin/service iptables condrestart > /dev/null 2>&1 || :
fi
# call to ldconfig after we uninstalled libraries
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment