Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Libssl ERROR: No such file or directory error when launching tg #301

Open
aleeessio opened this issue May 1, 2023 · 1 comment
Open

Comments

@aleeessio
Copy link

aleeessio commented May 1, 2023

I think that there's a problem with the versione of libssl. The 1.1 in fact is no longer installed by default, so the script should be updated to the 3.08

root@d33357df4709:~# tg
Traceback (most recent call last):
  File "/usr/local/bin/tg", line 8, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.10/dist-packages/tg/__main__.py", line 60, in main
    tg = Tdlib(
  File "/usr/local/lib/python3.10/dist-packages/telegram/client.py", line 136, in __init__
    self._tdjson = TDJson(library_path=library_path, verbosity=tdlib_verbosity)
  File "/usr/local/lib/python3.10/dist-packages/telegram/tdjson.py", line 27, in __init__
    self._build_client(library_path, verbosity)
  File "/usr/local/lib/python3.10/dist-packages/telegram/tdjson.py", line 34, in _build_client
    self._tdjson = CDLL(library_path)
  File "/usr/lib/python3.10/ctypes/__init__.py", line 374, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: libssl.so.1.1: cannot open shared object file: No such file or directory
find: ‘/root/.cache/tg/files’: No such file or directory

I've also tried do something by installing manually the library:

1. sudo apt update && sudo apt upgrade -y && sudo apt install -y wget
2. wget http://archive.debian.org/debian-archive/debian-security/pool/updates/main/o/openssl/libssl1.1_1.1.0l-1~deb9u6_amd64.deb
3. dpgk -i libssl1.1_1.1.0l-1~deb9u6_amd64.deb

The error is pretty the same, dispite it's shown in a different way. So the tg package requires libssl library at 1.1 version, but I don't know how to install it. As I said above, I've tried manually but the error it's pretty the same

Traceback (most recent call last):
  File "/usr/local/bin/tg", line 8, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.10/dist-packages/tg/__main__.py", line 60, in main
    tg = Tdlib(
  File "/usr/local/lib/python3.10/dist-packages/telegram/client.py", line 136, in __init__
    self._tdjson = TDJson(library_path=library_path, verbosity=tdlib_verbosity)
  File "/usr/local/lib/python3.10/dist-packages/telegram/tdjson.py", line 27, in __init__
    self._build_client(library_path, verbosity)
  File "/usr/local/lib/python3.10/dist-packages/telegram/tdjson.py", line 34, in _build_client
    self._tdjson = CDLL(library_path)
  File "/usr/lib/python3.10/ctypes/__init__.py", line 374, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: /lib/x86_64-linux-gnu/libcrypto.so.1.1: version `OPENSSL_1_1_1' not found (required by /usr/local/lib/python3.10/dist-packages/telegram/lib/linux/libtdjson.so)
find: ‘/root/.cache/tg/files’: No such file or directory
@Bilalharoon
Copy link

Bilalharoon commented Feb 21, 2024

I compiled my own tdlibjson.so using this website then put the path to that as the tdlib_path in the config file. I got an api error but that seemed to fix the libssl issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants