Reconfiguring a SCN When a Ship's LAN is Changed
A. Changes to shipside SCN
- Edit /etc/hosts to change relevant hostname/IP address pairs.
- Using given SCN IP and network IP, determine netmask and broadcast IPs.
Guidelines can be found at http://www.ibiblio.org/pub/Linux/docs/HOWTO/mini/IP-Subnetworking or perhaps http://netfilter.kernelnotes.org/unreliable-guides/networking-concepts-HOWTO-4.html#ss4.1
- Edit /etc/sysconfig/network-scripts/ifcfg-eth0:0
Replace definitions for IPADDR, NETWORK, NETMASK, BROADCAST
- Edit /etc/sysconfig/static-routes
Replace old IP address(es) with new.
- Reconfigure SCN router routing table.
a. Connect to router via 'telnet 172.16.xx.2' or 'minicom router_ttyS1'
b. Once connected/logged on
scn-rou> ena
passwd: xxxxxxx
scn-rou# show running-config
- Find 'ip route' statement that contains the old network IP. Record.
scn-rou# config terminal
- Remove old route. Place 'no' in front of 'ip route' found above.
scn-rou# no ip route xxx.xxx.xxx.xxx 255.255.255.xxx 172.16.xx.1
- Add new route. Replace old IP with new in 'ip route' statement.
scn-rou# ip route yyy.yyy.yyy.yyy 255.255.255.yyy 172.16.xx.1
scn-rou# exit * from 'config terminal'
scn-rou# save running-config startup-config
scn-rou# show startup-config * confirm changes
- exit
B. Changes to shoreside NICs
- Edit NIC /etc/rc.d/rc.local
It's necessary to know the network IP and the short form of the netmask, i.e.,
| Short Form |
Full Form |
Maximum #
of Machines |
| /24 |
/255.255.255.0 |
255 |
| /25 |
/255.255.255.128 |
127 |
| /26 |
/255.255.255.192 |
63 |
| /27 |
/255.255.255.224 |
31 |
| /28 |
/255.255.255.240 |
15 |
| /29 |
/255.255.255.248 |
7 |
| /30 |
/255.255.255.252 |
3 |
a. Remove masquerade entries for old IP (or comment with '#')
b. Add masquerade entries for new IP
- Place new rule into running kernel
Copy new entry from rc.local and run as root in shell window.
- Remove old ipchains entry from kernel
nic # ipchains --line --list fwd
results in a listing of rules denoted by a number in left column.
Note number of rule to remove. Confirm new rule(s) are in place.
nic # ipchains -D fwd number
nic # ipchains --line --list fwd
- Edit NIC router config
a. Connect to router via 'minicom router_ttyS1'
b. Once connected/logged on
scn-rou> ena
passwd: xxxxxxx
scn-rou# show running-config
- * Find 'ip route' statement that contains the old network IP. Record.
scn-rou# config terminal
- Remove old route. Place 'no' in front of 'ip route' found above.
scn-rou# no ip route xxx.xxx.xxx.xxx 255.255.255.xxx 172.16.xx.2
- Add new route. Replace old IP with new in 'ip route' starement.
scn-rou# ip route yyy.yyy.yyy.yyy 255.255.255.xxx 172.16.xx.2
scn-rou# exit * from 'config terminal'
scn-rou# save running-config startup-config
scn-rou# show startup-config * confirm changes
- exit
|