[Bug 506342] Re: apt-get crashed with SIGSEGV in __fprintf_chk()
*** This bug is a duplicate of bug 535509 *** https://bugs.launchpad.net/bugs/535509 I'll mark this bug as a dup of bug 535509 as we already have a branch attached there. ** This bug has been marked a duplicate of bug 535509 apt-get always crash with Segmentation fault (core dumped) if /var/log/apt doesn't exist. -- apt-get crashed with SIGSEGV in __fprintf_chk() https://bugs.launchpad.net/bugs/506342 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 506342] Re: apt-get crashed with SIGSEGV in __fprintf_chk()
Look like 595795 -- apt-get crashed with SIGSEGV in __fprintf_chk() https://bugs.launchpad.net/bugs/506342 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 506342] Re: apt-get crashed with SIGSEGV in __fprintf_chk()
I mount my /var/log on a ramfs (since I run off a 4G thumbdrive), and worked around the problem by creating any necessary directories in rc.local. I've also created in rc.local a link from /var/cache/apt to a /tmp/debs (with /tmp mounted as tmpfs) and create the /archives/partial directory (path). Postgres also needs a directory. This setup puts some of the most active write locations into ram, instead of (slow) flash, which has a limited lifespan. -- apt-get crashed with SIGSEGV in __fprintf_chk() https://bugs.launchpad.net/bugs/506342 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 506342] Re: apt-get crashed with SIGSEGV in __fprintf_chk()
Here is a patch to fix the problem. I've tested it with latest apt bzr branch. After changes, apt-get logs the following lines instead of giving a segmentation fault. E: Directory '/var/log/apt/' missing E: Directory '/var/log/apt/' missing ** Patch added: CloseLog.patch http://launchpadlibrarian.net/48243086/CloseLog.patch -- apt-get crashed with SIGSEGV in __fprintf_chk() https://bugs.launchpad.net/bugs/506342 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 506342] Re: apt-get crashed with SIGSEGV in __fprintf_chk()
I think crash happens because code snippet below (from apt- pkg/deb/dpkgpm.cc:656) does not check if history_out is valid. string history_name = flCombine(_config-FindDir(Dir::Log), _config-Find(Dir::Log::History)); if (!history_name.empty()) { FILE *history_out = fopen(history_name.c_str(),a); fprintf(history_out, End-Date: %s\n, timestr); fclose(history_out); } Problem gets triggered for me because my Dir::Log directory does not exists, due to the fact I've mounted my /var/log to a tmpfs. $apt-config dump ... Dir::Log var/log/apt; Dir::Log::Terminal term.log; Dir::Log::History history.log; ... I can confirm issue has disappeared after I've created directory manually. -- apt-get crashed with SIGSEGV in __fprintf_chk() https://bugs.launchpad.net/bugs/506342 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 506342] Re: apt-get crashed with SIGSEGV in __fprintf_chk()
** Visibility changed to: Public ** Changed in: apt (Ubuntu) Status: New = Confirmed -- apt-get crashed with SIGSEGV in __fprintf_chk() https://bugs.launchpad.net/bugs/506342 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs