# ifconfig eth0 up
[   32.627544] Generic PHY stmmac-0:01: attached PHY driver [Generic PHY] (mii_bus:phy_addr=stmmac-0:01, irq=-1)
[   32.639435] dwmac-sun8i 1c30000.ethernet eth0: No MAC Management Counters available
[   32.647233] dwmac-sun8i 1c30000.ethernet eth0: PTP not supported by HW
# ifup eth0
ifup: ignoring unknown interface eth0
# [   97.666629] random: crng init done
# ifconfig eth0 192.168.1.100
# ifconfig
eth0      Link encap:Ethernet  HWaddr 02:00:91:F6:8D:99  
          inet addr:192.168.1.100  Bcast:192.168.1.255  Mask:255.255.255.0
          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:38 
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  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)
# ping 10.23.14.63
PING 10.23.14.63 (10.23.14.63): 56 data bytes
ping: sendto: Network is unreachable我在串口助手上进行ping操作,请问怎么才知道v3s的网卡是正常工作?ping的地址应该是ping什么地址,v3s需要接网线吗?
离线
离线
V3s地址:192.168.1.100
子网掩码:255.255.255.0如果你不设置网关的情况下,是不能ping通 ping 10.23.14.63
只能ping通: 192.168.1.1 - 192.168.1.254
网有多大, 由子网掩码控制了!
我在u-boot命令行中设置了网关ip是
ethact=ethernet@1c30000
ethaddr=02:00:91:f6:8d:99
fdt_addr_r=0x41800000
fdtcontroladdr=43b40128
fdtfile=sun8i-v3s-licheepi-zero.dtb
gatewayip=192.168.253.1
ipaddr=192.168.126.100
kernel_addr_r=0x41000000
load_efi_dtb=load ${devtype} ${devnum}:${distro_bootpart} ${fdt_addr_r} ${prefix}${efi_fdtfile}
mmc_boot=if mmc dev ${devnum}; then setenv devtype mmc; run scan_dev_for_boot_part; fi
netmask=255.255.255.0这样算设置了网关?
离线
晕哥 说:V3s地址:192.168.1.100
子网掩码:255.255.255.0如果你不设置网关的情况下,是不能ping通 ping 10.23.14.63
只能ping通: 192.168.1.1 - 192.168.1.254
网有多大, 由子网掩码控制了!
我在u-boot命令行中设置了网关ip是
ethact=ethernet@1c30000 ethaddr=02:00:91:f6:8d:99 fdt_addr_r=0x41800000 fdtcontroladdr=43b40128 fdtfile=sun8i-v3s-licheepi-zero.dtb gatewayip=192.168.253.1 ipaddr=192.168.126.100 kernel_addr_r=0x41000000 load_efi_dtb=load ${devtype} ${devnum}:${distro_bootpart} ${fdt_addr_r} ${prefix}${efi_fdtfile} mmc_boot=if mmc dev ${devnum}; then setenv devtype mmc; run scan_dev_for_boot_part; fi netmask=255.255.255.0这样算设置了网关?
如果你要设置linux下的地址,就不要去弄u-boot的设置了,那不是一回事了。
linux启动后, u-boot就彻底不见了,你设置啥都没用了。
离线
linux下设置网关有专门的命令:
route add default gw 192.168.0.xxx
还有就是进行ping操作的时候 v3s板子需要接上网线?
我接上路由器网线就
# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
# [  257.926361] dwmac-sun8i 1c30000.ethernet eth0: Link is Up - 100Mbps/Full - flow control rx/tx离线
那v3s板子不接网线 可以ping通笔记本?
离线
不接网线能ping通?有无线网卡吧?
离线
不接网线能ping通?有无线网卡吧?
我现在有点搞不懂原理,是将笔记本本v3s板子连在一起,然后进行ping?能ping通说明网卡正常工作?
离线
ippen 说:不接网线能ping通?有无线网卡吧?
我现在有点搞不懂原理,是将笔记本本v3s板子连在一起,然后进行ping?能ping通说明网卡正常工作?
对, ping 就是 icmp 协议, 就是一个回应协议,刷存在感的。
离线
但是我把v3s板子和笔记本连在一起还是平不同、
ping 169.254.63.187
PING 169.254.63.187 (169.254.63.187): 56 data bytes
ping: sendto: Network is unreachable
# [  607.606202] dwmac-sun8i 1c30000.ethernet eth0: Link is Down169.254.63.187是我将v3s和笔记本连在一起时候,笔记本的IP地址,..是驱动没设置好?
离线
但是我把v3s板子和笔记本连在一起还是平不同、
ping 169.254.63.187 PING 169.254.63.187 (169.254.63.187): 56 data bytes ping: sendto: Network is unreachable # [ 607.606202] dwmac-sun8i 1c30000.ethernet eth0: Link is Down169.254.63.187是我将v3s和笔记本连在一起时候,笔记本的IP地址,..是驱动没设置好?
169.254.x.x 是无dhcp环境自动分配的IP
windows 有可能 禁止ping,所以从v3s ping windows 可能不通,可以试一下从windows ping v3s,如果通,就说明网络没问题
如果不通,就检查两边的ip地址设置,可以手动设置两边的IP,然后用ping测试
离线
那应该设置静态IP吧
离线
已经解决了 谢谢大家
离线
怎么解决的?
离线
怎么解决的?
我没有将电脑IP地址和板子的IP地址设置在同一网段下,所以ping不通,设置在同一网段下就可以了
离线
U-Boot SPL 2017.01-rc2-00057-g32ab180-dirty (Sep 22 2020 - 17:16:15)
DRAM: 64 MiB
Trying to boot from MMC1
U-Boot 2017.01-rc2-00057-g32ab180-dirty (Sep 22 2020 - 17:16:15 +0800) Allwinner Technology
CPU:   Allwinner V3s (SUN8I 1681)
Model: Lichee Pi Zero
DRAM:  64 MiB
MMC:   SUNXI SD/MMC: 0
*** Warning - bad CRC, using default environment
Setting up a 800x480 lcd console (overscan 0x0)
dotclock: 33000kHz = 33000kHz: (1 * 3MHz * 66) / 6
In:    serial@01c28000
Out:   serial@01c28000
Err:   serial@01c28000
U-Boot 2017.01-rc2-00057-g32ab180-dirty (Sep 22 2020 - 17:16:15 +0800) Allwinner Technology
CPU:   Allwinner V3s (SUN8I 1681)
Model: Lichee Pi Zero
DRAM:  64 MiB
MMC:   SUNXI SD/MMC: 0
*** Warning - bad CRC, using default environment
Setting up a 800x480 lcd console (overscan 0x0)
dotclock: 33000kHz = 33000kHz: (1 * 3MHz * 66) / 6
In:    serial@01c28000
Out:   serial@01c28000
Err:   serial@01c28000
Net:   phy interface0
eth0: ethernet@1c30000
starting USB...
No controllers found
Hit any key to stop autoboot:  0 
reading zImage
3692752 bytes read in 234 ms (15 MiB/s)
reading sun8i-v3s-licheepi-zero.dtb
8039 bytes read in 25 ms (313.5 KiB/s)
## Flattened Device Tree blob at 41800000
   Booting using the fdt blob at 0x41800000
   Loading Device Tree to 42dfb000, end 42dfff66 ... OK
