"CentOS 7 ifconfig 명령어 없음"의 두 판 사이의 차이

잔글 (봇: 자동으로 텍스트 교체 (-== 참고 자료 == +==참고==))
 
(사용자 2명의 중간 판 4개는 보이지 않습니다)
4번째 줄: 4번째 줄:
==문제상황==
==문제상황==
*CentOS 7을 최소설치했더니 ifconfig가 없다.<ref>[[CentOS 6 최소 설치]]에는 있었는데;;;</ref>
*CentOS 7을 최소설치했더니 ifconfig가 없다.<ref>[[CentOS 6 최소 설치]]에는 있었는데;;;</ref>
<source lang='cli'>
<source lang='console'>
[root@jmnote ~]# ifconfig
[root@zetawiki ~]# ifconfig
-bash: ifconfig: command not found
-bash: ifconfig: command not found
</source>
</source>
<source lang='cli'>
<source lang='console'>
[root@jmnote ~]# /sbin/ifconfig
[root@zetawiki ~]# /sbin/ifconfig
-bash: /sbin/ifconfig: No such file or directory
-bash: /sbin/ifconfig: No such file or directory
</source>
</source>
15번째 줄: 15번째 줄:
==해결방법 1: ip 명령어 사용==
==해결방법 1: ip 명령어 사용==
*ifconfig 명령어 대신 ip 명령어를 사용하자.
*ifconfig 명령어 대신 ip 명령어를 사용하자.
<source lang='cli'>
<source lang='console'>
[root@jmnote ~]# ip addr
[root@zetawiki ~]# ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN  
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN  
     link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
     link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
33번째 줄: 33번째 줄:
==해결방법 2: net-tools 설치==
==해결방법 2: net-tools 설치==
*ifconfig 명령어를 가지고 있는 net-tools 패키지를 설치하자.
*ifconfig 명령어를 가지고 있는 net-tools 패키지를 설치하자.
<source lang='cli'>
<source lang='console'>
[root@jmnote ~]# yum install net-tools
[root@zetawiki ~]# yum install net-tools
... (생략)
... (생략)
===========================================================================================
===========================================================================================
50번째 줄: 50번째 줄:
Is this ok [y/d/N]: y
Is this ok [y/d/N]: y
</source>
</source>
<source lang='cli'>
<source lang='console'>
... (생략)
... (생략)
Installed:
Installed:
57번째 줄: 57번째 줄:
Complete!
Complete!
</source>
</source>
<source lang='cli'>
<source lang='console'>
[root@jmnote ~]# ifconfig
[root@zetawiki ~]# ifconfig
ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
         inet 192.168.245.130  netmask 255.255.255.0  broadcast 192.168.245.255
         inet 192.168.245.130  netmask 255.255.255.0  broadcast 192.168.245.255
79번째 줄: 79번째 줄:


==같이 보기==
==같이 보기==
*[[CentOS 7 최소 설치 패키지 목록]]
*[[리눅스 ifconfig]]
*[[리눅스 ifconfig]]
*[[리눅스 ip]]


==주석==
==주석==
<references/>
<references/>


==참고 자료==
==참고==
*http://sharadchhetri.com/2014/07/25/ifconfig-command-found-centos-7/
*http://sharadchhetri.com/2014/07/25/ifconfig-command-found-centos-7/


[[분류: CentOS 7]]
[[분류: CentOS 7]]

2017년 6월 27일 (화) 01:51 기준 최신판

CentOS 7 ifconfig 명령어 없음
ifconfig: command not found

1 문제상황[ | ]

  • CentOS 7을 최소설치했더니 ifconfig가 없다.[1]
[root@zetawiki ~]# ifconfig
-bash: ifconfig: command not found
[root@zetawiki ~]# /sbin/ifconfig
-bash: /sbin/ifconfig: No such file or directory

2 해결방법 1: ip 명령어 사용[ | ]

  • ifconfig 명령어 대신 ip 명령어를 사용하자.
[root@zetawiki ~]# ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN 
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: ens33: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 00:0c:29:cb:a9:a7 brd ff:ff:ff:ff:ff:ff
    inet 192.168.245.130/24 brd 192.168.245.255 scope global dynamic ens33
       valid_lft 1786sec preferred_lft 1786sec
    inet6 fe80::20c:29ff:fecb:a9a7/64 scope link 
       valid_lft forever preferred_lft forever

3 해결방법 2: net-tools 설치[ | ]

  • ifconfig 명령어를 가지고 있는 net-tools 패키지를 설치하자.
[root@zetawiki ~]# yum install net-tools
... (생략)
===========================================================================================
 Package            Arch            Version                            Repository     Size
===========================================================================================
Installing:
 net-tools          x86_64          2.0-0.17.20131004git.el7           base          304 k

Transaction Summary
===========================================================================================
Install  1 Package

Total download size: 304 k
Installed size: 917 k
Is this ok [y/d/N]: y
... (생략)
Installed:
  net-tools.x86_64 0:2.0-0.17.20131004git.el7                                              

Complete!
[root@zetawiki ~]# ifconfig
ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.245.130  netmask 255.255.255.0  broadcast 192.168.245.255
        inet6 fe80::20c:29ff:fecb:a9a7  prefixlen 64  scopeid 0x20<link>
        ether 00:0c:29:cb:a9:a7  txqueuelen 1000  (Ethernet)
        RX packets 12519  bytes 18371158 (17.5 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 5956  bytes 375847 (367.0 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 0  (Local Loopback)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

4 같이 보기[ | ]

5 주석[ | ]

  1. CentOS 6 최소 설치에는 있었는데;;;

6 참고[ | ]

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}