Re: [vserver] Automatic gratuitous ARP on startup

From: Daniel Hokka Zakrisson <daniel_at_hozac.com>
Date: Thu 18 Aug 2011 - 10:16:08 BST
Message-ID: <56852.192.168.102.6.1313658968.squirrel@192.168.100.17>

Christian Balzer wrote:
> On Thu, 18 Aug 2011 09:58:57 +0200 Ghislain wrote:
>
>> Le 18/08/2011 07:17, Christian Balzer a écrit :
>> > Hello,
>> >
>> > Would have joined the IRC channel and asked there, but a) it doesn't
>> > let me connect (prolly because I'm hailing from smelly Asia) and b)
>> > despite the log mail archives tend to be the first thing people go
>> > looking for previously asked questions.
>> >
>> > Anyways, I would love to issue a gratuitous ARP (arping) when a vserver
>> > comes up, using the normal vserver-util framework. My hope is to find
>> > something akin to the "up do-stuff" ability of /etc/network/interfaces
>> > control file for ifup/ifdown.
>> > While the CISCO gear does allow the arp cache timeout to be set down to
>> > one second, it actually keeps caching things for at least a minute. It
>> > does however (when told so) honor gratuitous ARP requests.
>> >
>> > Regards,
>> >
>> > Christian
>>
>> does post-start* :
>> http://www.nongnu.org/util-vserver/doc/conf/configuration.html
>>
> [...]
>> post-start*
>> The scriptlet which will be executed after the vserver has been
>> started. Before executing the script, the vserver root directory will be
>> made the working directory.
>
> [...]
>>
>> pre-start*
>> The scriptlet which will be executed after network-interfaces were
>> enabled and the directories mounted, but before the vserver itself has
>> been started. Before executing the script,
>> the vserver root directory will be made the working directory.
> [...]
>> suits your need ?
>>
> Actually pre-start might be better suited.
> I will play with those, but I already can see where this will be less than
> elegant, unless there is an environment variable that holds the name (or
> more precisely the configuration directory) of the vserver that is being
> started at the time.
> Otherwise it will be one script with manually configured IP per guest,
> instead of a generic default one that goes to pick the IP(s) from the
> configuration files.

The name of the guest is the second argument to it. You can also drop it
in .defaults, and have it automatically apply to all of your guests...

> Regards,
>
> Christian
> --
> Christian Balzer Network/Systems Engineer
> chibi@gol.com Global OnLine Japan/Fusion Communications
> http://www.gol.com/
>

-- 
Daniel Hokka Zakrisson
Received on Thu Aug 18 10:16:19 2011
[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Thu 18 Aug 2011 - 10:16:19 BST by hypermail 2.1.8