--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
Title:
cloud-init sometimes fails on dpkg lock due to concurrent apt-
daily.service execution
To manage notifications about this bug go to:
2022 still happens on AWS Ubuntu 20.04.
But in my case, is 100% of the time, not sometimes.
This user-data:
```
#cloud-config
package_update: true
package_upgrade: true
packages:
- awscli
- jq
```
```
sudo cloud-init status
status: error
```
Logs collected and attached.
** Attachment
Since 20.04, apt can wait for a lock.
The apt(8) command automatically waits for a lock for 120 seconds (non-
interactive) or infinitely.
The apt-get(8) command can be configured to wait as well by passing the
-o DPkg::Lock::Timeout=, where
may also be -1 for infinite.
This avoids any races
Not sure if this helps, but we recently added behavior to wait for an
apt lock when doing apt commands. This will be included in our next
release: https://github.com/canonical/cloud-init/pull/1034
If there are still remaining issues, please open a new bug rather than
commenting here. This bug
From cloud-init point of view the solution now implemented make sense:
to run it before the apt-daily-upgrade. However, I wanted to add that
there are other use cases as well such as SSM documents being executed
on instances. These can be executed in batch at any time and may also
require
Ah, thanks, I wasn't aware they're distinct. So would simply adding apt-
daily-upgrade.service to the Before via cloud-init's bootcmd and then
issuing a daemon-reload be a suitable workaround? There's a 30s window
until the upgrade process starts if apt's history.log is to be trusted.
That is
Arguably it should run before apt-daily-upgrade too. apt-daily-upgrade
is the one locking dpkg; apt-daily locks apt lists (and cache)
directory.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
This is not fixed, it just affected me on Ubuntu 20.04.3 LTS, resulting
in the the subsequent server configuration failing completely because
awscli and jq were missing.
Output:
Cloud-init v. 21.3-1-g6803368d-0ubuntu1~20.04.4 running 'modules:config' at
Fri, 12 Nov 2021 11:05:29 +. Up 18.13
** Changed in: apt
Status: Confirmed => Fix Released
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
Title:
cloud-init sometimes fails on dpkg lock due to concurrent apt-
Nothing actionable here for apt, so I'll close this. We should consider
making frontend locking more flexible for scripts using apt, though, so
scripts can hold the lock all the time and drive apt.
** Changed in: apt (Ubuntu)
Status: New => Invalid
--
You received this bug notification
This bug is believed to be fixed in cloud-init in 17.1. If this is still
a problem for you, please make a comment and set the state back to New
Thank you.
** Changed in: cloud-init
Status: Confirmed => Fix Released
--
You received this bug notification because you are a member of Ubuntu
** Changed in: cloud-init (Ubuntu Yakkety)
Status: Fix Committed => Won't Fix
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
Title:
cloud-init sometimes fails on dpkg lock due to
This bug was fixed in the package cloud-init - 0.7.9-153-g16a7302f-
0ubuntu1~17.04.2
---
cloud-init (0.7.9-153-g16a7302f-0ubuntu1~17.04.2) zesty-proposed; urgency=medium
* cherry-pick 5fb49bac: azure: identify platform by well known value
in chassis asset (LP: #1693939)
*
This bug was fixed in the package cloud-init - 0.7.9-153-g16a7302f-
0ubuntu1~16.04.2
---
cloud-init (0.7.9-153-g16a7302f-0ubuntu1~16.04.2) xenial-proposed;
urgency=medium
* debian/patches/ds-identify-behavior-xenial.patch: refresh patch.
* cherry-pick 5fb49bac: azure: identify
** Attachment added: "zesty results"
https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/1693361/+attachment/4905924/+files/1693361-zesty.tar.gz
** Tags removed: verification-needed verification-needed-xenial
verification-needed-yakkety verification-needed-zesty
** Tags added:
$ for rel in xenial yakkety zesty; do lxc-proposed-snapshot --proposed
$rel proposed-$rel --publish || break; done
$ for rel in xenial yakkety zesty; do lxc launch proposed-$rel "--
config=user.user-data=$(cat config.yaml)" test-$rel || break; done
$ sleep 2m
$ for rel in xenial yakkety zesty;
** Attachment added: "yakkety results"
https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/1693361/+attachment/4905923/+files/1693361-yakkety.tar.gz
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
Hello Jim, or anyone else affected,
Accepted cloud-init into yakkety-proposed. The package will build now
and be available at https://launchpad.net/ubuntu/+source/cloud-
init/0.7.9-153-g16a7302f-0ubuntu1~16.10.2 in a few hours, and then in
the -proposed repository.
Please help us by testing this
Hello Jim, or anyone else affected,
Accepted cloud-init into zesty-proposed. The package will build now and
be available at https://launchpad.net/ubuntu/+source/cloud-
init/0.7.9-153-g16a7302f-0ubuntu1~17.04.2 in a few hours, and then in
the -proposed repository.
Please help us by testing this
** Description changed:
=== Begin SRU Template ===
[Impact]
A cloud-config that contains packages to install (see below) or
'package_upgrade' will run 'apt-get update'. That can sometimes fail as a
result of contention with the apt-daily.service that updates that information.
** Description changed:
+ === Begin SRU Template ===
+ [Impact]
+ A cloud-config that contains packages to install (see below) or
+ 'package_upgrade' will run 'apt-get update'. That can sometimes fail as a
+ result of contention with the apt-daily.service that updates that information.
+
+
** Merge proposal linked:
https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/326452
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
Title:
cloud-init sometimes fails on
This bug was fixed in the package cloud-init - 0.7.9-197-gebc9ecbc-
0ubuntu1
---
cloud-init (0.7.9-197-gebc9ecbc-0ubuntu1) artful; urgency=medium
* debian/control: add build dependency python3-jsonschema (LP: #1695318)
* New upstream snapshot.
- Azure: Add network-config,
** Changed in: cloud-init (Ubuntu Artful)
Status: Confirmed => Fix Committed
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
Title:
cloud-init sometimes fails on dpkg lock due to
** Changed in: apt
Status: New => Confirmed
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
Title:
cloud-init sometimes fails on dpkg lock due to concurrent apt-
daily.service
** Changed in: apt
Status: Unknown => New
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
Title:
cloud-init sometimes fails on dpkg lock due to concurrent apt-
daily.service
We eventually want wait locking in apt, but I don't think it really
solves all issues, especially in scripts with multiple apt invocations.
Which is why apt-daily got an additional flock lock for the upcoming
SRUs. (see artful).
Feel free.to wait on the same.lock and probably add some ordering
** Bug watch added: Debian Bug tracker #864681
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=864681
** Also affects: apt via
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=864681
Importance: Unknown
Status: Unknown
--
You received this bug notification because you are a
** Also affects: apt (Ubuntu)
Importance: Undecided
Status: New
** No longer affects: apt (Ubuntu Zesty)
** No longer affects: apt (Ubuntu Yakkety)
** No longer affects: apt (Ubuntu Xenial)
** No longer affects: apt (Ubuntu Artful)
--
You received this bug notification because you
** Merge proposal linked:
https://code.launchpad.net/~smoser/cloud-init/+git/cloud-init/+merge/325513
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
Title:
cloud-init sometimes fails on
** Also affects: cloud-init (Ubuntu Zesty)
Importance: Undecided
Status: New
** Also affects: cloud-init (Ubuntu Yakkety)
Importance: Undecided
Status: New
** Also affects: cloud-init (Ubuntu Artful)
Importance: Undecided
Status: New
** Also affects: cloud-init
** Also affects: cloud-init (Ubuntu)
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1693361
Title:
cloud-init sometimes fails on dpkg lock due to
32 matches
Mail list logo