Skip to content

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

Closed
karcaw wants to merge 1 commit into
xcat2:masterfrom
karcaw:7226-support-netplan-configs
Closed

Check for netplan, use it to detect static ips if possible#7227
karcaw wants to merge 1 commit into
xcat2:masterfrom
karcaw:7226-support-netplan-configs

Conversation

@karcaw

@karcaw karcaw commented Aug 4, 2022

Copy link
Copy Markdown
Contributor

The PR is to fix issue #7226

The modification include

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

@karcaw

karcaw commented Aug 29, 2022

Copy link
Copy Markdown
Contributor Author

@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
Copy Markdown
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
Copy Markdown
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

karcaw commented Sep 19, 2022

Copy link
Copy Markdown
Contributor Author

I just get a false or true result:

--> netplan get ethernets.enp0s25.dhcp4 
false

@gurevichmark

Copy link
Copy Markdown
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

karcaw commented Sep 20, 2022 via email

Copy link
Copy Markdown
Contributor Author

@khm

khm commented Feb 17, 2023

Copy link
Copy Markdown
Member

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

@gurevichmark

gurevichmark commented Feb 17, 2023

Copy link
Copy Markdown
Contributor

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

CLAassistant commented Jul 31, 2024

Copy link
Copy Markdown

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.
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