![Black Box LS1016A User Manual Download Page 127](http://html.mh-extra.com/html/black-box/ls1016a/ls1016a_user-manual_2763435127.webp)
Chapter 3 - Additional Features
User Guide
127
iptables -t nat -F post_nat_cluster
iptables -t nat -F pre_nat_cluster
iptables -t nat -X pre_nat_cluster
iptables -t nat -X post_nat_cluster
iptables -t nat -N pre_nat_cluster
iptables -t nat -N post_nat_cluster
iptables -A PREROUTING -t nat -p tcp -j pre_nat_cluster
iptables -A POSTROUTING -t nat -p tcp -j post_nat_cluster
iptables -A pre_nat_cluster -t nat -p tcp -d <master_ip> --dport
<master_port> -j DNAT --to <slave_ip>:<slave_port>
.....
iptables -A post_nat_cluster -t nat -p tcp -d <slave_ip> --dport
<slave_port> -j SNAT --to <master_ip>
.....
At any time the BLACK BOX
®
Advanced Console Server administrator can issue an iptables
command to view, change (at his own risk), or delete the rules in the nat table. If the adminis-
trator issues a “fwset restore” command he must also execute the command “signal_ras hup”
to recover the nat table.
BLACK BOX
®
Advanced Console Server clustering was primarily designed to allow a large
number of serial ports (in more than one box) to be accessed using just one single public IP
address. It only works for ports configured with the CAS profile. With iptables you can extend
the access to the clustering.
Examples:
1.
Accessing a Slave box with the WebUI from anywhere:
iptables -A PREROUTING -t nat -p tcp -d 192.168.47.79 --dport 8081
-j DNAT --to 192.168.51.2:80
2.
Accessing a public DNS from any Slave box:
iptables -A PREROUTING -t nat -p udp -d 64.186.161.2 --dport 53 -j
SNAT --to 64.186.161.79:53