4GB version of Dell Mini 9 runs out of space with updates

Bug #380784 reported by Fabián Rodríguez
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
The Dell Mini Project
Fix Committed
Undecided
Gary Lasker

Bug Description

When trying to apply updates to a Dell Mini 9 with 4GB disk space, the update process is launched but does not complete.

The system became irresponsive, when booted again remaining updates where proposed, when clicking on the panel icon an error message indicates:

dpkg was interrupted, you must manually run dpkg --configure -a to correct the problem.
drive_cache -write error open() failed, please report

The error message is approximate, as I was assisting the system owner on the phone.

As a workaround, we opened a terminal and issued:
sudo apt-get clean

which cleared up about 200 MB. Then:
sudo dpkg --configure -a

We also had to remove broken packages, using the filter in Synaptic package manager.

Update manager should check for total needed disk space and propose incremental updates or to clean up disk space accordingly.

Changed in dell-mini:
status: New → Confirmed
Revision history for this message
Fabián Rodríguez (magicfab) wrote :

Apparently Dell is still shipping machines with this problem as we're getting support calls about this issue.

Revision history for this message
Gary Lasker (gary-lasker) wrote :
Download full text (3.3 KiB)

I did some investigation into this bug using the current complete set of updates for the Dell Mini. Here are the details of what I found:

I did a test with my 8GB SSD QH (a 4GB machine was not available) where I loaded a fresh Dell Mini factory image and then squeezed the partition down to 4GB. Even before the very first update, the disk at that point was at 78% full with 2.66GB of space used. This is the factory install, right out of the box.

I did the first update, which is a 34.6 MB download. This update includes a redirect to the new repositories which contain a second, much larger, round of updates. Update manager detected the new set of updates and reported a download size of 413.4 MB. The updates were able to download, and after the install completed and the machine was restarted, the disk stood at 99% full. A check of the apt cache in /var/cache/apt/archives revealed that all 460MB of update packages were still there.

The good news is that the updates all installed without issue, and I was able to restart the machine. the bad news is that there is essentially no wiggle-room for the case where the user has added content (music, videos, etc.)

I discussed the options with Michael Vogt who is the designer and maintainer of update-manager, and it seems there are two immediate changes we can make to address these issues:

First, we can set an option in Synaptic for updates such that the apt cache is cleared after each update. This is done by passing the value "-o Synaptic::ClearCache=true" from inside update manager.

The second part is to backport Michael's free-disk-space check that he has added to update-manager starting with Intrepid. With this fix, the amount of free space is calculated before an upgrade is begun, and if there is not enough space to complete the upgrade it is aborted and a dialog is shown reporting how much additional disk space is needed and prompting the user to clear space before reattempting the upgrade.

Michael Vogt provided a patch for the first part and he also backported his free-disk-space fix from Intrepid to Hardy in a bzr branch. I created a patch from this branch and added this, plus the first patch, to update manager.

With these patches in place I reran the above test. After the first (34MB) update completed, the apt cache was cleared as expected. I then added a couple of large video files (leaving only 300MB free) before attempting to begin the second (430MB) update. As expected, the upgrade in this case was aborted and a the dialog prompted me to clear space. I deleted the video files and tried again. This time the update completed successfully, and after the update was complete the apt cache was again cleared, returning 430MB of free space. The disk usage after the update now stood at about 78%, about the size it was before the update began.

The new package has been checked in with version:

  update-manager 0.87.30netbook0belmont6

Note 1: When we deploy this update, we need to place it in *both* the legacy and the current repositories. This will insure that it will be part of the first, smaller, update and so will be operational for the second, much larger update.
Note 2: Since newer versions ...

Read more...

Revision history for this message
Gary Lasker (gary-lasker) wrote :

In summary, the fix that has been checked in prevents the failure mode described in this bug by detecting the low-disk space condition and showing a dialog before updating (this is a fix backported from Karmic update-manager). It also clears out the apt cache after an update so that the disk space used during the update process is returned to the user once the update is complete.

Changed in dell-mini:
assignee: nobody → Gary Lasker (gary-lasker)
status: Confirmed → Fix Committed
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.