0% found this document useful (0 votes)
97 views4 pages

Ubuntu

This document discusses how to configure static and dynamic IP addresses, set up a DHCP server, and add IP aliases on Ubuntu Linux. It provides instructions for setting an IP address as static or dynamic by editing the /etc/network/interfaces file. It also explains how to restart the networking interface for changes to take effect. Steps are given to set up an ISC DHCP server, including editing the dhcpd.conf file and starting/stopping the dhcpd service. The document describes IP aliasing as adding multiple IP addresses to a single network interface. It provides an example of configuring two IP aliases on the eth0 interface by adding entries to /etc/network/interfaces defining the address, netmask

Uploaded by

ciubaca1
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
97 views4 pages

Ubuntu

This document discusses how to configure static and dynamic IP addresses, set up a DHCP server, and add IP aliases on Ubuntu Linux. It provides instructions for setting an IP address as static or dynamic by editing the /etc/network/interfaces file. It also explains how to restart the networking interface for changes to take effect. Steps are given to set up an ISC DHCP server, including editing the dhcpd.conf file and starting/stopping the dhcpd service. The document describes IP aliasing as adding multiple IP addresses to a single network interface. It provides an example of configuring two IP aliases on the eth0 interface by adding entries to /etc/network/interfaces defining the address, netmask

Uploaded by

ciubaca1
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

1.

Setarea ip-ului ca static / dynamic


ifconfig
- afiseaza datele de retea atat pentru loop cat si pentru eth
( ifconfig eth0 )
sudo nano /etc/network/interfaces
Ca ip-ul sa fie - static : iface eth0 inet static
- dinamic: iface eth0 inet dhcp
Ca setarile sa aibe efect trebuie restartata interfata de retea :
sudo /etc/init.d/networking restart (nu merge pe UBUNTU 14.)
sudo ifdown eth0 apoi sudo ifup eth0
Se verifica daca setarile s-au incarcat cu comanda ifconfig
Pentru a sterge fereastra se foloseste comanda clear

2. Setarea unui server DHCP


cd /etc

ls

cd dhcp

ls ( -l )

sudo nano dhcpd.conf

sau direct
sudo nano /etc/dhcp/dhcpd.conf

- deschide fisierul cu configuratia

Pentru a iesi crtl + x si se salveaza modificarile


sudo /etc/init.d/isc-dhcp-server start ( stop , restart ) - pentru a porni/ opri/ restarta serverul
sudo tail /var/lib/dhcp/dhcpd.leases
Pentru a sterge fereastra se foloseste comanda clear

3. IP aliasing
IP aliasing is the process of adding more than one IP address to a network interface. Typical uses of IP
aliasing are virtual hosting of Web and FTP servers. It is fairly simple to set up an IP alias. You merely
have to configure the network interface on the system to listen for the additional IP address.
Below are the steps for configuring IP alias under Ubuntu Linux:
If you want to put IP alias on an interface, first find the interface, use command
ifconfig
Open the file - /etc/network/interfaces and add the following entries (here we are adding 2 IP aliases)
auto eth0:1
iface eth0:1 inet static
address 192.168.1.10
netmask 255.255.255.0
broadcast 192.168.1.255
network 192.168.1.0
gateway 192.168.1.1
auto eth0:2
iface eth0:2 inet static
address 192.168.1.11
netmask 255.255.255.0
broadcast 192.168.1.255
network 192.168.1.0
gateway 192.168.1.1
You need to enter all the details like address,netmask,network,broadcast and gateways values after
entering all the values save this file and exit.
Read more: http://linuxpoison.blogspot.ro/2011/09/configuring-ip-aliases-underubuntu.html#ixzz3NnBdbn3l

You might also like