(求助)移植IXP425到2.6.16网络不通
大家好
请问一下我移植IXP425到2.6.16上...内核和文件系统都跑起来了...NPE驱动模块也正确加载好了...但是现在确出现了一个问题....扳子不能ping通外网..外网也不能ping通板子.....不明白是什么原因..望各位大侠指教...
其中板子和PC都是挂在同一台路由器下面,PC和板子属于同一网段内。。。使用的是直通线。。。PC端没有开放火墙。。。
板子ping自己能够通。。但是ping外网确不通。。。外网ping板子时在板子上ifconfig 可以看到
ixp1 Link encap:Ethernet HWaddr 00:02:B3:02:02:02
inet addr:202.102.224.8 Bcast:202.102.224.255
Mask:255.255.255.0 UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:9 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:256
RX bytes:911 (911.0 B) TX bytes:0 (0.0 B)
[ 本帖最后由 cltnet 于 2007-6-25 11:42 编辑 ]
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(9)
tcpdump试试??
什么叫外网?是指你的PC机还是别的什么?
只能收不能够发?
把PC ping扳子时的信息也那出来。系统启动信息。
再检查你是否真的使用的是直通线(用这个线换到PC上PING路由器)
[ 本帖最后由 epegasus 于 2007-6-25 20:23 编辑 ]
外网就是我的PC 我在板子上ping 我的PC不通。。。。
使用我的PC ping 板子也不行。。。。。
串口信息如下。。。
Ethernet eth1: MAC address 00:00:84:28:50:02
IP: 202.102.224.103/255.255.255.0, Gateway: 202.102.224.1
Default server: 202.102.224.2, DNS server IP: 202.102.224.2
RedBoot>
RedBoot> load -r -v -b 0x800000 ramdisk2.gz
Using default protocol (TFTP)
|
Raw file loaded 0x00800000-0x00a6c9aa, assumed entry at 0x00800000
RedBoot> load -r -v -b 0x3000000 zImage1
Using default protocol (TFTP)
|
Raw file loaded 0x03000000-0x0313697b, assumed entry at 0x03000000
RedBoot> exec 0x3000000 -c "console=ttyS0,115200 root=/dev/ram0 initrd=0x800000,0x400000 mem=64M@0x0"
entry is 0x6000000
load_addr is 0x3000000
length is 0x13697c
Using base address 0x03000000 and length 0x0013697c
trampoline is 0x1f00
Uncompressing Linux................................................................................... done, booting the kernel.
Linux version 2.6.16.11 (root@localhost.localdomain) (gcc version 3.4.1 20040714 (TimeSys 3.4.1-7)) #1 Mon Jun 11 15:28:34 CST 2007
CPU: XScale-IXP42x Family [690541c1] revision 1 (ARMv5TE)
Machine: Intel IXDP425 Development Platform
Memory policy: ECC disabled, Data cache writeback
CPU0: D VIVT undefined 5 cache
CPU0: I cache: 32768 bytes, associativity 32, 32 byte lines, 32 sets
CPU0: D cache: 32768 bytes, associativity 32, 32 byte lines, 32 sets
Built 1 zonelists
Kernel command line: console=ttyS0,115200 root=/dev/ram0 initrd=0x800000,0x400000 mem=64M@0x0
PID hash table entries: 512 (order: 9, 8192 bytes)
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
Memory: 64MB = 64MB total
Memory: 58044KB available (2092K code, 440K data, 128K init)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
checking if image is initramfs...it isn't (no cpio magic); looks like an initrd
Freeing initrd memory: 4096K
NET: Registered protocol family 16
IXP4xx: Using 16MiB expansion bus window size
PCI: IXP4xx is host
PCI: IXP4xx Using direct access for memory space
PCI: bus0: Fast back to back transfers enabled
NetWinder Floating Point Emulator V0.97 (double precision)
JFFS2 version 2.2. (NAND) (C) 2001-2003 Red Hat, Inc.
io scheduler noop registered
io scheduler anticipatory registered (default)
io scheduler deadline registered
io scheduler cfq registered
IXP4xx Watchdog Timer: heartbeat 60 sec
Serial: 8250/16550 driver $Revision: 1.90 $ 2 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0xc8000000 (irq = 15) is a XScale
serial8250.0: ttyS1 at MMIO 0xc8001000 (irq = 13) is a XScale
RAMDISK driver initialized: 16 RAM disks of 8192K size 1024 blocksize
loop: loaded (max 8 devices)
Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 50MHz system bus speed for PIO modes; override with idebus=xx
IXP4XX-Flash.0: Found 1 x16 devices at 0x0 in 16-bit bank
Intel/Sharp Extended Query Table at 0x0031
Using buffer write method
cfi_cmdset_0001: Erase suspend on write enabled
Searching for RedBoot partition table in IXP4XX-Flash.0 at offset 0x7e0000
6 RedBoot partitions found on MTD device IXP4XX-Flash.0
Creating 6 MTD partitions on "IXP4XX-Flash.0":
0x00000000-0x00040000 : "RedBoot"
0x00040000-0x000c0000 : "kernel"
0x001c0000-0x005c0000 : "ramdisk"
0x005c0000-0x007c0000 : "jffs2"
0x007c0000-0x007e0000 : "RedBoot config"
0x007e0000-0x00800000 : "FIS directory"
mice: PS/2 mouse device common for all mice
i2c /dev entries driver
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 4096 (order: 2, 16384 bytes)
TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
TCP: Hash tables configured (established 4096 bind 4096)
TCP reno registered
TCP bic registered
NET: Registered protocol family 1
NET: Registered protocol family 8
NET: Registered protocol family 20
RAMDISK: Compressed image found at block 0
VFS: Mounted root (ext2 filesystem).
Freeing init memory: 128K
Fri Nov 11 12:00:00 UTC 2005
Centaur Home Gateway,, Inc., Copyright (C) 06 11, 2007.
Linux SOHO Gateway
ifconfig: eth0: error fetching interface information: Device not found
eth0 is down, check the hardware and try again!
loading HTTP server
loading TFTP server
loading firewall
ifconfig: eth1: error fetching interface information: Device not found
ifconfig: eth1: error fetching interface information: Device not found
WAN Port is not assigned an IP address, firewall is not set, exit
BusyBox v1.00 (2007.06.12-08:04+0000) Built-in shell (ash)
Enter 'help' for a list of built-in commands.
/ # insmod /lib/modules/net/ixp400.ko
Using /lib/modules/net/ixp400.ko
ixp400: module license 'unspecified' taints kernel.
/ # mknod /dev/ixNpe c 241 0
/ # cat /etc/IxNpeMicrocode.dat > /dev/ixNpe
/ # insmod /lib/modules/net/ixp400_eth.ko
Using /lib/modules/net/ixp400_eth.ko
ixp400_eth: no version for "ixQMgrInit" found: kernel tainted.
ixp400_eth: Initializing IXP400 NPE Ethernet driver software v. 1.7
ixp400_eth: CPU clock speed (approx) = 532 MHz
ixp400_eth: Found PHY 0 at address 1
ixp400_eth: Found PHY 1 at address 2
ixp400_eth: ixp0 is using NPEB and the PHY at address 1
ixp400_eth: ixp1 is using NPEC and the PHY at address 2
ixp400_eth: Use default MAC address 00:02:b3:01:01:01 for port 0
ixp400_eth: Use default MAC address 00:02:b3:02:02:02 for port 1
/ # ifconfig
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 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:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
/ # ifconfig ixp1 202.102.224.5 netmask 255.255.255.0 up
/ # ifconfig
ixp1 Link encap:Ethernet HWaddr 00:02:B3:02:02:02
inet addr:202.102.224.5 Bcast:202.102.224.255 Mask:255.255.255.0
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:5 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:256
RX bytes:771 (771.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:16436 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:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
/ # ifconfig
ixp1 Link encap:Ethernet HWaddr 00:02:B3:02:02:02
inet addr:202.102.224.5 Bcast:202.102.224.255 Mask:255.255.255.0
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:6 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:256
RX bytes:831 (831.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:16436 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:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
/ # ifconfig
ixp1 Link encap:Ethernet HWaddr 00:02:B3:02:02:02
inet addr:202.102.224.5 Bcast:202.102.224.255 Mask:255.255.255.0
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:7 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:256
RX bytes:891 (891.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:16436 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:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
/ #
/ # ping 202.102.224.5
PING 202.102.224.5 (202.102.224.5): 56 data bytes
64 bytes from 202.102.224.5: icmp_seq=0 ttl=64 time=0.3 ms
64 bytes from 202.102.224.5: icmp_seq=1 ttl=64 time=0.2 ms
64 bytes from 202.102.224.5: icmp_seq=2 ttl=64 time=0.1 ms
64 bytes from 202.102.224.5: icmp_seq=3 ttl=64 time=0.2 ms
64 bytes from 202.102.224.5: icmp_seq=4 ttl=64 time=0.1 ms
64 bytes from 202.102.224.5: icmp_seq=5 ttl=64 time=0.2 ms
64 bytes from 202.102.224.5: icmp_seq=6 ttl=64 time=0.1 ms
64 bytes from 202.102.224.5: icmp_seq=7 ttl=64 time=0.2 ms
64 bytes from 202.102.224.5: icmp_seq=8 ttl=64 time=0.1 ms
64 bytes from 202.102.224.5: icmp_seq=9 ttl=64 time=0.2 ms
64 bytes from 202.102.224.5: icmp_seq=10 ttl=64 time=0.1 ms
ping 自己能够通。。。
板子上ping PC 信息如下。。
/etc # ping 202.102.224.2
PING 202.102.224.2 (202.102.224.2): 56 data bytes
红色的地方怀疑就是问题的所在。。。可是还不太明白。。。
以下是我在PC上ping 板子的信息
Connection-specific DNS Suffix . :
IP Address. . . . . . . . . . . . : 202.102.224.2
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 202.102.224.1
C:\Documents and Settings\T>ping 202.102.224.5 -t
Pinging 202.102.224.5 with 32 bytes of data:
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Ping statistics for 202.102.224.5:
Packets: Sent = 8, Received = 0, Lost = 8 (100% loss),
Control-C
^C
C:\Documents and Settings\T>arp -a
Interface: 202.102.224.2 --- 0x20002
Internet Address Physical Address Type
202.102.224.1 00-0e-a0-00-77-b3 dynamic
C:\Documents and Settings\T>
板子和PC都是通过直通线连接在一台路由器上面的。。。。把那根线换到PC上能够ping通路由器。。。
谢谢。。。
[ 本帖最后由 cltnet 于 2007-6-26 11:27 编辑 ]
我也遇到同样的问题,前2天还是好的,晕死
我还发现,ixp0只能发不能收
ixp1 只能收不能发,晕死了
[ 本帖最后由 smalloc 于 2007-6-26 11:36 编辑 ]
那你解决了吗。。我把NPE驱动模块弄上去后。。。就是这样了。。。
以前网卡驱动这里改过
static int phyAddresses[IXP425_ETH_ACC_MII_MAX_ADDR] =
{
#if defined(CONFIG_ARCH_IXDP425)
/* 1 PHY per NPE port */
13, /* Port 1 (IX_ETH_PORT_1 / NPE B) */ //这里的13,14是改了的,以前是1,0改了据说就可以了,
14 /* Port 2 (IX_ETH_PORT_2 / NPE C) */ //前2天好象还可以,用过tft下过东西,你看看.
那里的1和0好像只是表示一个代号。。。两块网卡。。。应该不会有太大的影响。。。
并且我的现在就是1和0。。
只是代号吗?我没仔细看,是别人改的,真的没什么影响,phyaddress没有什么影响吗?
[ 本帖最后由 smalloc 于 2007-6-26 12:17 编辑 ]
我晕,我的又好了,吃了顿饭,就好了.....
我想这样的ixp0,还是ixp1选择一个,UP,另一个down,然后再去吃顿饭......
[ 本帖最后由 smalloc 于 2007-6-26 12:33 编辑 ]