race condition with locking during update-manager dist-upgrade

Bug #283892 reported by Bogdan Butnaru
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
update-manager (Ubuntu)
Incomplete
Undecided
Unassigned

Bug Description

Binary package hint: update-manager

Hello! I've just noticed something weird:

I have a machine with Ubuntu Hardy on it. Today I tried to upgrade to Intrepid, so I started 'update-manager -d'. It started doing its thing, everything seemed OK.

In a separate terminal I was toying with aptitude, looking for a vnc package. I typed "aptitude install vnc-server"; I realized at the end that it couldn't work because of the update, but I pressed enter anyway to see what'd happen. Surprisingly, the update-manager coughed out an error. As far as I can tell, aptitude managed to take the "update lock" and start its thing, and the update-manager stumbled on it. (In fact, update-manager threw up the error, then continued installing a few things, and then stopped. I ran 'aptitude dist-upgrade' and it seems to continue correctly, but it's still going so I'm not sure everything will be A-OK.)

I know this is not a common situation, but it still should be fixed. I'm not sure if the update-manager can take lock on behalf of whatever apps it's running, so perhaps it should detect lock failures and retry or ask the user what to do.

Revision history for this message
Michael Vogt (mvo) wrote :

Thanks for your bugreport.

Could you please attach the logs in /var/log/dist-upgrade/* ? There is a known race condition in the lock file operation, but it should not be easy to trigger. I have not debugged it in detail, but it basicly its the problem that apt runs dpkg in various runs and when one dpkg exists it gives up the lock and when the next one starts it takes it again. In between there is a lock-less time.

Changed in update-manager:
status: New → Incomplete
Revision history for this message
Bogdan Butnaru (bogdanb) wrote :

Here is everything. Note that I haven't yet restarted the machine after the upgrade:

I started "update-manager -d", and after it broke I used "aptitude dist-upgrade" to continue the upgrade. But I had to leave (it's my work machine and it got late) and I didn't restart it in case something goes wrong during the reboot. This was taken via ssh. I won't get near the machine until Monday.

Changed in update-manager:
status: Incomplete → New
Michael Vogt (mvo)
Changed in update-manager:
milestone: none → later
status: New → Triaged
Revision history for this message
Maarten Bezemer (veger) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. We are sorry that we do not always have the capacity to look at all reported bugs in a timely manner. There have been many changes in Ubuntu since that time you reported the bug and your problem may have been fixed with some of the updates. It would help us a lot if you could test it on a currently supported Ubuntu version. When you test it and it is still an issue, kindly upload the updated logs by running apport-collect 283892 and any other logs that are relevant for this particular issue.

Changed in update-manager (Ubuntu):
status: Triaged → Incomplete
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.