Вообщем такое дело:
ipfw_natd.sh:
#!/bin/sh
natd -f /etc/natd.conf
ipfw add 500 divert natd all from any to any via fxp0
ipfw add 501 pass all from any to any
# Ниже приведен пример, показывающий как можно выделить себе и начальнику по отдельному
# каналу в 128К, а всем остальным дать только 128К. Предположим, что мой ip-адрес
# 10.0.0.5, а ip-адрес начальника 10.0.0.2 и fxp0 - это сетевая карточка, подключенная
# к интернету.
ipfw add 509 pipe 3 ip from 10.0.0.5 to any out via fxp0
ipfw add 510 pipe 4 ip from any to 10.0.0.5 in via fxp0
ipfw pipe 3 config bw 128Kbit/s queue 20Kbytes
ipfw pipe 4 config bw 128Kbit/s queue 20Kbytes
ipfw add pipe 1 ip from any to any out via fxp0
ipfw add pipe 2 ip from any to any in via fxp0
ipfw pipe 1 config bw 128Kbit/s queue 20Kbytes
ipfw pipe 2 config bw 128Kbit/s queue 20Kbytes
И никчёрту не работает, firewall_type = "open"
Ограничения недействуют ! Это у меня в автозагрузке стоит ! В сервере 2 сетевые, rl1 - Internet, rl0 - Local net
natd.conf:
alias_address 194.67.18.8
target_address 10.0.0.1
log yes
log_denied yes
use_sockets yes
same_ports yes
unregistered_only yes