Am Thursday 04 October 2012 22:29:31 schrieben Sie:
> On Thu, Oct 04, 2012 at 10:17:25PM +0200, Rainer Stratmann wrote:
> > >  DHCP Client? or Server?
> >
> > Client
> > Isn't it possible to make it easier?
> > Is it possible to let /etc/network/interfaces untouched?
>
> Why don't you want to touch it? This is the file meant to be touched for
> network configuration.

Because I am searching for the most easy and most flexible way for what I 
need.
If I want to change the static ipadress in the above mentioned example then I 
have to change the file (remountrw, change ipadress in file, remountro, and 
so on).
Isn't it possible to supress the execution of /sbin/dhclient (or a script) at 
boot time and execute it later from the application if required?
If there is no dhclient program then I am able to set the ipadress manually 
with ifconfig without changing config files if I am right. This works already 
with my application. Then I can use this part of the software in the future 
also.

> > >  sudo cp -pi /etc/network/interfaces /etc/network/interfaces.dhcp
> > >  sudo cp -pi /etc/network/interfaces /etc/network/interfaces.static1
>
> Well, not the intended way, I'd say.
> You can do:
> ifup -i /etc/network/interfaces.dhcp eth0
> ifup -i /etc/network/interfaces.static1 eth0

> Alternatively you can name the interfaces, something like (typed by
> heart):
> iface static inet static
>      address 10.2.16.6
>      netmask 255.255.255.252
>      broadcast 10.2.16.7
>      gateway 10.2.16.5
>
> iface dhcp inet dhcp
>
> and then: ifup eth0=static or ifup eth0=dhcp
>
> Then again there are packages like 'guessnet' that select an appropriate
> interface configuration suitable for the network you are in.
>
> Regards,
>       Adrian



_______________________________________________
Voyage-linux mailing list
Voyage-linux@list.voyage.hk
http://list.voyage.hk/mailman/listinfo/voyage-linux

Reply via email to