"리눅스 본딩 확인"의 두 판 사이의 차이

잔글 (봇: 자동으로 텍스트 교체 (-==참고 자료== +==참고==))
 
(사용자 2명의 중간 판 13개는 보이지 않습니다)
3번째 줄: 3번째 줄:
;리눅스 bonding 정보 수집
;리눅스 bonding 정보 수집


==방법 1: ifcfg-eth 파일==
==방법 1: bondN 파일==
<source lang='dos'>
<source lang='console'>
[root@localhost ~]# grep -H MASTER= /etc/sysconfig/network-scripts/ifcfg-eth*
[root@zetawiki ~]# grep -H ^'Slave Interface'  /proc/net/bonding/bond*
/proc/net/bonding/bond0:Slave Interface: eth0
/proc/net/bonding/bond0:Slave Interface: eth1
/proc/net/bonding/bond1:Slave Interface: eth2
/proc/net/bonding/bond1:Slave Interface: eth3
</source>
:→ eth0 + eth1 = bond0
:→ eth2 + eth3 = bond1
 
==방법 2: ifcfg-ethN 파일==
<source lang='console'>
[root@zetawiki ~]# grep -H MASTER= /etc/sysconfig/network-scripts/ifcfg-eth*
/etc/sysconfig/network-scripts/ifcfg-eth0:MASTER=bond0
/etc/sysconfig/network-scripts/ifcfg-eth0:MASTER=bond0
/etc/sysconfig/network-scripts/ifcfg-eth1:MASTER=bond0
/etc/sysconfig/network-scripts/ifcfg-eth1:MASTER=bond0
11번째 줄: 22번째 줄:
/etc/sysconfig/network-scripts/ifcfg-eth3:MASTER=bond1
/etc/sysconfig/network-scripts/ifcfg-eth3:MASTER=bond1
</source>
</source>
:→ eth0 + eth1 bond0
:→ eth0 + eth1 = bond0
:→ eth2 + eth3 bond1
:→ eth2 + eth3 = bond1


==전체 확인==
==방법 3: ip link==
===명령어===
<source lang='console'>
<source lang='bash'>
[root@zetawiki ~]# ip link | grep bond0
DEVNAMES=(`ifconfig -a | grep eth | awk '{print $1}' | xargs echo`)
4: eth2: <BROADCAST,MULTICAST,SLAVE,UP> mtu 1500 qdisc pfifo_fast master bond0 qlen 100
for DEVNAME in "${DEVNAMES[@]}"
5: eth3: <BROADCAST,MULTICAST,NOARP,SLAVE,DEBUG,AUTOMEDIA,PORTSEL,NOTRAILERS,UP> mtu 1500 qdisc pfifo_fast master bond0 qlen 100
do
58: bond0: <BROADCAST,MULTICAST,MASTER,UP> mtu 1500 qdisc noqueue
        MASTER=`grep MASTER= /etc/sysconfig/network-scripts/ifcfg-$DEVNAME`
        echo "$DEVNAME --- $MASTER"
done
</source>
</source>
 
:→ eth2 + eth3 = bond0
===실행예시===
<source lang='dos'>
[root@jmnote ~]# for DEVNAME in "${DEVNAMES[@]}"; do MASTER=`grep MASTER= /etc/sysconfig/network-scripts/ifcfg-$DEVNAME`; echo "$DEVNAME --- $MASTER"; done
eth0 --- MASTER=bond1
eth1 --- MASTER=bond1
eth2 ---
eth3 ---
eth4 --- MASTER=bond0
eth5 ---
eth6 --- MASTER=bond0
eth7 ---
</source>
:→ eth0과 eth1이 bond1로 묶여 있음
:→ eth4과 eth6이 bond0으로 묶여 있음


==같이 보기==
==같이 보기==
44번째 줄: 38번째 줄:
*[[리눅스 이더넷 펌웨어 버전 수집]]
*[[리눅스 이더넷 펌웨어 버전 수집]]
*[[/etc/sysconfig/network-scripts/ifcfg-eth0]]
*[[/etc/sysconfig/network-scripts/ifcfg-eth0]]
*[[/proc/net/bonding/bond0]]
*[[리눅스 ip link]]
==참고==
*http://linux-ip.net/html/ether-bonding.html
[[분류: 리눅스 네트워크]]
[[분류: 리눅스 네트워크]]

2017년 7월 11일 (화) 04:17 기준 최신판

리눅스 이더넷 bond 확인
리눅스 bonding 확인
리눅스 bonding 정보 수집

1 방법 1: bondN 파일[ | ]

[root@zetawiki ~]# grep -H ^'Slave Interface'  /proc/net/bonding/bond*
/proc/net/bonding/bond0:Slave Interface: eth0
/proc/net/bonding/bond0:Slave Interface: eth1
/proc/net/bonding/bond1:Slave Interface: eth2
/proc/net/bonding/bond1:Slave Interface: eth3
→ eth0 + eth1 = bond0
→ eth2 + eth3 = bond1

2 방법 2: ifcfg-ethN 파일[ | ]

[root@zetawiki ~]# grep -H MASTER= /etc/sysconfig/network-scripts/ifcfg-eth*
/etc/sysconfig/network-scripts/ifcfg-eth0:MASTER=bond0
/etc/sysconfig/network-scripts/ifcfg-eth1:MASTER=bond0
/etc/sysconfig/network-scripts/ifcfg-eth2:MASTER=bond1
/etc/sysconfig/network-scripts/ifcfg-eth3:MASTER=bond1
→ eth0 + eth1 = bond0
→ eth2 + eth3 = bond1

3 방법 3: ip link[ | ]

[root@zetawiki ~]# ip link | grep bond0
4: eth2: <BROADCAST,MULTICAST,SLAVE,UP> mtu 1500 qdisc pfifo_fast master bond0 qlen 100
5: eth3: <BROADCAST,MULTICAST,NOARP,SLAVE,DEBUG,AUTOMEDIA,PORTSEL,NOTRAILERS,UP> mtu 1500 qdisc pfifo_fast master bond0 qlen 100
58: bond0: <BROADCAST,MULTICAST,MASTER,UP> mtu 1500 qdisc noqueue
→ eth2 + eth3 = bond0

4 같이 보기[ | ]

5 참고[ | ]

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