Showing posts with label Networking. Show all posts
Showing posts with label Networking. Show all posts

Sunday, June 9, 2013

Tutorial DHCP Server di Debian Lenny

Pengertian
Merupakan sebuah aplikasi server yang digunakan untuk memberikan pelayanan IP Address , Gateway dan DNS Server secara Otomatis kepada client.

Sebuah jaringan lokal yang tidak menggunakan DHCP harus memberikan alamat IP kepada semua komputer secara manual. Jika DHCP dipasang di jaringan lokal, maka semua komputer yang tersambung di jaringan akan mendapatkan alamat IP secara otomatis dari server DHCP. Selain alamat IP, banyak parameter jaringan yang dapat diberikan oleh DHCP, seperti default gateway dan DNS server.

Cara Kerja DHCP
Karena DHCP merupakan sebuah protokol yang menggunakan arsitektur client/server, maka dalam DHCP terdapat dua pihak yang terlibat, yakni DHCP Server dan DHCP Client.
DHCP server merupakan sebuah mesin yang menjalankan layanan yang dapat "menyewakan" alamat IP dan informasi TCP/IP lainnya kepada semua klien yang memintanya.
DHCP client merupakan mesin klien yang menjalankan perangkat lunak klien DHCP yang memungkinkan mereka untuk dapat berkomunikasi dengan DHCP Server.
DHCP server umumnya memiliki sekumpulan alamat yang diizinkan untuk didistribusikan kepada klien, yang disebut sebagai DHCP Pool. Setiap klien kemudian akan menyewa alamat IP dari DHCP Pool ini untuk waktu yang ditentukan oleh DHCP, biasanya hingga beberapa hari. Manakala waktu penyewaan alamat IP tersebut habis masanya, klien akan meminta kepada server untuk memberikan alamat IP yang baru atau memperpanjangnya.
DHCP Client akan mencoba untuk mendapatkan "penyewaan" alamat IP dari sebuah DHCP server dalam proses empat langkah berikut:

  1. DHCPDISCOVER: DHCP client akan menyebarkan request secara broadcast untuk mencari DHCP Server yang aktif.
  2. DHCPOFFER: Setelah DHCP Server mendengar broadcast dari DHCP Client, DHCP server kemudian menawarkan sebuah alamat kepada DHCP client.
  3. DHCPREQUEST: Client meminta DCHP server untuk menyewakan alamat IP dari salah satu alamat yang tersedia dalam DHCP Pool pada DHCP Server yang bersangkutan.
  4. DHCPACK: DHCP server akan merespons permintaan dari klien dengan mengirimkan paket acknowledgment. Kemudian, DHCP Server akan menetapkan sebuah alamat (dan konfigurasi TCP/IP lainnya) kepada klien, dan memperbarui basis data database miliknya. Klien selanjutnya akan memulai proses binding dengan tumpukan protokol TCP/IP dan karena telah memiliki alamat IP, klien pun dapat memulai komunikasi jaringan.

Empat tahap di atas hanya berlaku bagi klien yang belum memiliki alamat. Untuk klien yang sebelumnya pernah meminta alamat kepada DHCP server yang sama, hanya tahap 3 dan tahap 4 yang dilakukan, yakni tahap pembaruan alamat (address renewal), yang jelas lebih cepat prosesnya.

untuk Tutorial cara instalasinya dapat didownload di sini : download materi

Sumber : wikipedia

Thursday, June 6, 2013

FTP Server pada Debian Lenny 5.0 (Anonymous dan non-anonymous FTP)

Pengertian FTP 
File Transfer Protocol (FTP) adalah suatu protokol yang berfungsi untuk tukar-menukar file dalam suatu network yang menggunakan TCP Protokol.

FTP dibagi menjadi 2 Buah yaitu FTP Server dan FTP Client.
FTP user terdapat 2 jenis yaitu : anonymous dan non-anonymous.

FTP server adalah suatu server yang menjalankan software yang berfungsi untuk memberikan layanan tukar menukar file dimana server tersebut selalu siap memberikan layanan FTP apabila mendapat permintaan (request) dari FTP client.

FTP client adalah computer yang merequest koneksi ke FTP server untuk tujuan tukar menukar file. Setelah terhubung dengan FTP server, maka client dapat men-download, meng-upload, merename, men-delete, dll sesuai dengan permission yang diberikan oleh FTP server.

Langkah instalasi FTP
1. instal paket FTP , dalam hal ini saya menggunakan vsftpd
    #apt-get install vsftpd
2. ubah konfigurasi pada file "/etc/vsftpd.conf" dan hilangkan tanda # pada bagian local_enable=yes
3. kemudian hilangkan juga tanda # pada baris write_enable=yes agar user bisa upload file ke server
4. Restart FTP server anda dengan cara berikut :
    #/etc/init.d/vsftpd restart

