[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#509866: dpkg: Output sometimes suddenly switches to CAPS



reassign 509866 apt-get 0.7.19+b1
severity 509866 normal
thanks

On Tuesday 30 December 2008, Guillem Jover wrote:
> You could append ',clone,fork,vfork,execve' to 'trace=ioctl'.

Thanks.

> > On Monday 29 December 2008, Guillem Jover wrote:
> My initial gut feeling was that this could be one of kernel, glibc, the
> terminal emulator or the program invoking dpkg (in this case apt). I
> guess the terminal emulator we can discard, as it happens with
> different ones.

Looks like it's apt-get.

I've not reproduced the error with the extra strace, but I did get an
strace for the invocation corresponding to the one in my previous mail and
it is sufficiently similar to narrow down the problem.

Full strace attached; here are the most relevant bits.

apt-get gets called and gets PID 24406
24406 execve("/usr/bin/apt-get", ["apt-get", "-o", "APT::Status-Fd=4", "-o", "APT::Keep-Fds::=5",
   "-o", "APT::Keep-Fds::=6", "-o", "APT::Install-Recommends=false", "-q", "-y", "--no-remove",
   "install", "initramfs-tools"], ["DEBCONF_READFD=5", "SHELL=/bin/sh", "TERM=bterm", "PERL_BADLANG=0",
   "USER=root", "initrd=initrd.gz", "TERM_TYPE=virtual", "DEBCONF_ADMIN_EMAIL=", "PATH=/sbin:/usr/sbin:/bin:/usr/b"...,
   "vga=normal", "PWD=/", "LANG=en_US.UTF-8", "DEBIAN_PRIORITY=high", "DEBCONF_OLD_FD_BASE=4", "SHLVL=1", "HOME=/",
   "BOOT_IMAGE=linux", "TERM_FRAMEBUFFER=yes", "PB_WAYPOINT_LENGTH=20", "DEBIAN_FRONTEND=passthrough",
   "APT_LISTCHANGES_FRONTEND=none", "LVM_SUPPRESS_FD_WARNINGS=1", "PB_POSITION=117", "DEBCONF_WRITEFD=6",
   "modules=strace-udeb,openssh-clie"..., "DEBCONF_DROP_TRANSLATIONS=1", "MENU=/usr/bin/main-menu",
   "UDPKG_QUIET=y", "_=/usr/bin/debconf-apt-progress", "PERL_DL_NONLAZY=1"]) = 0

apt-get first calls dpkg-preconfigure
24406 clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7ff04a9c7780) = 24411
24411 execve("/bin/sh", ["/bin/sh", "-c", "/usr/sbin/dpkg-preconfigure --ap"...], ["DEBCONF_READFD=5", "SHELL=/bin/sh",
   "TERM=bterm", "PERL_BADLANG=0", "USER=root", "initrd=initrd.gz", "TERM_TYPE=virtual", "DEBCONF_ADMIN_EMAIL=",
   "PATH=/sbin:/usr/sbin:/bin:/usr/b"..., "vga=normal", "PWD=/", "LANG=en_US.UTF-8", "DEBIAN_PRIORITY=high",
   "DEBCONF_OLD_FD_BASE=4", "SHLVL=1", "HOME=/", "BOOT_IMAGE=linux", "TERM_FRAMEBUFFER=yes", "PB_WAYPOINT_LENGTH=20",
   "DEBIAN_FRONTEND=passthrough", "APT_LISTCHANGES_FRONTEND=none", "LVM_SUPPRESS_FD_WARNINGS=1", "PB_POSITION=117",
   "DEBCONF_WRITEFD=6", "modules=strace-udeb,openssh-clie"..., "DEBCONF_DROP_TRANSLATIONS=1", "MENU=/usr/bin/main-menu",
   "UDPKG_QUIET=y", "_=/usr/bin/debconf-apt-progress", "PERL_DL_NONLAZY=1"]) = 0

After it returns from that, here's where oflags gets corrupted; PID is that of apt-get.
24406 ioctl(14, SNDCTL_TMR_TIMEBASE or TCGETS,
   {c_iflags=0x500, c_oflags=0x5, c_cflags=0xbf, c_lflags=0x8a3b, c_line=0,
    c_cc="\x03\x1c\x7f\x15\x04\x00\x01\x00\x11\x13\x1a\x00\x12\x0f\x17\x16\x00\x00\x00"}) = 0
24406 ioctl(14, SNDCTL_TMR_CONTINUE or TCSETSF,
   {c_iflags=0x1, c_oflags=0x7ff0, c_cflags=0, c_lflags=0, c_line=0, c_cc[VMIN]=0, c_cc[VTIME]=0,
    c_cc="\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf0\x7f\x00\x00\x00\x00\x00\x00"}) = 0
24406 ioctl(14, SNDCTL_TMR_TIMEBASE or TCGETS,
   {c_iflags=0x1, c_oflags=0x7ff0, c_cflags=0xb0, c_lflags=0, c_line=0, c_cc[VMIN]=0, c_cc[VTIME]=0,
    c_cc="\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf0\x7f\x00\x00\x00\x00\x00\x00"}) = 0

And immediately after that dpkg is called.
24406 clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7ff04a9c7780) = 24430
24430 ioctl(14, TIOCSCTTY)              = 0
24430 ioctl(0, SNDCTL_TMR_TIMEBASE or TCGETS,
   {c_iflags=0x1, c_oflags=0x7ff0, c_cflags=0xb0, c_lflags=0, c_line=0, c_cc[VMIN]=0, c_cc[VTIME]=0,
    c_cc="\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf0\x7f\x00\x00\x00\x00\x00\x00"}) = 0
24430 execve("/usr/bin/dpkg", ["/usr/bin/dpkg", "--status-fd", "12", "--unpack",
   "--auto-deconfigure", "/var/cache/apt/archives/libvolum"..., "/var/cache/apt/archives/udev_0.1"...,
   "/var/cache/apt/archives/libklibc"..., "/var/cache/apt/archives/klibc-ut"...,
   "/var/cache/apt/archives/initramf"...], ["DEBCONF_READFD=5", "SHELL=/bin/sh", "TERM=bterm", "PERL_BADLANG=0",
   "USER=root", "initrd=initrd.gz", "TERM_TYPE=virtual", "DEBCONF_ADMIN_EMAIL=", "PATH=/sbin:/usr/sbin:/bin:/usr/b"...,
   "vga=normal", "PWD=/", "LANG=en_US.UTF-8", "DEBIAN_PRIORITY=high", "DEBCONF_OLD_FD_BASE=4", "SHLVL=1",
   "HOME=/", "BOOT_IMAGE=linux", "TERM_FRAMEBUFFER=yes", "PB_WAYPOINT_LENGTH=20", "DEBIAN_FRONTEND=passthrough",
   "APT_LISTCHANGES_FRONTEND=none", "LVM_SUPPRESS_FD_WARNINGS=1", "PB_POSITION=117", "DEBCONF_WRITEFD=6",
   "modules=strace-udeb,openssh-clie"..., "DEBCONF_DROP_TRANSLATIONS=1", "MENU=/usr/bin/main-menu", "UDPKG_QUIET=y",
   "_=/usr/bin/debconf-apt-progress", "PERL_DL_NONLAZY=1", "DPKG_NO_TSTP=yes"]) = 0

Without claiming to understand the code, I guess the problem is most likely
to be around line 779 of apt-pkg/deb/dpkgpm.cc.

Attachment: strace.ioctl.24372.gz
Description: GNU Zip compressed data


Reply to: