ifconfig.eth0/ipv4 or ifcfg-eth0 why the difference
bruce.dubbs at gmail.com
Tue Feb 9 16:19:09 PST 2010
> On Tue, Feb 9, 2010 at 1:42 PM, Bruce Dubbs <bruce.dubbs at gmail.com> wrote:
>> I see what the problem is. The gateway is OK for /8, but wrong for /24.
>> IN a /24 network, the .0 address is the network address, not a host
>> address. You've set it up incorrectly on the LiveCD. Either change the
>> gateway to .1 or the prefix to 8 on the LiveCD instance.
> That LFS LiveCD 6.3 r2160 is setting the config itself.
> route -n shows:
> Kernel IP routing table
> Destination Gateway Genmask Flags Metric Ref Use Iface
> 10.0.2.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
> 0.0.0.0 10.0.2.2 0.0.0.0 UG 0 0 0 eth0
This is fine, but the system that it is communicating with should
have the same network mask.
> This is also the same for all my other VMs. VirtualBox sets all VMs to
> this private network and each one is completely separate from the
> others. If I set PREFIX=24 in my LFS build the kernel complains with
The kernel is not complaining, but the program or script setting the ip
address is doing the complaining.
You always solve these types of problems by doing the steps manually,
not by scripts.
ip addr add 10.0.2.15/24 broadcast 10.0.2.255 dev eth0
ip link set eth0 up
The route seems to be set up, but you would do that manually with
ip route add default via 10.0.2.0 dev eth0
Once you get it to work manually, then we can address the scripts.
More information about the lfs-support