apt-get does not run in background

Bug #1088023 reported by Dan Kegel
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
apt (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

On Ubuntu 12.04.1, with apt-0.8.16~exp12ubuntu10.6

When I run a script that does
   ...
   sudo apt-get -y install cmake

in the background, apt-get hangs. ps -augx | grep apt shows

root 20603 0.9 0.4 38000 29044 pts/1 T 10:14 0:01 apt-get -y install cmake

Attaching with gdb and doing 'bt' says:

#0 0xb775b1b2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2
#1 0xb74473c3 in __read_nocancel () at ../sysdeps/unix/syscall-template.S:82
#2 0xb76ef403 in pkgDPkgPM::DoStdin(int) ()
   from /usr/lib/i386-linux-gnu/libapt-pkg.so.4.12
#3 0xb76f809e in pkgDPkgPM::Go(int) ()
   from /usr/lib/i386-linux-gnu/libapt-pkg.so.4.12
#4 0xb767e94a in pkgPackageManager::DoInstallPostFork(int) ()
   from /usr/lib/i386-linux-gnu/libapt-pkg.so.4.12
#5 0xb767e9b0 in pkgPackageManager::DoInstall(int) ()
   from /usr/lib/i386-linux-gnu/libapt-pkg.so.4.12

Googling for DoStdin found that this has an upstream bug report already:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=555632

Workaround is to redirect stdin.

Revision history for this message
Edward Donovan (edward.donovan) wrote :

Hi -

The title says aptitude, but the example is apt-get. Since they're different programs. I guess I'll change the title to apt-get, for clarity.

summary: - aptitude does not run in background
+ apt-get does not run in background
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in apt (Ubuntu):
status: New → Confirmed
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.