untuk lebih lengkapnya tentang FTP silahkan download pada link berikut : Download Materi

Thursday, February 21, 2013

Webserver pada Debian Lenny (Debian 5.0)

pada tutorial saya akan mencoba untuk menjelaskan tentang pembuatan aplikasi web server pada linux debian 5 atau debian lenny.

ok tanpa banyak kata , langsung saja kita mulai.

Pengenalan webserver
apa sih web server itu ?
Webserver merupakan sebuah aplikasi yang memberikan layanan berupa data web atau yang berfungsi untuk menerima permintaan HTTP atau HTTPS dan mengirimkannya kembali dalam bentuk dokumen HTML atau halaman web.

Instalasi Webserver pada Debian
untuk instalasi webserver pada debian lenny dibutuhkan beberapa peralatan yang harus disiapkan yaitu :
1. Komputer
2. DVD OS Debian 5
2. DVDROM
3. Paket yang dibutuhkan adalah apache2

untuk cara instalasi dan konfigurasi, dapat dilakukan sebagia berikut :
1. instalasi paket apache2
    #apt-get install apache2
2. Konfigurasi webserver
    - buka file "/etc/apache2/site-available/default"
    - edit pada bagian DocumentRoot , dan ganti sesuai dengan dimana folder web berada
      contoh :
      DocumentRoot /var/www/web/
    - untuk nama subdomain dari webserver , dapat dilakukan dengan penambahan ServerName
      www.domain.com diatas DocumentRoot
      contoh :
      ServerName www.domain.com
      DocumentRoot /var/www/web/
    - Kemudian simpan perubahan konfigurasi tersebut.
    - Restart apache2 dengan cara :
       # /etc/init.d/apache2 restart
3. Buka browser dan akses IP webserver atau address dari webserver.

untuk materi lengkapnya dapat didownload disini download materi

Thursday, May 21, 2009

Configuring Virtual IP Address in Solaris

Follow the three simple steps that will help you to configure virtual IP address :

  1. Edit the /etc/hosts file and add additional IP addresses, along with the associated hostname. For example : To add 192.168.0.1 (web1) and 192.168.0.2 (web2) to the system, enter in the following manner.

192.168.0.1 web1
192.168.0.2 web2

The system needs to be configured for the newly added IP addresses.

  1. Create the startup files so that the system will automatically add the new IP addresses upon bootup.

    a. Create new files in the /etc directory. The file names should follow the following convention according to the new ip address added.

    hostname.hme0:1
    hostname.hme0:2

    b. The contents of these files will be a single line with the respective hostname entered. For example:

      File Name

      Contents

      hostname.hme0:1

      hostname.hme0:2

      web1

      web2

The file "hostname.hme0:1" will contain "web1" and "hostname.hme0:2" will contain "web2".

If you look in the "/etc" directory, you will find a file named "hostname.hme0" (which is the real interface, the :n represents the virtual interface). In this file, you will find the name of your system. If you look in the "/etc/hosts" file, you will find your IP address.

