problem s NATem

Scoobie Ray scoobie at mail.ru
Wed Aug 4 08:35:46 CEST 2004


Dobry den!
Mam pocitac, ketry je napojen na internet - bezi na nem FreeBSD 5.2.1 a potrebuji jeste na nej napojit pocitas s Linuxem pres NAT. Nakonfiguroval jsem jadro dle handbooku nasledovne:
#Network Address Translation (NAT)
options         IPFIREWALL
options         IPDIVERT
options         IPFIREWALL_DEFAULT_TO_ACCEPT
options         IPFIREWALL_VERBOSE

Do /etc/rc.conf jsem pridal tyto radky:
gateway_enable="YES"            # Set to YES if this host will be a gateway.
mrouted_enable="NO"             # Do multicast routing (see /etc/mrouted.conf).
firewall_enable="YES"           # Enables the firewall rules in /etc/rc.firewall at boot.
firewall_type="OPEN"            # This specifies a predefined firewall ruleset that allows anything in. See /etc/rc.firewall for additional types.
natd_enable="YES"                                                                                                                
natd_interface="fxp0"           # Indicates which interface to forward packets through (the interface connected to the Internet).
natd_flags="-redirect_address 192.168.254.1 147.32.122.196"
arpproxy_all=""                 # replaces obsolete kernel option ARP_PROXYALL.

Linuxovy stroj ma IP 192.168.254.2
Po restertu pocitace dle dmesg ipfirawall nabehne, ale natd v pameti neni. Zarizeni fxp0 taky nikde neni.

Jestlize spustim natd takto:
natd -a 192.168.254.1 -t 147.32.122.196 -redirect_address 192.168.254.1 147.32.122.196
Natd nabehne, ale stejne chybi natd_interface.
Kdyz jsem dal tuto radku do /etc/rc.conf do natd_flags natd opet nenabehl.

Muzete mi s tim, prosim, pomoci?
Dekuji za napady.





More information about the Users-l mailing list