[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: problem whit virtual interfaces [SOLVED]



On Fri, Jan 22, 2010 at 03:46:21PM +0100, Marco Vaschetto wrote:
> Camaleón ha scritto:
>> On Fri, 22 Jan 2010 14:09:48 +0100, Marco Vaschetto wrote:
>>
>>   
>>> Camaleón ha scritto:
>>>     
>>>> On Fri, 22 Jan 2010 13:11:18 +0100, Marco Vaschetto wrote:
>>>>
>>>>
>>>>       
>>>>> iface eth0 inet static
>>>>>                 
>>>> Shouldn't that read "iface eth0:1 inet static"? :-?
>>>>                            ^^^^^^
>>>>
>>>>
>>>>       
>>> I have try whit static configuration for eth0 and the alias, like:
>>>     
>>
>> (...)
>>    
>>> And I try to configure (*eth0*)* *whit the local Ethernet ip address and
>>> the alias (*eth0:1*) whit the public ip but I got always the same error,
>>>
>>> so if the configuration of "/etc/network/interfaces" is right I'm
>>> thinking, is possible, I didn't enable in the kernel some modules;
>>>
>>> but if the unload modules, I didn't know witch one I must load for make
>>> the alias working.
>>>     
>>
>> No additional module should be needed to load for using virtual  
>> interfaces. It must be a very an error in the config file we are both 
>> failing to see :-)
>>
>> Just try with a simpler file, something like this:
>>
>> 5.4.3. The virtual interface
>> http://www.debian.org/doc/manuals/debian-reference/ch05.en.html#_the_virtual_interface
>>
>> And see what happens.
>>
>> Greetings,
>>
>>   
> yes, is about metric the problem, and I think must configure the virtual  
> interface like is a normal hardware..
>
> now I have configure like this
>
> #eth0 public ip
> allow-hotplug
> auto eth0
> iface eth0 inet static
>        address 195.137.146.82
>        netmask 255.255.255.248
>        network 195.137.146.80
>        broadcast 195.137.146.87

If you defines an address and a netmask, providing the network address
and the broadcast address is redundant. You can remove those lines.

>        gateway 195.137.146.81

So this interface is the default gateway

> metric 0
> #eth0:1 local ethernet
> allow-hotplug
> auto eth0:1
> iface eth0:1 inet static
>        address 192.168.0.50
>        netmask 255.255.255.0
>        network 192.168.0.0
>        broadcast 192.168.0.255
>        gateway 192.168.0.254

No, wait. This is the default gateway!

>        dns-nameserver 192.168.0.1
> metric 1

-- 
Tzafrir Cohen         | tzafrir@jabber.org | VIM is
http://tzafrir.org.il |                    | a Mutt's
tzafrir@cohens.org.il |                    |  best
ICQ# 16849754         |                    | friend


Reply to: