Trying to set two static ip in dhcpcd.conf, but second ip is not active.
dhcpcd.conf
interface eth0
static ip_address=192.168.3.99/24
static routers=192.168.3.61
static domain_name_server=192.168.3.61
interface eth0:1
static ip_address=192.168.4.55/24
static routers=192.168.4.50
static domain_name_server=192.168.4.50
ifconfig output:
inet addr:192.168.3.99 Bcast:192.168.3.255 Mask:255.255.255.0
Does anyone faced similar situation.
/etc/network/interfaces
, I leave the file/etc/network/interfaces
untouched to keepdhcpcd
working as intended, while adding a file such as/etc/network/interfaces.d/eth0-mydb
to have the additional IP address configured. – VCD Jun 27 '18 at 14:09/etc/network/interfaces
based. Beyond that your answer is reasonable enough. – goldilocks Jul 06 '23 at 16:56