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

Check for netplan, use it to detect static ips if possible #7227

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

karcaw
Copy link

@karcaw karcaw commented Aug 4, 2022

The PR is to fix issue #7226

The modification include

add check for netplan, and use it to check for static ips

@karcaw
Copy link
Author

karcaw commented Aug 29, 2022

@karcaw Are you running on Ubuntu 20? When I try this on my Ubuntu 18, I get:

root@c910f04x12v05:~# netplan get ethernets.ens3.dhcp4
usage: /usr/sbin/netplan  [-h] [--debug]  ...
/usr/sbin/netplan : error: argument : invalid choice: 'get' (choose from 'help', 'apply', 'generate', 'ip', 'try')
root@c910f04x12v05:~#

yes i have been running ubuntu 20.04 and 22.04 for this issue.

@gurevichmark
Copy link
Contributor

Since xCAT still needs to support UB 16, 18, is there a version of this command that would run on all of them ?

@gurevichmark
Copy link
Contributor

@karcaw
Can you show the output you are getting from netplan get command ?
I still get /usr/sbin/netplan : error: argument : invalid choice: 'get', even when running on Ubuntu 20.04

@karcaw
Copy link
Author

karcaw commented Sep 19, 2022

I just get a false or true result:

--> netplan get ethernets.enp0s25.dhcp4 
false

@gurevichmark
Copy link
Contributor

What version of netplan do you have installed ? I have:

root@c910f04x35v07:~# apt list --installed | grep "netplan"
libnetplan0/now 0.99-0ubuntu3~20.04.2 amd64 [installed,local]
netplan.io/now 0.99-0ubuntu3~20.04.2 amd64 [installed,local]
root@c910f04x35v07:~#

@karcaw
Copy link
Author

karcaw commented Sep 20, 2022 via email

@khm
Copy link
Member

khm commented Feb 17, 2023

@gurevichmark What needs to happen to move this merge request forward?

@gurevichmark
Copy link
Contributor

gurevichmark commented Feb 17, 2023

Need a set of flags or something, so that netplan get works on UB16, UB18 and UB20.
Currently I get /usr/sbin/netplan : error: argument : invalid choice: 'get', when running on those versions of OS.
Seems like netplan get only works on UB22.

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Evan J. Felix seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

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

Successfully merging this pull request may close these issues.

4 participants