View previous topic :: View next topic |
Author |
Message |
bastibasti Guru
![Guru Guru](/images/ranks/rank_rect_3.gif)
Joined: 27 Nov 2006 Posts: 590
|
Posted: Sat Jun 16, 2018 6:17 am Post subject: two ip adresses for one interface? |
|
|
Hi,
how can I add a second IP to my br0??
current setup: config_br0="192.168.1.2 netmask 255.255.255.0 brd 192.168.1.255" |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
eccerr0r Watchman
![Watchman Watchman](/images/ranks/rank-G-2-watchman.gif)
Joined: 01 Jul 2004 Posts: 9890 Location: almost Mile High in the USA
|
Posted: Sat Jun 16, 2018 6:35 am Post subject: |
|
|
Something like this now...?
config_eth0="x.y.z.a netmask 255.255.f.g
b.c.d.e netmask 255.255.h.i
j.k.l.m/n
::4/64
" _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
khayyam Watchman
![Watchman Watchman](/images/ranks/rank-G-2-watchman.gif)
![](images/avatars/9397496074fd0189143bb7.png)
Joined: 07 Jun 2012 Posts: 6227 Location: Room 101
|
Posted: Sat Jun 16, 2018 8:39 am Post subject: Re: two ip adresses for one interface? |
|
|
bastibasti wrote: | current setup: config_br0="192.168.1.2 netmask 255.255.255.0 brd 192.168.1.255" |
bastibasti ... you might use CIDR notation:
Code: | config_br0="192.168.1.2/24 192.168.1.3/24" |
best ... khay |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
NeddySeagoon Administrator
![Administrator Administrator](/images/ranks/rank-admin.gif)
![](images/avatars/3946266373f47d606a2db3.jpg)
Joined: 05 Jul 2003 Posts: 54821 Location: 56N 3W
|
Posted: Sat Jun 16, 2018 10:29 am Post subject: |
|
|
bastibasti,
Mix and match works too.
Code: | # make sure to use iproute2
# Our own IPv4 and IPv6 setup
modules="iproute2"
config_eth0="5.9.82.14 netmask 255.255.255.224 brd 5.9.82.31
2a01:4f8:162:c::2/64"
routes_eth0="default via 5.9.82.1
default via fe80::1" |
That's IPv4 and IPv6. The one entry per line is for ease of reading. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|