Can't set static IP to Fedora 27 (or 26) lxc container

Bogdan Dumitru

Active Member
May 6, 2018
5
1
43
42
Hello,

I've been struggling with this for a few hours still.
Steps:
1. Install Proxmox from latest iso
2. pveam update && apt update && apt full-upgrade
3. Download fedora 27 container template
4. Create new CT with fixed ip (ex: 10.10.0.18/24)
5. Start container. The container has a DHCP address.
6. If I install NetworkManager in container it will get the fixed ip set by proxmox but only after I do a ifdown eth0 && ifup eth0 in the container. Before that it will have a DHCP address.
I've checked the /etc/sysconfig/network-scripts/ifcfg-eth0 file and looks good.
Help. I need latest FreeIPA (the one in CentOS 7 has a bug that I _need_ to avoid) and it will only work on fedora properly.
 
I'm giving up for now using LXC because I can't properly set static IP to fedora 27. I'll use kvm VM.
Interested in a response so I can come back to lxc as it is so much lighter.
 
Default Fedora starts systemd-networkd, but Proxmox uses the former network scripts to set up static IP.
Try:
Code:
systemctl stop systemd-networkd
systemctl start network
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!