Red Hat SATELLITE 5.1.0 RELEASE NOTES Manual de instalación Pagina 180

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 268
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 179
162 The Virtualization Cookbook for Red Hat Enterprise Linux 5.2
Verify that the firewall is off using the chkconfig --list command. The service name is
iptables:
# chkconfig --list iptables
iptables 0:off 1:off 2:off 3:off 4:off 5:off 6:off
Turn on the firewall at boot time with the chkconfig command, and for this session with the
service command:
# chkconfig iptables on
# service iptables start
Applying iptables firewall rules: [ OK ]
Loading additional iptables modules: ip_conntrack_netbios_ns [ OK ]
Go back to your browser and click refresh. You should get an error that the server is not
responding. This is because packets for ports for http: and https: (80 and 443) are dropped by
default.
To allow Web traffic through, you can modify the file /etc/sysconfig/iptables. First make a
backup copy, add two rules (shown in bold font) to allow these ports, and then save your
changes:
# cd /etc/sysconfig
# cp iptables iptables.orig
# vi iptables
*filter
:INPUT ACCEPT [0:0]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
:RH-Firewall-1-INPUT - [0:0]
-A INPUT -j RH-Firewall-1-INPUT
-A FORWARD -j RH-Firewall-1-INPUT
-A RH-Firewall-1-INPUT -i lo -j ACCEPT
-A RH-Firewall-1-INPUT -p icmp --icmp-type any -j ACCEPT
-A RH-Firewall-1-INPUT -p 50 -j ACCEPT
-A RH-Firewall-1-INPUT -p 51 -j ACCEPT
-A RH-Firewall-1-INPUT -p udp --dport 5353 -d 224.0.0.251 -j ACCEPT
-A RH-Firewall-1-INPUT -p udp -m udp --dport 631 -j ACCEPT
-A RH-Firewall-1-INPUT -p tcp -m tcp --dport 631 -j ACCEPT
-A RH-Firewall-1-INPUT -p tcp -m tcp --dport 80 -j ACCEPT
-A RH-Firewall-1-INPUT -p tcp -m tcp --dport 443 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j ACCEPT
-A RH-Firewall-1-INPUT -j REJECT --reject-with icmp-host-prohibited
COMMIT
Restart the firewall to pick up the new rules:
# service iptables restart
Flushing firewall rules: [ OK ]
Setting chains to policy ACCEPT: filter [ OK ]
Unloading iptables modules: [ OK ]
Applying iptables firewall rules: [ OK ]
Loading additional iptables modules: ip_conntrack_netbios_ns [ OK ]
Go back to your browser and click refresh again. You should not get an error this time. You
should now have a firewall that allows Web traffic.
Vista de pagina 179
1 2 ... 175 176 177 178 179 180 181 182 183 184 185 ... 267 268

Comentarios a estos manuales

Sin comentarios