Now you have configured virtual IP address for two new interfaces that you have added ( .hme0:1 and .hme0:2 .

  1. To activate this virtual IP address, you have to provide the following commands :

# ifconfig hme0:1 plumb

# ifconfig hme0:2 plumb

The system startup in Solaris searches the "/etc" directory for files named "hostname.*". When it finds one or more of these files, it reads the hostname from them, looks up the hostname in the "/etc/hosts" file for a match, and if found, configures the interface with the IP address of the match.

Please re-boot your system for the virtual IP address to be configured in your system.

(OR)

To configure the interface without re-starting the system, use the "ifconfig" command. To add the two IP addresses, type:

# ifconfig hme0:1 192.168.0.1 up

# ifconfig hme0:2 192.168.0.2 up

After having issued these two commands, the system would recognize the new IP addresses immediately, without re-booting the system.

Configuring Virutal IP addresses

Configuring Virtual IP Address in Windows NT

The procedure to configure multiple virtual IP addresses in Windows NT is given below. This procedure can be performed only by an user with admin privilege.

  1. Click on the Start Menu on the Taskbar and choose Control Panel.

  2. Double-click Network among the components displayed in the Control Panel. This opens up a Network dialog with 5 tabs.

  3. Choose the Protocols tab and click on TCP / IP Protocol from listed protocols.

  4. Click on Properties button when TCP / IP Protocol is selected.

  5. This brings up the Microsoft TCP / IP properties dialog ; choose IP Address tab.

  6. Click the Advanced button ; this will bring the Advanced IP addressing with the Adapter Name shown above the configured IP addresses in your system.

  7. Click Add to display the TCP/ IP Address dialog. Specify IP Address and the corresponding Subnet Mask.

  8. Re-start the system for the changes to take effect.

Configuring Virtual IP Address in Windows XP/2000/ ME/2003

The procedure to configure virtual IP addresses in bulk under Windows XP/2000/ME is given below. This procedure can be performed only by an user with admin privilege.

  1. Click on the Start Menu and choose Settings.

  2. Among the listed items select Network and Dial-up connections.

  3. Select Local area connection from the items under Network and Dial-up connections ; this opens with the general information on Local area connection status.

  4. Click on the Properties button. The Local area connection properties dialog opens listing all the protocols.

  5. Choose Internet Protocol ( TCP / IP ) and click on the Properties button.

  6. The Internet Protocol TCP / IP Properties dialog is invoked. Click on the Advanced button at the bottom of the dialog. The Advanced TCP / IP settings dialog displays all the configured IP addresses in your system.

  7. Click Add button next to the displayed IP addresses to add an IP address with a corresponding sub-net mask.

  8. You will have to re-start the system for the changes to take effect.

Configuring Virtual IP Address in bulk under Windows 2000

The procedure to configure virtual IP addresses in bulk under Windows 2000 is given below. This procedure can be performed only by an user with admin privilege.

  1. Select Start ->Run and type regedt32 in the run dialog ( or you can type it on the DOS prompt) .

  2. This will bring up the Registry Editor - HKEY_LOCAL_MACHINE on Local Machine screen.

  3. Choose the HKEY_LOCAL_MACHINE on the tree displayed on the left hand side.

  4. Choose the path : HKEY_LOCAL_MACHINE -> System -> CurrentControlSet -> Services > NetBT -> Parameters -> Interfaces. Here, you will find a series of Tcpip_{labels} under Interfaces, an example is shown below: Tcpip_{2B34C0C3_FCA8_486C_8559_989429901786}

  5. Select all the Tcpip_{labels} listed to check if the right hand side data content which has Netbios Options:REG_DWORD :0x1 and make a note of this Tcpip_{ label } .

  6. Search for this label under HKEY_LOCAL_MACHINE ->System -> CurrentControlSet -> Services -> Tcpip -> Parameters -> Interfaces. Here, you will find the same Tcpip_{label } (that you had noted down in point 5). When you select this, the right side data content will display IP address and properties.

  7. Double click on the IP address field . This opens a Multi-String editor where the virtual IP addresses you want have to be keyed in. You can cut and paste to minimise the time for large number of IPs .

  8. When you have finished entering the IP addresses, select the subnetmask field ( 255.255.255.0) in the right hand side. This opens a Multi-String editor where the subnetmask you want have to be keyed in. Enter the same number of subnetmasks(255.255.255.0) as the number of IPs.

  9. You will have to re-start the system for the changes to take effect.

  10. Now you should be able to ping these virtual IP addresses. Also, make sure that there are no conflicts in the network ( i.e the virtual IP you have configured is not already being used by some other user).

Configuring Virtual IP Address in Windows in DHCP mode

The procedure to configure virtual IP addresses in windows with DHCP mode is the same as Configuring Virtual IP Address in bulk under Windows 2000.

Configuring Virtual IP Address in Linux

  1. Invoke the linuxconf tool. ( type linuxconf in the shell prompt and press Enter ). For starting this tool you have to be logged in as Super user.

  2. In the displayed menu, select the menu item : IP Aliases for virtual hosts and press Enter. This will display the two interfaces eth0 and lo. (Ethernet interfaces in Linux are called by such names as eth0 and eth1)

  3. Select eth0 and press Enter. This will show all the IP aliases configured for the selected interface.

  4. In the field IP alias or range, enter the desired IP address or the range with a corresponding Netmask.

    Example

    IP alias or range : 177.177.177.1-25
    Netmask : 255.255.255.0


    Note:

    1. These commands have to be executed with the super user privilege.

    2. You will have to re-start the system for the changes to take effect.

    3. When you are configuring a large number of IP address, it might take a long time to boot up.

Using the following command, we can configure Virtual IPs in the Linux box at run-time without re-booting the machine or re-starting the network.

ifconfig eth0:1 172.19.1.2 netmask 255.255.255.0 up

ifconfig eth0:3 172.19.1.3 netmask 255.255.255.0 up

The interface number must be unique for each interface (for example eth0:1, eth0:2 etc). The same interfaces can be made down by using the following command.

ifconfig eth0:1 172.19.1.2 netmask 255.255.255.0 down

ifconfig eth0:3 172.19.1.3 netmask 255.255.255.0 down

Popular Posts