Skip to content
This repository has been archived by the owner on Mar 24, 2024. It is now read-only.

libgcc_s.so.1 must be installed for pthread_cancel to work #10

Open
satter opened this issue Sep 14, 2020 · 3 comments
Open

libgcc_s.so.1 must be installed for pthread_cancel to work #10

satter opened this issue Sep 14, 2020 · 3 comments
Labels
bug Something isn't working need more info

Comments

@satter
Copy link

satter commented Sep 14, 2020

Hello,

I'm trying to back up my icloud photos to Ubuntu 18.04 system.

After running for 1-2 minutes gimme-iphotos crashes with the same error:

...
DEBUG:app:Downloading 'IMG_9845.HEIC' to '/srv/backup/icloud/photos/IMG_9845.HEIC.a4b6gyx1'
DEBUG:app:Downloading 'IMG_9844.HEIC' to '/srv/backup/icloud/photos/IMG_9844.HEIC.c3uzjdos'
DEBUG:app:Downloading 'IMG_9843.HEIC' to '/srv/backup/icloud/photos/IMG_9843.HEIC.62yqt8nf'
libgcc_s.so.1 must be installed for pthread_cancel to work
Aborted (core dumped)

This library is installed:

/lib/x86_64-linux-gnu/libgcc_s.so.1: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=679f3ae11120ec7c483bc9295345d836f5c104f7, stripped

Program is installed from pip3:

$ pip3 list | grep gimme
gimme-iphotos (1.0.6)
$ python3 --version
Python 3.6.9

Is this a 32/64bit issue?
Should I install libgcc 32bit?

@Zebradil
Copy link
Owner

I'll check that later today. So far I tested it in python:3.6.9-buster docker container. There was no libgcc error, but it downloaded empty files, so apart from your particular issue there is something related to the python version. While developing I was using python 3.8.

Meanwhile, as a workaround you can use gimme-iphotos via docker, there are instructions in the readme. If something is not clear, don't hesitate to rise a question.

@satter
Copy link
Author

satter commented Sep 14, 2020

I do not have system where I can run docker at the moment

I've used strace to get more info:

epoll_create1(EPOLL_CLOEXEC)            = -1 EMFILE (Too many open files)

Looks like this crash is related to max open files limit, now running fine with ulimit -n 20000
I have ~20k photos in icloud, running with ulimit -n 10000 was unsuccessful

Here is backtrace collected from core dump:

Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/usr/bin/python3 /usr/local/bin/gimme-iphotos -d /srv/backup/icloud/photos/ -u'.
Program terminated with signal SIGABRT, Aborted.
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
51	../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
[Current thread is 1 (Thread 0x7f681cff9700 (LWP 16039))]
(gdb) set substitute-path /build/glibc-2ORdQG/glibc-2.27/signal/ /opt/src/glibc-2.27/
(gdb) bt
#0  0x00007f687a88cf47 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
#1  0x00007f687a88e8b1 in __GI_abort () at abort.c:79
#2  0x00007f687a8d7655 in __libc_message (action=action@entry=(do_abort | do_backtrace), fmt=fmt@entry=0x7f687aa049f6 "%s", fmt=0x7f687aa049f6 "%s", action=(do_abort | do_backtrace))
    at ../sysdeps/posix/libc_fatal.c:181
#3  0x00007f687a8d799a in __GI___libc_fatal (message=message@entry=0x7f687a643c38 "libgcc_s.so.1 must be installed for pthread_cancel to work\n") at ../sysdeps/posix/libc_fatal.c:191
#4  0x00007f687a641edf in pthread_cancel_init () at ../sysdeps/nptl/unwind-forcedunwind.c:64
#5  0x00007f687a641fe4 in _Unwind_ForcedUnwind (exc=0x7f681cff9d70, stop=stop@entry=0x7f687a63fd90 <unwind_stop>, stop_argument=0x7f681cff8f10) at ../sysdeps/nptl/unwind-forcedunwind.c:126
#6  0x00007f687a63ff20 in __GI___pthread_unwind (buf=<optimized out>) at unwind.c:121
#7  0x00007f687a637ae5 in __do_cancel () at pthreadP.h:297
#8  0x00007f687a637ae5 in __pthread_exit (value=<optimized out>) at pthread_exit.c:28
#9  0x00007f687a97e6b4 in __pthread_exit (retval=<optimized out>) at forward.c:173
#10 0x0000000000631bb5 in  ()
#11 0x00000000005e1463 in  ()
#12 0x0000000000631af4 in  ()
#13 0x00007f687a6366db in start_thread (arg=0x7f681cff9700) at pthread_create.c:463
#14 0x00007f687a96fa3f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95

@satter
Copy link
Author

satter commented Sep 14, 2020

I do not know if it is related to this issue or not, but gimme-iphotos has memory issues.

It is consuming all available memory until OOM kicks in:

image

@Zebradil Zebradil added bug Something isn't working need more info labels Nov 13, 2020
@Zebradil Zebradil self-assigned this Nov 13, 2020
@Zebradil Zebradil removed their assignment Nov 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working need more info
Projects
None yet
Development

No branches or pull requests

2 participants