← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1952575] Re: Ubuntu18.04 instnace is making use of wrong datasource when created with confid_drive=true in openstack

 

[Expired for cloud-init because there has been no activity for 60 days.]

** Changed in: cloud-init
       Status: Incomplete => Expired

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to cloud-init.
https://bugs.launchpad.net/bugs/1952575

Title:
  Ubuntu18.04  instnace is making use of wrong datasource when  created
  with confid_drive=true in openstack

Status in cloud-init:
  Expired

Bug description:
  It is noticed that in the case of ubuntu18.04 instance when created
  with --config-drive true option,  /var/lib/cloud/instance symlink is
  wrongly pointed

  ```
  ubuntu@test1:~$ ls -ltr /var/lib/cloud/
  total 24
  drwxr-xr-x 2 root root 4096 Nov 25 11:35 seed
  drwxr-xr-x 6 root root 4096 Nov 25 11:35 scripts
  drwxr-xr-x 2 root root 4096 Nov 25 11:35 handlers
  lrwxrwxrwx 1 root root   44 Nov 25 11:35 instance -> /var/lib/cloud/instances/iid-datasource-none
  drwxr-xr-x 2 root root 4096 Nov 25 11:35 sem
  drwxr-xr-x 4 root root 4096 Nov 25 11:35 instances
  drwxr-xr-x 2 root root 4096 Nov 25 11:35 data
  ubuntu@test1:~$ 
  ```
  Unlike ubuntu20.04 the cloud-init stages are running multiple times

  ```
  ubuntu@test1:~$ sudo grep 'Cloud-init v. 20.3-2-g371b392c-0ubuntu1~18.04.1 running' -arn /var/log/cloud-init.log
  1:2021-11-25 11:35:29,909 - util.py[DEBUG]: Cloud-init v. 20.3-2-g371b392c-0ubuntu1~18.04.1 running 'init-local' at Thu, 25 Nov 2021 11:35:29 +0000. Up 7.56 seconds.
  203:2021-11-25 11:35:33,046 - util.py[DEBUG]: Cloud-init v. 20.3-2-g371b392c-0ubuntu1~18.04.1 running 'init' at Thu, 25 Nov 2021 11:35:32 +0000. Up 10.69 seconds.
  614:2021-11-25 11:35:37,333 - util.py[DEBUG]: Cloud-init v. 20.3-2-g371b392c-0ubuntu1~18.04.1 running 'modules:config' at Thu, 25 Nov 2021 11:35:37 +0000. Up 14.95 seconds.
  742:2021-11-25 11:35:38,493 - util.py[DEBUG]: Cloud-init v. 20.3-2-g371b392c-0ubuntu1~18.04.1 running 'modules:final' at Thu, 25 Nov 2021 11:35:38 +0000. Up 16.09 seconds.
  813:2021-11-25 11:35:53,319 - util.py[DEBUG]: Cloud-init v. 20.3-2-g371b392c-0ubuntu1~18.04.1 running 'init' at Thu, 25 Nov 2021 11:35:53 +0000. Up 30.97 seconds.
  1194:2021-11-25 11:35:55,169 - util.py[DEBUG]: Cloud-init v. 20.3-2-g371b392c-0ubuntu1~18.04.1 running 'modules:config' at Thu, 25 Nov 2021 11:35:55 +0000. Up 32.80 seconds.
  1310:2021-11-25 11:35:55,855 - util.py[DEBUG]: Cloud-init v. 20.3-2-g371b392c-0ubuntu1~18.04.1 running 'modules:final' at Thu, 25 Nov 2021 11:35:55 +0000. Up 33.49 seconds.
  ubuntu@test1:~$ 
  ```

  During the second run cloud-int is looking for data source with
  NETWORK dependency and the returned object is `DataSourceNone` instead
  of `DataSourceConfigDrive`

  ```
  2021-11-25 11:35:53,338 - main.py[DEBUG]: Execution continuing, no previous run detected that would allow us to stop early.
  2021-11-25 11:35:53,338 - handlers.py[DEBUG]: start: init-network/check-cache: attempting to read from cache [trust]
  2021-11-25 11:35:53,338 - util.py[DEBUG]: Reading from /var/lib/cloud/instance/obj.pkl (quiet=False)
  2021-11-25 11:35:53,338 - stages.py[DEBUG]: no cache found
  2021-11-25 11:35:53,338 - handlers.py[DEBUG]: finish: init-network/check-cache: SUCCESS: no cache found
  2021-11-25 11:35:53,338 - util.py[DEBUG]: Attempting to remove /var/lib/cloud/instance
  2021-11-25 11:35:53,341 - stages.py[DEBUG]: Using distro class <class 'cloudinit.distros.ubuntu.Distro'>
  2021-11-25 11:35:53,341 - __init__.py[DEBUG]: Looking for data source in: ['ConfigDrive', 'None'], via packages ['', 'cloudinit.sources'] that matches dependencies ['FILESYSTEM', 'NETWORK']
  2021-11-25 11:35:53,344 - __init__.py[DEBUG]: Searching for network data source in: ['DataSourceNone']
  2021-11-25 11:35:53,344 - handlers.py[DEBUG]: start: init-network/search-None: searching for network data from DataSourceNone
  2021-11-25 11:35:53,344 - __init__.py[DEBUG]: Seeing if we can get any data from <class 'cloudinit.sources.DataSourceNone.DataSourceNone'>
  ```

To manage notifications about this bug go to:
https://bugs.launchpad.net/cloud-init/+bug/1952575/+subscriptions



References