Mengetahui Alamat IP Sebuah Kartu Jaringan / LAN Card

Untuk melihat seluruh alamat kartu jaringan atau LAN Card Atau Network Interface Card kita bisa menggunakan perintah /sbin/ifconfig. Jika digunakan tanpa menggunakan opsi apapun, maka informasi mengenai seluruh kartu jaringan akan ditampilkan termasuk lo / loopback interface.

[[email protected] ~]$ /sbin/ifconfig
eth0      Link encap:Ethernet  HWaddr 00:0C:29:04:CE:62
          inet addr:192.168.221.128  Bcast:192.168.221.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fe04:ce62/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:66 errors:0 dropped:0 overruns:0 frame:0
          TX packets:76 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:9425 (9.2 KiB)  TX bytes:13482 (13.1 KiB)
          Interrupt:67 Base address:0x2024

eth1      Link encap:Ethernet  HWaddr 00:0C:29:04:CE:6C
          inet addr:192.168.63.129  Bcast:192.168.63.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fe04:ce6c/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:7 errors:0 dropped:0 overruns:0 frame:0
          TX packets:39 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:1390 (1.3 KiB)  TX bytes:7985 (7.7 KiB)
          Interrupt:67 Base address:0x20a4

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)

Jika ingin menampilkan informasi hanya kartu jaringan tertentu, maka anda bisa menambahkan nama interface sebagai parameter ifconfig

[[email protected] ~]$ /sbin/ifconfig eth0
eth0      Link encap:Ethernet  HWaddr 00:0C:29:04:CE:62
          inet addr:192.168.221.128  Bcast:192.168.221.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fe04:ce62/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:127 errors:0 dropped:0 overruns:0 frame:0
          TX packets:140 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:14609 (14.2 KiB)  TX bytes:21610 (21.1 KiB)
          Interrupt:67 Base address:0x2024

Kalau anda hanya ingin melihat alamat IP sebuah interface tanpa informasi tambahan, anda bisa menggunakan perintah berikut :

[[email protected] ~]$ /sbin/ifconfig eth0 | grep 'inet addr:'
          inet addr:192.168.221.128  Bcast:192.168.221.255  Mask:255.255.255.0

6 thoughts on “Mengetahui Alamat IP Sebuah Kartu Jaringan / LAN Card

  1. Pingback: lnxbox

  2. Pingback: muhammad panji

  3. Pingback: Muhammad Panji

  4. Pingback: kurungsiku

  5. Pingback: lnxbox

  6. Pingback: Tweets that mention [1001+ Linux Tips] Mengetahui Alamat IP Sebuah Kartu Jaringan / LAN Card | LinuxBox.Web.ID -- Topsy.com

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.