Configure Additional IP Addresses Rumi, January 18, 2009 Let’s assume our network interface is eth0. Then there is a file /etc/sysconfig/network-scripts/ifcfg-eth0 which contains the settings for eth0. We can use this as a sample for our new virtual network interface eth0:0: cp /etc/sysconfig/network-scripts/ifcfg-eth0 /etc/sysconfig/network-scripts/ifcfg-eth0:0 Now we want to use the IP address 192.168.0.101 on the virtual interface eth0:0. Therefore we open the file /etc/sysconfig/network-scripts/ifcfg-eth0:0 and modify it as follows (we can leave out the HWADDR line as it is the same physical network card): vi /etc/sysconfig/network-scripts/ifcfg-eth0:0 Look sort of- # Advanced Micro Devices [AMD] 79c970 [PCnet32 LANCE] DEVICE=eth0:0 BOOTPROTO=static BROADCAST=192.168.0.255 IPADDR=192.168.0.101 NETMASK=255.255.255.0 NETWORK=192.168.0.0 ONBOOT=yes Afterwards we have to restart the network: /etc/init.d/network restart You might also want to adjust /etc/hosts after you have added new IP addresses, although this is not necessary. Now run: ifconfig You should now see your new IP address in the output: [root@server1 ~]# ifconfig eth0 Link encap:Ethernet HWaddr 00:0C:29:55:33:B3 inet addr:192.168.0.100 Bcast:192.168.0.255 Mask:255.255.255.0 inet6 addr: fe80::20c:29ff:fe55:33b3/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:355 errors:0 dropped:0 overruns:0 frame:0 TX packets:300 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:31326 (30.5 KiB) TX bytes:47669 (46.5 KiB) Interrupt:177 Base address:0x1400 eth0:0 Link encap:Ethernet HWaddr 00:0C:29:55:33:B3 inet addr:192.168.0.101 Bcast:192.168.0.255 Mask:255.255.255.0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 Interrupt:177 Base address:0x1400 lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:8 errors:0 dropped:0 overruns:0 frame:0 TX packets:8 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:560 (560.0 b) TX bytes:560 (560.0 b) [root@server1 ~]# Related Administrations Configurations (Linux)
Deploying a J2EE application behind an Apache server in a production environment April 20, 2012 You have created a Web application using a JBoss application server and you are going to put it in production. Great! But deploying your application with JBoss serving the Web requests directly may not be the optimal solution. First because the Tomcat web server embedded within JBoss is not the… Read More
Perfect FTP Server for Debian or Ubuntu May 9, 2018 This installation was performed on a Ubuntu 14.04 distribution system. While there are a variety of FTP server tools available for Linux, one of the most popular and mature options is vsftpd. Begin by SSHing into your server as root and use the apt-get command to install vsftpd: apt-get update… Read More
osTicket Automated Install Script December 13, 2021 osTicket is one of the leading open source ticketing systems. Here’s an easy way to spin up an instance on Ubuntu. Note: This script is purely intended for use in short-lived demo systems. The passwords are obvious (password !?) and there is no hardening applied to any of this system…. Read More