10.11 Changing the IP
Address Using SMIT
Suppose you have only one network card in your system. A user wants to host two different initial homepages on the Web server. After verifying that your Web server does support multiple IP addresses, you can bind multiple IP addresses to a single network adapter by defining an alias. For example, if the second IP address is 192.168.1.3, you can use the command:
ifconfig tr0 184.108.40.206 netmask 255.255.255.0 alias
After this, you can update your Web server configuration such that users using different URLs will see different initial homepages on the Web server.
There will be no ODM record created. You will need to invoke the same command again when you reboot your system. If your installation has a local startup script defined in the /etc/inittab file, this command should be included in that local startup script.
When this alias is no longer required, you can remove it using the command:
ifconfig tr0 220.127.116.11 netmask 255.255.255.0 delete
Use the traceroute
command to check whether the alias has been added or
deleted successfully as shown in Figure 97.
Figure 97: Checking whether Alias Has Been Added and Deleted Successfully
10.13 The .netrc