Re: How to configure a DHCP + (2nd) Static address (eg on eth0+eth0:0)?
- From: Derek Atkins <warlord MIT EDU>
- To: Andrei Borzenkov <arvidjaar gmail com>
- Cc: networkmanager-list gnome org
- Subject: Re: How to configure a DHCP + (2nd) Static address (eg on eth0+eth0:0)?
- Date: Wed, 30 Sep 2015 10:15:07 -0400
Andrei,
Andrei Borzenkov <arvidjaar gmail com> writes:
29.09.2015 20:54, Dan Williams пишет:
Basically I want to automate NM doing, effectively:
ifconfig eth0:0 192.168.x.y
Don't do this with interface aliases; the kernel is perfectly capable of
using more than one address on the same interface. Simply do:
ip addr add 192.168.x.y/24 dev eth0
and magically you'll have two.
This makes addresses invisible in ifconfig output and that may confuse
legacy software (I know about at least one such case). Adding "label
xxx" will emulate legacy aliases enough to make them appear as
"normal" interface.
Could you explain more detail on how to add "label xxx" to the nmcli
command (which you inconveniently cut out of your reply, so I've
included it below)? I cannot find any reference to "label" in the nmcli
documentation.
nmcli con mod "Wired connection 1" +ipv4.addresses "192.168.x.y/24"
Thanks,
-derek
--
Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
Member, MIT Student Information Processing Board (SIPB)
URL: http://web.mit.edu/warlord/ PP-ASEL-IA N1NWH
warlord MIT EDU PGP key available
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]