Cannot setup simplefb: node not found
Starting kernel ...
[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.12.0-rc1-00089-g19e52b7 (root@eason-virtual-machine) (gcc version 6.3.1 20170404 (Linaro GCC 6.3-2017.05) ) #2 SMP Wed Sep 23 10:10:14 CST 2020
[    0.000000] CPU: ARMv7 Processor [410fc075] revision 5 (ARMv7), cr=10c5387d
[    0.000000] CPU: div instructions available: patching division code
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] OF: fdt: Machine model: Lichee Pi Zero
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] percpu: Embedded 16 pages/cpu @c3f62000 s33484 r8192 d23860 u65536
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 16256
[    0.000000] Kernel command line: console=ttyS0,115200 panic=5 rootwait root=/dev/mmcblk0p2 earlyprintk rw  vt.global_cursor_default=0
[    0.000000] PID hash table entries: 256 (order: -2, 1024 bytes)
[    0.000000] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Memory: 54964K/65536K available (6144K kernel code, 363K rwdata, 1368K rodata, 1024K init, 253K bss, 10572K reserved, 0K cma-reserved, 0K highmem)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xc4800000 - 0xff800000   ( 944 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xc4000000   (  64 MB)
[    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
[    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
[    0.000000]       .text : 0xc0008000 - 0xc0700000   (7136 kB)
[    0.000000]       .init : 0xc0900000 - 0xc0a00000   (1024 kB)
[    0.000000]       .data : 0xc0a00000 - 0xc0a5ac80   ( 364 kB)
[    0.000000]        .bss : 0xc0a61298 - 0xc0aa07a4   ( 254 kB)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000]  RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
[    0.000000] NR_IRQS:16 nr_irqs:16 16
[    0.000000] arch_timer: cp15 timer(s) running at 24.00MHz (virt).
[    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x588fe9dc0, max_idle_ns: 440795202592 ns
[    0.000008] sched_clock: 56 bits at 24MHz, resolution 41ns, wraps every 4398046511097ns
[    0.000018] Switching to timer-based delay loop, resolution 41ns
[    0.000154] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[    0.000378] Console: colour dummy device 80x30
[    0.000414] Calibrating delay loop (skipped), value calculated using timer frequency.. 48.00 BogoMIPS (lpj=240000)
[    0.000429] pid_max: default: 32768 minimum: 301
[    0.000562] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.000573] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.001185] CPU: Testing write buffer coherency: ok
[    0.001555] /cpus/cpu@0 missing clock-frequency property
[    0.001575] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
[    0.002017] Setting up static identity map for 0x40100000 - 0x40100060
[    0.002648] smp: Bringing up secondary CPUs ...
[    0.002664] smp: Brought up 1 node, 1 CPU
[    0.002673] SMP: Total of 1 processors activated (48.00 BogoMIPS).
[    0.002680] CPU: All CPU(s) started in SVC mode.
[    0.003423] devtmpfs: initialized
[    0.005833] VFP support v0.3: implementor 41 architecture 2 part 30 variant 7 rev 5
[    0.006094] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.006124] futex hash table entries: 256 (order: 2, 16384 bytes)
[    0.006279] pinctrl core: initialized pinctrl subsystem
[    0.007302] NET: Registered protocol family 16
[    0.007774] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.008851] hw-breakpoint: found 5 (+1 reserved) breakpoint and 4 watchpoint registers.
[    0.008867] hw-breakpoint: maximum watchpoint size is 8 bytes.
[    0.019896] SCSI subsystem initialized
[    0.020639] usbcore: registered new interface driver usbfs
[    0.020707] usbcore: registered new interface driver hub
[    0.020794] usbcore: registered new device driver usb
[    0.021019] pps_core: LinuxPPS API ver. 1 registered
[    0.021029] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    0.021051] PTP clock support registered
[    0.021303] Advanced Linux Sound Architecture Driver Initialized.
[    0.022441] clocksource: Switched to clocksource arch_sys_counter
[    0.033603] NET: Registered protocol family 2
[    0.034178] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[    0.034219] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[    0.034243] TCP: Hash tables configured (established 1024 bind 1024)
[    0.034376] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    0.034428] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    0.034651] NET: Registered protocol family 1
[    0.035324] RPC: Registered named UNIX socket transport module.
[    0.035344] RPC: Registered udp transport module.
[    0.035350] RPC: Registered tcp transport module.
[    0.035355] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.037370] workingset: timestamp_bits=30 max_order=14 bucket_order=0
[    0.046932] NFS: Registering the id_resolver key type
[    0.046980] Key type id_resolver registered
[    0.046988] Key type id_legacy registered
[    0.048271] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 249)
[    0.048292] io scheduler noop registered
[    0.048299] io scheduler deadline registered
[    0.048344] io scheduler cfq registered (default)
[    0.048352] io scheduler mq-deadline registered
[    0.048358] io scheduler kyber registered
[    0.053240] sun8i-v3s-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver
[    0.121630] Serial: 8250/16550 driver, 8 ports, IRQ sharing disabled
[    0.125070] console [ttyS0] disabled
[    0.145335] 1c28000.serial: ttyS0 at MMIO 0x1c28000 (irq = 30, base_baud = 1500000) is a U6_16550A
[    0.702576] console [ttyS0] enabled
[    0.708050] libphy: Fixed MDIO Bus: probed
[    0.712162] CAN device driver interface
[    0.717513] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    0.724134] ehci-platform: EHCI generic platform driver
[    0.729454] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    0.735686] ohci-platform: OHCI generic platform driver
[    0.742137] sun6i-rtc 1c20400.rtc: rtc core: registered rtc-sun6i as rtc0
[    0.749015] sun6i-rtc 1c20400.rtc: RTC enabled
[    0.753667] i2c /dev entries driver
[    0.757377] IR NEC protocol handler initialized
[    0.761905] IR RC5(x/sz) protocol handler initialized
[    0.766995] IR RC6 protocol handler initialized
[    0.771520] IR JVC protocol handler initialized
[    0.776061] IR Sony protocol handler initialized
[    0.780672] IR SANYO protocol handler initialized
[    0.785379] IR Sharp protocol handler initialized
[    0.790076] IR MCE Keyboard/mouse protocol handler initialized
[    0.795909] IR XMP protocol handler initialized
[    0.801174] sunxi-wdt 1c20ca0.watchdog: Watchdog enabled (timeout=16 sec, nowayout=0)
[    0.862494] sunxi-mmc 1c0f000.mmc: base:0xc485d000 irq:22
[    0.869472] usbcore: registered new interface driver usbhid
[    0.875140] usbhid: USB HID core driver
[    0.880453] NET: Registered protocol family 17
[    0.885044] can: controller area network core (rev 20170425 abi 9)
[    0.891319] NET: Registered protocol family 29
[    0.895809] can: raw protocol (rev 20170425)
[    0.900078] can: broadcast manager protocol (rev 20170425 t)
[    0.905760] can: netlink gateway (rev 20170425) max_hops=1
[    0.911544] Key type dns_resolver registered
[    0.915994] Registering SWP/SWPB emulation handler
[    0.927358] usb_phy_generic usb_phy_generic.0.auto: usb_phy_generic.0.auto supply vcc not found, using dummy regulator
[    0.938788] musb-hdrc musb-hdrc.1.auto: MUSB HDRC host driver
[    0.944642] musb-hdrc musb-hdrc.1.auto: new USB bus registered, assigned bus number 1
[    0.955825] hub 1-0:1.0: USB hub found
[    0.959700] hub 1-0:1.0: 1 port detected
[    0.964587] sun6i-rtc 1c20400.rtc: setting system clock to 1970-01-01 00:24:14 UTC (1454)
[    0.973039] vcc3v0: disabling
[    0.976012] vcc5v0: disabling
[    0.978976] ALSA device list:
[    0.981930]   No soundcards found.
[    0.986418] Waiting for root device /dev/mmcblk0p2...
[    1.034200] mmc0: host does not support reading read-only switch, assuming write-enable
[    1.044062] mmc0: new high speed SD card at address 21b7
[    1.050129] mmcblk0: mmc0:21b7 XTSDA 122 MiB 
[    1.055873]  mmcblk0: p1 p2
[    1.073460] EXT4-fs (mmcblk0p2): couldn't mount as ext3 due to feature incompatibilities
[    1.082362] EXT4-fs (mmcblk0p2): couldn't mount as ext2 due to feature incompatibilities
[    1.096825] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[    1.105120] VFS: Mounted root (ext4 filesystem) on device 179:2.
[    1.113356] devtmpfs: mounted
[    1.117500] Freeing unused kernel memory: 1024K
[    1.239606] EXT4-fs (mmcblk0p2): re-mounted. Opts: data=ordered
Starting logging: OK
Starting mdev...
modprobe: can't change directory to '/lib/modules': No such file or directory
Initializing random number generator... [    2.275630] random: dd: uninitialized urandom read (512 bytes read)
done.
Starting network: OK
Welcome to Buildroot
buildroot login: root
# cd /
# ifconfig [   11.203565] random: fast init done
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  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)
# ifconfig 
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  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)
# ifconfig -a
eth0      Link encap:Ethernet  HWaddr 02:01:3F:A9:80:1C  
          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)
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  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)
# ifup eth0
ifup: ignoring unknown interface eth0
# 
# 
# 
# ifup eth0
ifup: ignoring unknown interface eth0
# 
# ifconfig eth0 up
[   45.091683] sun8i-emac 1c30000.ethernet: EMAC reset timeout
ifconfig: SIOCSIFFLAGS: Bad address
# 
# 
# ifconfig eth0 up
[   48.242901] libphy: 1c30000.ethernet: probed
[   48.257117] Generic PHY 1c30000.ethernet-0:01: attached PHY driver [Generic PHY] (mii_bus:phy_addr=1c30000.ethernet-0:01, irq=-1)
[   48.268898] sun8i-emac 1c30000.ethernet: device MAC address slot 0 02:01:3f:a9:80:1c
[   48.277097] sun8i-emac 1c30000.ethernet: device MAC address slot 1 01:00:5e:00:00:01
# 
# 
# ifconfig 
eth0      Link encap:Ethernet  HWaddr 02:01:3F:A9:80:1C  
          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)
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  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)
# 
# 
# ifconfig eth0 192.168.1.111 netmask 255.255.255.0
[   70.620278] sun8i-emac 1c30000.ethernet: device MAC address slot 1 01:00:5e:00:00:01
# route add default gw 192.168.1.1
# 
# 
# ifconfig 
eth0      Link encap:Ethernet  HWaddr 02:01:3F:A9:80:1C  
          inet addr:192.168.1.111  Bcast:192.168.1.255  Mask:255.255.255.0
          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)
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  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)
# ifdown eth0
ifdown: interface eth0 not configured
# 
# 
# ifconfig eth0 down
[  154.235700] sun8i-emac 1c30000.ethernet: device MAC address slot 1 01:00:5e:00:00:01
# ifconfig 
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  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)
# ifconfig -a
eth0      Link encap:Ethernet  HWaddr 02:01:3F:A9:80:1C  
          inet addr:192.168.1.111  Bcast:192.168.1.255  Mask:255.255.255.0
          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)
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  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)
# ifup eth0
ifup: ignoring unknown interface eth0
# ifconfig eth0 up
[  177.118765] libphy: 1c30000.ethernet: probed
[  177.137264] Generic PHY 1c30000.ethernet-0:01: attached PHY driver [Generic PHY] (mii_bus:phy_addr=1c30000.ethernet-0:01, irq=-1)
[  177.149049] sun8i-emac 1c30000.ethernet: device MAC address slot 0 02:01:3f:a9:80:1c
[  177.157236] sun8i-emac 1c30000.ethernet: device MAC address slot 1 01:00:5e:00:00:01
# 晕哥 能帮忙看下是哪的问题吗 网卡启动不了 使用ifup eth0命令后返回ifup: ignoring unknown interface eth0; 无法启动网卡 ; 使用ifconfig eth0 up可以启动 但是需要启动两次才行,如下:
# ifconfig eth0 up
[  115.841536] sun8i-emac 1c30000.ethernet: EMAC reset timeout
ifconfig: SIOCSIFFLAGS: Bad address
# ifconfig eth0 up
[  117.653642] libphy: 1c30000.ethernet: probed
[  117.667119] Generic PHY 1c30000.ethernet-0:01: attached PHY driver [Generic PHY] (mii_bus:phy_addr=1c30000.ethernet-0:01, irq=-1)
[  117.678902] sun8i-emac 1c30000.ethernet: device MAC address slot 0 02:01:3f:a9:80:1c
[  117.687114] sun8i-emac 1c30000.ethernet: device MAC address slot 1 01:00:5e:00:00:01
# 设置好ip也不能ping通  电脑网口也识别不出插入网线,估计还是网卡没有启动;使用的内核是荔枝派官方适配好的,版本是4.12;
关闭网卡也有问题,如下:
# ifdown eth0
ifdown: interface eth0 not configured
# 使用ifconfig eth0 down是可以关闭:
# ifconfig eth0 down
[  267.065531] sun8i-emac 1c30000.ethernet: device MAC address slot 1 01:00:5e:00:00:01
# 晕哥帮忙分析一下,应该跟文件系统没有关系吧; 各位大佬有没有遇到过的,希望不吝指教; 谢谢各位;
离线
linux下设置网关有专门的命令:
route add default gw 192.168.0.xxx
我已经设置了网关,但仍然无法ping通。
离线