HP 1032 Manual page 44

Clusterpack v2.4 tutorial
Table of Contents

Advertisement

% man 8 ipf
List the input output filter rules
% ipfstat -hio
Setup the NAT rules
In this section, we will walk through the steps of setting up HP-UX IPFilter that translate the source IP
addresses of all packets from the compute private subnet to the IP address of the gateway node. For addin
more sophisticated NAT rules, please refer to the IPFilter documentation.
1. Create a file with NAT rules.
Example 1: Map packets from all Compute Nodes in the 192.168.0.x subnet to a single IP
address 15.99.84.23
% cat << EOF > /tmp/nat.rules
# lan0 -- interface to the external network
# NAT IP interface: 15.99.84.23
map lan0 192.168.0.0/24 -> 15.99.84.23/32 portmap tcp/udp
40000:60000
map lan0 192.168.0.0/24 -> 15.99.84.23/32
EOF
% cat /tmp/nat.rules
# lan0 -- interface to the external network
# NAT IP interface: 15.99.84.23
map lan0 192.168.0.0/24 -> 15.99.84.23/32 portmap tcp/udp
40000:60000
map lan0 192.168.0.0/24 -> 15.99.84.23/32
Example 2: Map packets from specific Compute Nodes (192.168.0.3 and 192.168.0.4) to
a single IP address 15.99.84.23
% cat << EOF > /tmp/nat.rules
# lan0 -- interface to the external network
# NAT IP interface: 15.99.84.23
map lan0 192.168.0.3/32 -> 15.99.84.23/32 portmap tcp/udp
40000:60000
map lan0 192.168.0.3/32 -> 15.99.84.23/32
map lan0 192.168.0.4/32 -> 15.99.84.23/32 portmap tcp/udp
40000:60000
map lan0 192.168.0.4/32 -> 15.99.84.23/32
EOF
% cat /tmp/nat.rules
# lan0 -- interface to the external network
# NAT IP interface: 15.99.84.23
map lan0 192.168.0.3/32 -> 15.99.84.23/32 portmap tcp/udp
40000:60000
map lan0 192.168.0.3/32 -> 15.99.84.23/32

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents