RTNETLINK 回答:无效参数

RTNETLINK 回答:无效参数

当我的系统启动时,它会显示以下消息。

Bringing up loopback interface:  [  OK  ]
Bringing up interface eth0:  RTNETLINK answers: Invalid argument
[  OK  ]
Bringing up interface eth1:  RTNETLINK answers: Invalid argument
[  OK  ]
Bringing up interface eth2:  RTNETLINK answers: Invalid argument
[  OK  ]
Bringing up interface eth3:  RTNETLINK answers: Invalid argument
[  OK  ]

为什么会发生这种情况。通常它不会给出消息RTNETLINK answers: Invalid argument

我这样做了ifconfig,输出是

eth0      Link encap:Ethernet  HWaddr 00:00:50:6D:56:B4  
          inet addr:120.0.10.137  Bcast:120.0.255.255  Mask:255.255.255.0
          inet6 addr: fe80::200:50ff:fe6d:56b4/64 Scope:Link
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:3 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 b)  TX bytes:214 (214.0 b)
          Base address:0xa000 

eth1      Link encap:Ethernet  HWaddr 00:00:50:6D:56:B5  
          inet addr:121.0.10.137  Bcast:121.0.255.255  Mask:255.255.255.0
          inet6 addr: fe80::200:50ff:fe6d:56b5/64 Scope:Link
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:3 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 b)  TX bytes:214 (214.0 b)
          Base address:0xc000 

eth2      Link encap:Ethernet  HWaddr 00:00:50:6D:56:B6  
          inet addr:128.0.10.137  Bcast:128.0.255.255  Mask:255.255.255.0
          inet6 addr: fe80::200:50ff:fe6d:56b6/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:14 errors:0 dropped:0 overruns:0 frame:0
          TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:1006 (1006.0 b)  TX bytes:396 (396.0 b)
          Interrupt:16 

eth3      Link encap:Ethernet  HWaddr 00:00:50:6D:56:B7  
          inet addr:123.0.10.137  Bcast:123.0.255.255  Mask:255.255.255.0
          inet6 addr: fe80::200:50ff:fe6d:56b7/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:10 errors:0 dropped:0 overruns:0 frame:0
          TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:728 (728.0 b)  TX bytes:396 (396.0 b)
          Interrupt:17 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:14 errors:0 dropped:0 overruns:0 frame:0
          TX packets:14 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:980 (980.0 b)  TX bytes:980 (980.0 b)

该消息的原因可能是什么以及如何将其更改为正常?

谢谢

答案1

我猜你更改了你的 IP 地址。请确保 IP 地址、掩码和网关属于同一类(A 类或 B 类或 C 类)

我的下一个猜测是,您已将“DHCP”地址更改为“静态”地址。如果是这种情况,请确保管理员已从 DHCP 范围中删除 IP 地址,因为 DHCP 范围是该地址的所有者。您的配置应该看起来像这样

root@servername network-scripts]# vi ifcfg-eth0

DEVICE=eth0
BOOTPROTO=static
IPADDR=10.206.2.4
GATEWAY=10.206.255.255
NETMASK=255.255.0.0


root@servername network-scripts]# service network restart

希望这对你有帮助

答案2

这可能与您在 /etc/sysconfig/network-scripts/ifcfg-eth* 文件中设置的选项有关。您可能在其中设置了一些不正确的选项。

答案3

乍一看,您的网络掩码和/或广播地址似乎是错误的。

如果您所在的网络是 121.0.10.0/24,那么广播地址通常应该是 121.0.10.255,而不是像您这样的 121.0.255.255。我不知道这是否真的会导致您看到的错误,或者它是否只是“转移注意力的借口”,但在我看来您的网络配置肯定是错误的,需要仔细检查。

http://jodies.de/ipcalc?host=121.0.10.137&mask1=24&mask2=

相关内容