bonding nie powraca do interfejsu eth0

Masz problemy z siecią bądź internetem? Zapytaj tu
rysic
Beginner
Posty: 113
Rejestracja: 28 lipca 2009, 16:13

bonding nie powraca do interfejsu eth0

Post autor: rysic »

Utworzyłem sobie interfejs bond0 w ten sposób

Kod: Zaznacz cały

auto bond0
iface bond0 inet static
        address 192.168.1.10
        netmask 255.255.255.0
        gateway 192.168.1.1
        up /sbin/ifenslave bond0 eth0 eth1
        down /sbin/ifenslave -d bond0 eth0 eth1
        primary eth0
Oraz ustawiłem:

Kod: Zaznacz cały

$cat /etc/modprobe.d/aliases-bond.conf
alias bond0 bonding
        options bonding mode=1 arp_interval=2000 arp_ip_target=192.168.1.10
Ponoć z opcją ,,primary'' eth0 powinno wszystko powracać do interfejsu eth0, ale gdy wykonam zamknięcie portu, to przełącza się na eth1, ale po otwarciu już nie powraca do eth0.

Kod: Zaznacz cały

$cat /proc/net/bonding/bond0
Ethernet Channel Bonding Driver: v3.5.0 (November 4, 2008)Bonding Mode: fault-tolerance (active-backup)
Primary Slave: None
Currently Active Slave: eth1
MII Status: up
MII Polling Interval (ms): 100
Up Delay (ms): 200
Down Delay (ms): 200
Slave Interface: eth0
MII Status: up
Link Failure Count: 1
Permanent HW addr: 00:1a:4b:ea:6a:64
Slave Interface: eth1
MII Status: up
Link Failure Count: 0
Permanent HW addr: 00:1a:4b:ea:6a:62
mariaczi
Member
Posty: 1343
Rejestracja: 08 lutego 2008, 12:58
Lokalizacja: localhost@śląskie

Post autor: mariaczi »

Nie wygodniej zrobić to czytelniej?

Kod: Zaznacz cały

auto bond0
iface bond0 inet static
    address 192.168.1.10
    netmask 255.255.255.0
    gateway 192.168.1.1
    slaves eth0 eth1
    bond_mode active-backup
    bond_miimon 100
    bond_downdelay 200
    bond_updelay 200
Resztę robi już skrypt uruchamiający interfejsy sieciowe (sieć).
rysic
Beginner
Posty: 113
Rejestracja: 28 lipca 2009, 16:13

Post autor: rysic »

Wtedy nie trzeba już konfigurować aliases-bond.conf?
mariaczi
Member
Posty: 1343
Rejestracja: 08 lutego 2008, 12:58
Lokalizacja: localhost@śląskie

Post autor: mariaczi »

Sądzę, że tak. :)
rysic
Beginner
Posty: 113
Rejestracja: 28 lipca 2009, 16:13

Post autor: rysic »

Niestety, zmiana nic nie daje...
Awatar użytkownika
Unit
Beginner
Posty: 356
Rejestracja: 27 marca 2007, 09:39

Post autor: Unit »

http://wiki.debian.org/Bonding
Oczywiście pakiet ifenslave-2.6 jest zainstalowany?
rysic
Beginner
Posty: 113
Rejestracja: 28 lipca 2009, 16:13

Post autor: rysic »

Unit pisze:http://wiki.debian.org/Bonding
Oczywiście pakiet ifenslave-2.6 jest zainstalowany?
Widziałem już to wiki, nie ma tam nic odnośnie tematu..
Oczywiście, pakiet ifenslave jest zainstalowany, bo bez tego nie wystartuje bonding a problem nie jest w tym, że nie startuje i nie działa, tylko nie powraca do głównego interfejsu.
Awatar użytkownika
Unit
Beginner
Posty: 356
Rejestracja: 27 marca 2007, 09:39

Post autor: Unit »

Pokaż informacje zawarte w /var/log/syslog dotyczące problemu.
rysic
Beginner
Posty: 113
Rejestracja: 28 lipca 2009, 16:13

Post autor: rysic »

Kod: Zaznacz cały

Aug  3 10:20:13 PL02 kernel: [  149.492579] bnx2: eth0 NIC Copper Link is Down
Aug  3 10:20:13 PL02 kernel: [  149.524259] bonding: bond0: link status down for active interface eth0, disabling it in 200 ms.
Aug  3 10:20:13 PL02 kernel: [  149.724259] bonding: bond0: link status definitely down for interface eth0, disabling it
Aug  3 10:20:13 PL02 kernel: [  149.724263] bonding: bond0: making interface eth1 the new active one.

Aug  3 10:20:34 PL02 kernel: [  170.812009] bnx2: eth0 NIC Copper Link is Up, 1000 Mbps full duplex
Aug  3 10:20:34 PL02 kernel: [  170.824259] bonding: bond0: link status up for interface eth0, enabling it in 200 ms.
Aug  3 10:20:35 PL02 kernel: [  171.024271] bonding: bond0: link status definitely up for interface eth0.
Dokładnie to samo, co widać przez:

Kod: Zaznacz cały

cat /proc/net/bonding/bond0
Link wstaje, ale bond0 nie przełącza się na eth0 z powrotem.
Awatar użytkownika
Unit
Beginner
Posty: 356
Rejestracja: 27 marca 2007, 09:39

Post autor: Unit »

rysic pisze: Dokładnie to samo, co widać w cat /proc/net/bonding/bond0. Link wstaje, ale bond0 nie przełącza się na eth0 z powrotem.
Nie przełącza się, bo z eth1 nic się nie dzieje.
Na stronce: http://www.linuxhorizon.ro/bonding.html masz odpowiedź:
A different slave becomes active if, and only if, the active slave fails.
ODPOWIEDZ