|
楼主 |
发表于 2003-4-22 16:29:01
|
显示全部楼层
更正
现在发现,其实在iptables -F以后,也就是在
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain RH-Lokkit-0-50-INPUT (0 references)
target prot opt source destination
的情况下,oracle使用是完全正常的
我现在改了以下script,如下
#!/bin/sh
echo "Starting iptables rules..."
/sbin/iptables -F INPUT
/sbin/iptables -F OUTPUT
/sbin/iptables -P INPUT DROP
/sbin/iptables -P OUTPUT ACCEPT
/sbin/iptables -A INPUT -i lo -j ACCEPT
/sbin/iptables -A INPUT -p tcp -s 10.137.18.194/26 --dport ssh -j ACCEPT
/sbin/iptables -A INPUT -p tcp -s 10.137.16.0/22 --dport 21 -j ACCEPT
/sbin/iptables -A INPUT -p tcp -s 10.137.16.0/22 --dport 20 -j ACCEPT
/sbin/iptables -A INPUT -p tcp -s 10.137.18.194/26 --dport 139 -j ACCEPT
/sbin/iptables -A INPUT -p tcp -s 10.137.18.194/26 --dport 1521 -j ACCEPT
/sbin/iptables -A INPUT -p tcp -s 10.137.18.194/26 --dport 6003 -j ACCEPT
/sbin/iptables -A INPUT -p tcp -s 10.137.18.194/26 --dport 32773 -j ACCEPT
运行以后,iptables -L显示:
Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT tcp -- 10.137.18.192/26 anywhere tcp dpt:ssh
ACCEPT tcp -- 10.137.16.0/22 anywhere tcp dpt:ftp
ACCEPT tcp -- 10.137.16.0/22 anywhere tcp dpt:ftp-data
ACCEPT tcp -- 10.137.18.192/26 anywhere tcp dpt:netbios-ssn
ACCEPT tcp -- 10.137.18.192/26 anywhere tcp dpt:1521
ACCEPT tcp -- 10.137.18.192/26 anywhere tcp dpt:6003
ACCEPT tcp -- 10.137.18.192/26 anywhere tcp dpt:32773
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain RH-Lokkit-0-50-INPUT (0 references)
target prot opt source destination
在这种情况下,开始oracle正常,几分钟后开始出现错误:"ORA-12545:连接因对象主机或对象不存在而失败" |
|