Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Providing network config #1173

Closed
flaw opened this issue Jul 22, 2021 · 2 comments
Closed

Providing network config #1173

flaw opened this issue Jul 22, 2021 · 2 comments

Comments

@flaw
Copy link

flaw commented Jul 22, 2021

I noticed that you by default disable the network configuration support in cloud-init.

I tried to use a post-install script to remove the 99-disable-network-config.cfg which did something, but not what I wanted it to do. I can see now in cloud-init logs that it is indeed trying to configure the network now as the meta-data instructs but that doesn't seem to result in the system actually having any configuration under /etc/systemd/network.

From this I'm assuming there is some other mechanism I should be using to provide the network configuration to Mariner? Could you point me in the right direction?

@universal4
Copy link

I am not sure what others may do, but I installed it as a vm, and network configured with dhcp.
Ifconfig worked to set an ip temporary, but it went back to default dhcp upon reboot.

After it was set up, I created 2 new config files for the public and private cards and it works fine that way.
In the config files I just named the nic in the match section (eth0 or eth1)
Then in network section, the normal address and gateway and dns lines, for the private only an address and netmask line was needed
The config files need to be named lower numbers then the 99, but once I verified it worked, I got rid of the 99 one.

@ddstreetmicrosoft
Copy link
Contributor

in mariner 3 (azure linux 3), cloud-init default network configuration is restored. for mariner 2, when running in azure, the cloud-init datasource should provide the network configuration details, and when running outside a cloud environment, you can either use the 99-dhcp-en.network file (which enables DHCP for all interfaces that start with the letter 'e'), or if that doesn't work for you then you will need to create your own systemd-networkd configuration file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants