NICがIPを取らなくなった
BagleBone BlackのNICが上がらなくなった。
ifconfigしてみても取っている様子がない。
root@beaglebone:~# ifconfig eth0 eth0 Link encap:Ethernet HWaddr 90:59:AF:5C:4D:B5 UP BROADCAST MULTICAST MTU:1500 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:0 (0.0 B) TX bytes:0 (0.0 B) Interrupt:56
dmesgにもそれらしいログはない。
systemdのせいでもないようだ。
root@beaglebone:~# systemctl status network network.service Loaded: error (Reason: No such file or directory) Active: inactive (dead)
リブートしてみてもかわらない。
NICが生きてない。
シリアルコンソールをつなげてみた。
[ 15.713063] libphy: PHY 4a101000.mdio:00 not found [ 15.718148] net eth0: phy 4a101000.mdio:00 not found on slave 0 [ 15.724381] libphy: PHY 4a101000.mdio:01 not found [ 15.729397] net eth0: phy 4a101000.mdio:01 not found on slave 1
なにこれ〜。
PHYのリセットに失敗した?
ubootのレベルでresetしてみる。
U-Boot 2013.04-dirty (Jun 19 2013 - 09:57:14) I2C: ready DRAM: 512 MiB WARNING: Caches not enabled NAND: No NAND device found!!! 0 MiB MMC: OMAP SD/MMC: 0, OMAP SD/MMC: 1 *** Warning - readenv() failed, using default environment musb-hdrc: ConfigData=0xde (UTMI-8, dyn FIFOs, HB-ISO Rx, HB-ISO Tx, SoftConn) musb-hdrc: MHDRC RTL version 2.0 musb-hdrc: setup fifo_mode 4 musb-hdrc: 28/31 max ep, 16384/16384 memory USB Peripheral mode controller at 47401000 using PIO, IRQ 0 musb-hdrc: ConfigData=0xde (UTMI-8, dyn FIFOs, HB-ISO Rx, HB-ISO Tx, SoftConn) musb-hdrc: MHDRC RTL version 2.0 musb-hdrc: setup fifo_mode 4 musb-hdrc: 28/31 max ep, 16384/16384 memory USB Host mode controller at 47401800 using PIO, IRQ 0 Net: <ethaddr> not set. Validating first E-fuse MAC Phy not found PHY reset timed out cpsw, usb_ether Hit any key to stop autoboot: 0 U-Boot#
MACアドレスが飛んだかな?
ubootレベルでリセットしてみる。
U-Boot# reset resetting ... U-Boot SPL 2013.04-dirty (Jun 19 2013 - 09:57:14) musb-hdrc: ConfigData=0xde (UTMI-8, dyn FIFOs, HB-ISO Rx, HB-ISO Tx, SoftConn) musb-hdrc: MHDRC RTL version 2.0 musb-hdrc: setup fifo_mode 4 musb-hdrc: 28/31 max ep, 16384/16384 memory USB Peripheral mode controller at 47401000 using PIO, IRQ 0 musb-hdrc: ConfigData=0xde (UTMI-8, dyn FIFOs, HB-ISO Rx, HB-ISO Tx, SoftConn) musb-hdrc: MHDRC RTL version 2.0 musb-hdrc: setup fifo_mode 4 musb-hdrc: 28/31 max ep, 16384/16384 memory USB Host mode controller at 47401800 using PIO, IRQ 0 OMAP SD/MMC: 0 mmc_send_cmd : timeout: No status update reading u-boot.img reading u-boot.img U-Boot 2013.04-dirty (Jun 19 2013 - 09:57:14) I2C: ready DRAM: 512 MiB WARNING: Caches not enabled NAND: No NAND device found!!! 0 MiB MMC: OMAP SD/MMC: 0, OMAP SD/MMC: 1 *** Warning - readenv() failed, using default environment musb-hdrc: ConfigData=0xde (UTMI-8, dyn FIFOs, HB-ISO Rx, HB-ISO Tx, SoftConn) musb-hdrc: MHDRC RTL version 2.0 musb-hdrc: setup fifo_mode 4 musb-hdrc: 28/31 max ep, 16384/16384 memory USB Peripheral mode controller at 47401000 using PIO, IRQ 0 musb-hdrc: ConfigData=0xde (UTMI-8, dyn FIFOs, HB-ISO Rx, HB-ISO Tx, SoftConn) musb-hdrc: MHDRC RTL version 2.0 musb-hdrc: setup fifo_mode 4 musb-hdrc: 28/31 max ep, 16384/16384 memory USB Host mode controller at 47401800 using PIO, IRQ 0 Net: <ethaddr> not set. Validating first E-fuse MAC Phy not found PHY reset timed out cpsw, usb_ether Hit any key to stop autoboot: 0 U-Boot#
ダメだな。
どうやら、いくつか報告がある事象のようだ。
Beaglebone black Ethernet instability: libphy: Link is Down
https://groups.google.com/forum/#!msg/beagleboard/Vp4pxwHm8BU/Iaw3p5xm0MoJ
Re: BeagleBone Black: Ethernet transmits packets but does not receive them - msg#01878
http://osdir.com/ml/beagleboard/2013-07/msg01878.html
BeagleBone ethernet troubles libphy
http://archlinuxarm.org/forum/viewtopic.php?f=28&t=5515
kernel/drivers/net/phy/libphy.ko.gz これ?
root@beaglebone:~# find / | grep libphy.ko root@beaglebone:~# find / | grep libphy
なさげ。
root@beaglebone:~# find /etc/systemd | grep netctl root@beaglebone:~# find /etc/ | grep netctl /etc/systemd/system/networking.service /etc/systemd/system/busybox-udhcpc.service root@beaglebone:~# systemctl status busybox-udhcpc busybox-udhcpc.service Loaded: masked (/dev/null) Active: inactive (dead) root@beaglebone:~# systemctl status networking networking.service Loaded: masked (/dev/null) Active: inactive (dead) root@beaglebone:~# ifup eth0 ifup: can't open '/etc/network/interfaces': No such file or directory root@beaglebone:~# systemctl start networking Failed to issue method call: Unit networking.service is masked.
root@beaglebone:~# cat /etc/systemd/system/networking.service
なんにもない...
root@beaglebone:~# cat /etc/systemd/system/busybox-udhcpc.service
これもなんにもない。
ファイル消えたってことかな?
それともなくて普通?(普通みたい)
root@beaglebone:~# systemctl enable netctl-ifplugd@eth0 Failed to issue method call: No such file or directory
でも、MACアドレスついてはいるんだよな。
root@beaglebone:~# ifconfig eth0 eth0 Link encap:Ethernet HWaddr 90:59:AF:5C:4D:B5 UP BROADCAST MULTICAST MTU:1500 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:0 (0.0 B) TX bytes:0 (0.0 B) Interrupt:56
HUBをリセットして、コールドブートしたら動くようになった。
root@beaglebone:~# ifconfig eth0 eth0 Link encap:Ethernet HWaddr 90:59:AF:5C:4D:B5 inet addr:192.168.1.101 Bcast:192.168.1.255 Mask:255.255.255.0 inet6 addr: fe80::9259:afff:fe5c:4db5/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:15 errors:0 dropped:0 overruns:0 frame:0 TX packets:41 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:2423 (2.3 KiB) TX bytes:9537 (9.3 KiB) Interrupt:56
HUBの調子悪かっただけか。