example of the problem:
$ su
Segmentation fault
$ sudo ls
Segmentation fault
I tried to compile sqlite3 from source earlier. I don't know what libraries it installed. This may be the reason why this is happening.
I tried strace su
and it ends with the following:
...
fstat64(6, {st_mode=S_IFREG|0644, st_size=17964, ...}) = 0
mmap2(NULL, 20788, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 6, 0) = 0xb7295000
mmap2(0xb7299000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 6, 0x3) = 0xb7299000
close(6) = 0
mprotect(0xb7299000, 4096, PROT_READ) = 0
mprotect(0xb72f9000, 4096, PROT_READ) = 0
set_tid_address(0xb758a728) = 11144
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV (core dumped) +++
Segmentation fault (core dumped)
When I try gdb su
and try to run, it gives me Cannot find new threads: generic error
. I looked online for a solution to the problem, encountered this thread, and then tried running LD_PRELOAD=/lib/i386-linux-gnu/libpthread.so.0 gdb su
(as suggested in the thread). When I then tried to run it again, it gave me the same error.
Based on the strace, I think there is some problem with how it's threading, but I have no idea how to fix this. Is there some way to reinstall the basic bash utilities?
Here's more information about my system:
$ uname -a
myhost 3.2.0-37-generic-pae #58-Ubuntu SMP Thu Jan 24 15:51:02 UTC 2013 i686 i686 i386 GNU/Linux
(I'm pretty sure the hardware is 64bit)