netdev_pformat does not show unconfigured devices
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cloud-init |
Fix Released
|
Undecided
|
Unassigned | ||
cloud-init (Ubuntu) |
Fix Released
|
Medium
|
Scott Moser |
Bug Description
The changes in commit 6d48d265a05 made netdevinfo.
showing information about network devices that do not have an address.
see below:
$ git checkout --quiet 6d48d265a05^
$ git rev-parse HEAD
4c573d0e0173d2b
$ python3 -c 'from cloudinit import netinfo; print(netinfo.
+++++++
+------
| Device | Up | Address | Mask | Scope | Hw-Address |
+------
| eth0: | False | . | . | . | 00:16:3e:de:51:a6 |
| lo: | True | 127.0.0.1 | 255.0.0.0 | . | . |
| lo: | True | . | . | d | . |
+------
$ git checkout --quiet master master
error: pathspec 'master' did not match any file(s) known to git.
$ git checkout --quiet master
$ git rev-parse HEAD
4ed164592fe8cb1
$ python3 -c 'from cloudinit import netinfo; print(netinfo.
+++++++
+------
| Device | Up | Address | Mask | Scope | Hw-Address |
+------
| lo | True | 127.0.0.1 | 255.0.0.0 | host | . |
| lo | True | ::1/128 | . | host | . |
+------
ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: cloud-init 18.2-14-
ProcVersionSign
Uname: Linux 4.15.0-13-generic x86_64
ApportVersion: 2.20.9-0ubuntu5
Architecture: amd64
CloudName: LXD
Date: Mon Apr 23 16:39:48 2018
PackageArchitec
ProcEnviron:
TERM=xterm-
PATH=(custom, no user)
LANG=C.UTF-8
SourcePackage: cloud-init
UpgradeStatus: No upgrade log present (probably fresh install)
user_data.txt:
#cloud-config
{}
Related branches
- Server Team CI bot: Approve (continuous-integration)
- Chad Smith: Approve
-
Diff: 183 lines (+107/-11)5 files modifiedcloudinit/netinfo.py (+30/-10)
cloudinit/tests/test_netinfo.py (+46/-1)
tests/data/netinfo/netdev-formatted-output-down (+8/-0)
tests/data/netinfo/new-ifconfig-output-down (+15/-0)
tests/data/netinfo/sample-ipaddrshow-output-down (+8/-0)
Changed in cloud-init (Ubuntu): | |
status: | New → Confirmed |
importance: | Undecided → Low |
importance: | Low → Medium |
assignee: | nobody → Scott Moser (smoser) |
An upstream commit landed for this bug.
To view that commit see the following URL: /git.launchpad. net/cloud- init/commit/ ?id=14cb4924
https:/