Linux Networking on terminal and Back with CentOS 7

recently i installed centos 7 and happy to say back to play with linux. so as first step after installation was the configure network. first need to check what are the available interfaces in current system. to check that we can use ifconfing -a command

[root@tecmint ~]# ifconfig -a

eth0      Link encap:Ethernet  HWaddr 00:0B:CD:1C:18:5A
          inet addr:  Bcast:  Mask:
          inet6 addr: fe80::20b:cdff:fe1c:185a/64 Scope:Link
          RX packets:2344927 errors:0 dropped:0 overruns:0 frame:0
          TX packets:2220777 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:293839516 (280.2 MiB)  TX bytes:1043722206 (995.3 MiB)
          Interrupt:185 Memory:f7fe0000-f7ff0000

lo        Link encap:Local Loopback
          inet addr:  Mask:
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:5022927 errors:0 dropped:0 overruns:0 frame:0
          TX packets:5022927 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:2175739488 (2.0 GiB)  TX bytes:2175739488 (2.0 GiB)

then select the interface you need to active and give following command. mostly with ethernet it will be eth0

ifconfig eth0 up 
ifup eth0

[root@tecmint ~]# ifconfig eth0 up
[root@tecmint ~]# ifup eth0

it will try to make connection with dhcp server and request ip and assign that ip to interface
or else we can assign ip to that interface
[root@tecmint ~]# ifconfig eth0


0 අදහස්:

Post a Comment

මෙම ලිපිය කියවනකොට හිතුණු දේවල් වලින් ටිකක් මෙතන ලියලම යන්නකෝ

Related Posts Plugin for WordPress, Blogger...