brunoenten / pgadmin4-snap

Snap for the pgadmin4 postgres management tool
Other
0 stars 0 forks source link

libpxbackend-1.0.so: cannot open shared object file #1

Open larskanis opened 1 month ago

larskanis commented 1 month ago

I installed pgadmin4 with

$ sudo snap install pgadmin4
pgadmin4 8.10 aus Bruno Enten (brunoenten) installiert

Then starting the app through the program icon works successfully. :+1:

But running the app in the command line fails like so:

$ pgadmin4
Gtk-Message: 14:11:22.708: Not loading module "atk-bridge": The functionality is provided by GTK natively. Please try to not load it.
libpxbackend-1.0.so: cannot open shared object file: No such file or directory
Failed to load module: /home/kanis/snap/pgadmin4/common/.cache/gio-modules/libgiolibproxy.so

The GUI splash screen appears saying "Waiting for pgAdmin 4 to start...", then it takes 3 minutes and the following error window appears:

The pgAdmin 4 server could not be contacted:

pgAdmin Runtime Environment
--------------------------------------------------------
Python Path: "/snap/pgadmin4/5/usr/pgadmin4/venv/bin/python3"
Runtime Config File: "/home/kanis/snap/pgadmin4/5/.config/pgadmin4/config.json"
Webapp Path: "/snap/pgadmin4/5/usr/pgadmin4/web/pgAdmin4.py"
pgAdmin Command: "/snap/pgadmin4/5/usr/pgadmin4/venv/bin/python3 -s /snap/pgadmin4/5/usr/pgadmin4/web/pgAdmin4.py"
Environment: 
  - SHELL: /bin/bash
  - SESSION_MANAGER: local/c1385lx:@/tmp/.ICE-unix/4406,unix/c1385lx:/tmp/.ICE-unix/4406
  - __EGL_EXTERNAL_PLATFORM_CONFIG_DIRS: /snap/pgadmin4/5/gpu-2404/usr/share/egl/egl_external_platform.d
  - QT_ACCESSIBILITY: 1
  - __EGL_VENDOR_LIBRARY_DIRS: /snap/pgadmin4/5/gpu-2404/usr/share/glvnd/egl_vendor.d
  - SNAP_REVISION: 5
  - COLORTERM: truecolor
  - XDG_CONFIG_DIRS: /snap/pgadmin4/5/gnome-platform/etc/xdg:/etc/xdg/xdg-ubuntu:/etc/xdg
  - NVM_INC: /home/kanis/.nvm/versions/node/v20.14.0/include/node
  - XDG_MENU_PREFIX: gnome-
  - no_proxy: localhost,127.0.0.0/8,::1
  - GNOME_DESKTOP_SESSION_ID: this-is-deprecated
  - CLUTTER_BACKEND: wayland
  - rvm_prefix: /home/kanis
  - SNAP_REAL_HOME: /home/kanis
  - VK_LAYER_PATH: /snap/pgadmin4/5/gpu-2404/usr/share/vulkan/implicit_layer.d/:/snap/pgadmin4/5/gpu-2404/usr/share/vulkan/explicit_layer.d/
  - SNAP_USER_COMMON: /home/kanis/snap/pgadmin4/common
  - FONTCONFIG_PATH: /snap/pgadmin4/5/gnome-platform/etc/fonts
  - GNOME_SHELL_SESSION_MODE: ubuntu
  - SSH_AUTH_SOCK: /run/user/1126801433/keyring/ssh
  - XDG_DATA_HOME: /home/kanis/snap/pgadmin4/5/.local/share
  - GNOTIFICATION_BACKEND: freedesktop
  - PIPEWIRE_MODULE_DIR: /snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/pipewire-0.3
  - XDG_CONFIG_HOME: /home/kanis/snap/pgadmin4/5/.config
  - XCURSOR_PATH: /snap/pgadmin4/5/data-dir/icons:/snap/pgadmin4/5/gnome-platform/usr/share/icons
  - MEMORY_PRESSURE_WRITE: c29tZSAyMDAwMDAgMjAwMDAwMAA=
  - SNAP_INSTANCE_KEY: 
  - MY_RUBY_HOME: /home/kanis/.rvm/rubies/ruby-3.3.3
  - XMODIFIERS: @im=ibus
  - DESKTOP_SESSION: ubuntu
  - GDK_PIXBUF_MODULE_FILE: /home/kanis/snap/pgadmin4/common/.cache/gdk-pixbuf-loaders.cache
  - GCONV_PATH: /snap/pgadmin4/5/gpu-2404/usr/lib/i386-linux-gnu/gconv
  - GTK_MODULES: gail:atk-bridge
  - RUBY_VERSION: ruby-3.3.3
  - SNAP_EUID: 1126801433
  - KRB5CCNAME: FILE:/home/kanis/krb5cc
  - PWD: /home/kanis
  - LOGNAME: kanis
  - XDG_SESSION_DESKTOP: ubuntu
  - XDG_SESSION_TYPE: wayland
  - rvm_version: 1.29.12-next (master)
  - rvm_pretty_print_flag: auto
  - SYSTEMD_EXEC_PID: 4450
  - SPA_PLUGIN_DIR: /snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/spa-0.2
  - XAUTHORITY: /run/user/1126801433/.mutter-Xwaylandauth.X9SRQ2
  - TEMPDIR: /tmp
  - ftp_proxy: http://192.168.253.230:4712
  - SNAP_CONTEXT: Yj-vxctu9dObmC9A0oEgpP-SanfPHjvPObt6x9Tx2151LP0iBril
  - GST_PLUGIN_SCANNER: /snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/gstreamer1.0/gstreamer-1.0/gst-plugin-scanner
  - LD_PRELOAD: :/snap/pgadmin4/5/gnome-platform/$LIB/bindtextdomain.so
  - GI_TYPELIB_PATH: /snap/pgadmin4/5/gnome-platform/usr/lib/girepository-1.0:/snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/girepository-1.0
  - HOME: /home/kanis/snap/pgadmin4/5
  - USERNAME: kanis
  - IM_CONFIG_PHASE: 1
  - LANG: de_DE.UTF-8
  - LS_COLORS: rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=00:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.avif=01;35:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:*~=00;90:*#=00;90:*.bak=00;90:*.crdownload=00;90:*.dpkg-dist=00;90:*.dpkg-new=00;90:*.dpkg-old=00;90:*.dpkg-tmp=00;90:*.old=00;90:*.orig=00;90:*.part=00;90:*.rej=00;90:*.rpmnew=00;90:*.rpmorig=00;90:*.rpmsave=00;90:*.swp=00;90:*.tmp=00;90:*.ucf-dist=00;90:*.ucf-new=00;90:*.ucf-old=00;90:
  - XDG_CURRENT_DESKTOP: Unity
  - MEMORY_PRESSURE_WATCH: /sys/fs/cgroup/user.slice/user-1126801433.slice/user@1126801433.service/session.slice/org.gnome.Shell@wayland.service/memory.pressure
  - VTE_VERSION: 7600
  - WAYLAND_DISPLAY: wayland-0
  - SNAP_ARCH: amd64
  - SNAP_INSTANCE_NAME: pgadmin4
  - SNAP_USER_DATA: /home/kanis/snap/pgadmin4/5
  - TMPDIR: /tmp
  - GNOME_TERMINAL_SCREEN: /org/gnome/Terminal/screen/4e314d75_8ee8_4994_8fee_18424e6e8398
  - https_proxy: http://192.168.253.230:4712
  - SNAP_DESKTOP_RUNTIME: /snap/pgadmin4/5/gnome-platform
  - SNAP_LAUNCHER_ARCH_TRIPLET: x86_64-linux-gnu
  - rvm_recommended_ruby: rvm install ruby-3.3.0
  - SNAP_REEXEC: 
  - SNAP_UID: 1126801433
  - PIPEWIRE_CONFIG_DIR: /snap/pgadmin4/5/gnome-platform/usr/share/pipewire
  - QT_QPA_PLATFORM: wayland-egl
  - XDG_CACHE_HOME: /home/kanis/snap/pgadmin4/common/.cache
  - NVM_DIR: /home/kanis/.nvm
  - GNOME_SETUP_DISPLAY: :1
  - rvm_bin_path: /home/kanis/.rvm/bin
  - GEM_PATH: /home/kanis/.rvm/gems/ruby-3.3.3:/home/kanis/.rvm/gems/ruby-3.3.3@global
  - GEM_HOME: /home/kanis/.rvm/gems/ruby-3.3.3
  - LESSCLOSE: /usr/bin/lesspipe %s %s
  - XDG_SESSION_CLASS: user
  - LIBGWEATHER_LOCATIONS_PATH: /snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/libgweather-4/Locations.bin
  - PYTHONPATH: /snap/pgadmin4/5/gnome-platform/usr/lib/python3/dist-packages
  - TERM: xterm-256color
  - GTK_PATH: /snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/gtk-2.0:/snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/gtk-3.0:/snap/pgadmin4/5/gnome-platform/usr/lib/gtk-3.0:/snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/gtk-4.0
  - XLOCALEDIR: /snap/pgadmin4/5/gpu-2404/usr/share/X11/locale
  - LIBTHAI_DICTDIR: /snap/pgadmin4/5/gnome-platform/usr/share/libthai/
  - LESSOPEN: | /usr/bin/lesspipe %s
  - USER: kanis
  - NO_PROXY: localhost,127.0.0.0/8,::1
  - SNAP: /snap/pgadmin4/5
  - GNOME_TERMINAL_SERVICE: :1.124
  - SNAP_COMMON: /var/snap/pgadmin4/common
  - SNAP_VERSION: 8.10
  - DISPLAY: :0
  - SHLVL: 1
  - GDK_PIXBUF_MODULEDIR: /snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/gdk-pixbuf-2.0/2.10.0/loaders
  - NVM_CD_FLAGS: 
  - LOCPATH: /snap/pgadmin4/5/gnome-platform/usr/lib/locale
  - SNAP_LIBRARY_PATH: /var/lib/snapd/lib/gl:/var/lib/snapd/lib/gl32:/var/lib/snapd/void
  - GSM_SKIP_SSH_AGENT_WORKAROUND: true
  - SNAP_COOKIE: Yj-vxctu9dObmC9A0oEgpP-SanfPHjvPObt6x9Tx2151LP0iBril
  - HTTPS_PROXY: http://ccproxy:4712/
  - HTTP_PROXY: http://ccproxy:4712/
  - QT_IM_MODULE: ibus
  - LIBGL_DRIVERS_PATH: /snap/pgadmin4/5/gpu-2404/usr/lib/x86_64-linux-gnu/dri/:/snap/pgadmin4/5/gpu-2404/usr/lib/i386-linux-gnu/dri/
  - http_proxy: http://192.168.253.230:4712
  - SNAP_DATA: /var/snap/pgadmin4/5
  - GST_PLUGIN_PATH: /snap/pgadmin4/5/usr/lib/x86_64-linux-gnu/gstreamer-1.0
  - LD_LIBRARY_PATH: /var/lib/snapd/lib/gl:/var/lib/snapd/lib/gl32:/var/lib/snapd/void:/snap/pgadmin4/5/usr/lib:/snap/pgadmin4/5/usr/lib/x86_64-linux-gnu:/snap/pgadmin4/5/gpu-2404/usr/lib/x86_64-linux-gnu:/snap/pgadmin4/5/gpu-2404/usr/lib/x86_64-linux-gnu/vdpau:/snap/pgadmin4/5/gpu-2404/usr/lib/i386-linux-gnu:/snap/pgadmin4/5/gpu-2404/usr/lib/i386-linux-gnu/vdpau:/snap/pgadmin4/5/gnome-platform/lib/x86_64-linux-gnu:/snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu:/snap/pgadmin4/5/gnome-platform/usr/lib:/snap/pgadmin4/5/gnome-platform/lib:/snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/libunity:/snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/pulseaudio
  - XDG_RUNTIME_DIR: /run/user/1126801433/snap.pgadmin4
  - DEBUGINFOD_URLS: https://debuginfod.ubuntu.com 
  - LIBVA_DRIVERS_PATH: /snap/pgadmin4/5/gpu-2404/usr/lib/x86_64-linux-gnu/dri/:/snap/pgadmin4/5/gpu-2404/usr/lib/i386-linux-gnu/dri/
  - GST_PLUGIN_SYSTEM_PATH: /snap/pgadmin4/5/gnome-platform/usr/lib/x86_64-linux-gnu/gstreamer-1.0
  - MAKE: make -j12
  - FONTCONFIG_FILE: /snap/pgadmin4/5/gnome-platform/etc/fonts/fonts.conf
  - SNAP_NAME: pgadmin4
  - MAVEN_OPTS: -Dhttp.proxyHost=ccproxy -Dhttp.proxyPort=4712 -Dhttps.proxyHost=ccproxy -Dhttps.proxyPort=4712
  - XDG_DATA_DIRS: /home/kanis/snap/pgadmin4/5/.local/share:/home/kanis/snap/pgadmin4/5:/snap/pgadmin4/5/data-dir:/snap/pgadmin4/5/usr/share:/snap/pgadmin4/5/gnome-platform/usr/share:/usr/share/ubuntu:/usr/share/gnome:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop:/snap/pgadmin4/5/gpu-2404/usr/share
  - GDK_BACKEND: x11
  - PATH: /snap/pgadmin4/5/usr/sbin:/snap/pgadmin4/5/usr/bin:/snap/pgadmin4/5/sbin:/snap/pgadmin4/5/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/pgadmin4/5/gnome-platform/usr/bin
  - GTK_USE_PORTAL: 1
  - GDMSESSION: ubuntu
  - GTK_IM_MODULE_FILE: /home/kanis/snap/pgadmin4/common/.cache/immodules/immodules.cache
  - DBUS_SESSION_BUS_ADDRESS: unix:path=/run/user/1126801433/bus
  - NVM_BIN: /home/kanis/.nvm/versions/node/v20.14.0/bin
  - IRBRC: /home/kanis/.rvm/rubies/ruby-3.3.3/.irbrc
  - GIO_MODULE_DIR: /home/kanis/snap/pgadmin4/common/.cache/gio-modules
  - PULSE_SERVER: unix:/run/user/1126801433/snap.pgadmin4/../pulse/native
  - XKB_CONFIG_ROOT: /snap/pgadmin4/5/gnome-platform/usr/share/X11/xkb
  - rvm_path: /home/kanis/.rvm
  - OLDPWD: /home/kanis/comcard/Produktionsverwaltung/prodverwaltung2
  - CHROME_DESKTOP: pgadmin4.desktop
  - ORIGINAL_XDG_CURRENT_DESKTOP: ubuntu:GNOME
  - ELECTRON_ENABLE_SECURITY_WARNINGS: false
  - PGADMIN_INT_PORT: 41443
  - PGADMIN_INT_KEY: b36f822f-42e3-485c-aad8-81a9d3f0e665
brunoenten commented 1 month ago

That's very strange. Launching it using the icon or command line shouldn't make a difference.

Can you consistently reproduce this issue?

larskanis commented 1 month ago

I did a bit more debugging and tried to suppress various environment variables to be passed to the pgadmin4 process. That way I found that the http_proxy setting is breaking the pgamin4 to launch.

A workaround is to start the app with env command like so:

env -u HTTP_PROXY -u http_proxy   pgadmin4

Then the app starts successfully. But it shouldn't break due to a proxy setting.

I have the following proxy variables set:

$ env|sort|grep -i proxy
ftp_proxy=http://192.168.253.230:4712
http_proxy=http://192.168.253.230:4712
HTTP_PROXY=http://192.168.253.230:4712/
https_proxy=http://192.168.253.230:4712
HTTPS_PROXY=http://192.168.253.230:4712/
no_proxy=localhost,127.0.0.0/8,::1
NO_PROXY=localhost,127.0.0.0/8,::1

The following message still appears, even when it successfully starts. So it obviously isn't related to the startup issue:

libpxbackend-1.0.so: cannot open shared object file: No such file or directory