Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 759091 - dev-db/pgadmin4 launch fails with "The application server could not be contacted"
Summary: dev-db/pgadmin4 launch fails with "The application server could not be contac...
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal major (vote)
Assignee: PgSQL Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-12-08 17:40 UTC by Jeff Hubbs
Modified: 2020-12-17 18:15 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
regular user's pgadmin4 log (.pgAdmin4.startup.log,1.34 KB, text/x-log)
2020-12-08 17:40 UTC, Jeff Hubbs
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jeff Hubbs 2020-12-08 17:40:06 UTC
Created attachment 677266 [details]
regular user's pgadmin4 log

Desktop system with KDE successfully emerged dev-db/pgadmin4-4.17-r1 but when launching it from the GUI menu the pgadmin splash screen appears, its status message steps through "Starting pgAdmin4 server..." then "Taking longer than usual..." then "Almost there..." and is eventually replaced by a window saying "Fatal Error / The application server could not be contacted." While this is taking place /usr/bin/pgAdmin4 is taking up near 100% of one thread at a time. ~/.pgadmin/pgadmin4.log exists but is zero bytes. 

I've attached ~.pgAdmin4.startup.log.

# emerge --info dev-db/pgadmin4
Portage 3.0.9 (python 3.8.6-final-0, default/linux/amd64/17.1/desktop/plasma, gcc-9.3.0, glibc-2.32-r2, 5.4.80-gentoo-r1 x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-5.4.80-gentoo-r1-x86_64-Intel-R-_Core-TM-_i5_CPU_650_@_3.20GHz-with-glibc2.2.5
KiB Mem:     8082916 total,   4470864 free
KiB Swap:   16777212 total,  16777212 free
Timestamp of repository gentoo: Tue, 08 Dec 2020 08:00:01 +0000
Head commit of repository gentoo: a78fa865809db64d25774d96b36830cd0583c106
sh bash 5.0_p18
ld GNU ld (Gentoo 2.34 p6) 2.34.0
distcc 3.3.3 x86_64-pc-linux-gnu [disabled]
app-shells/bash:          5.0_p18::gentoo
dev-java/java-config:     2.3.1::gentoo
dev-lang/perl:            5.30.3::gentoo
dev-lang/python:          2.7.18-r4::gentoo, 3.7.9::gentoo, 3.8.6::gentoo, 3.9.0::gentoo
dev-util/cmake:           3.17.4-r1::gentoo
sys-apps/baselayout:      2.7::gentoo
sys-apps/openrc:          0.42.1::gentoo
sys-apps/sandbox:         2.20::gentoo
sys-devel/autoconf:       2.13-r1::gentoo, 2.69-r5::gentoo
sys-devel/automake:       1.16.2-r1::gentoo
sys-devel/binutils:       2.34-r2::gentoo
sys-devel/gcc:            9.3.0-r1::gentoo
sys-devel/gcc-config:     2.3.2-r1::gentoo
sys-devel/libtool:        2.4.6-r6::gentoo
sys-devel/make:           4.2.1-r4::gentoo
sys-kernel/linux-headers: 5.4-r1::gentoo (virtual/os-headers)
sys-libs/glibc:           2.32-r2::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://192.168.0.25/gentoo-portage
    priority: -1000
    sync-rsync-extra-opts: 
    sync-rsync-verify-metamanifest: no
    sync-rsync-verify-jobs: 1
    sync-rsync-verify-max-age: 24

booboo
    location: /var/lib/layman/booboo
    masters: gentoo
    priority: 50

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="@FREE linux-fw-redistributable no-source-code NPSL"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=westmere -mtune=westmere -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=westmere -mtune=westmere -O2 -pipe"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
FCFLAGS="-march=westmere -mtune=westmere -O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-march=westmere -mtune=westmere -O2 -pipe"
GENTOO_MIRRORS="ftp://192.168.0.25"
LANG="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j5"
PKGDIR="/var/cache/binpkgs"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="X a52 aac acl acpi activities alsa amd64 berkdb branding bzip2 cairo cdda cdr cli crypt cups dbus declarative dri dts dvd dvdr elogind emboss encode exif flac fortran gdbm gif gpm gui iconv icu ipv6 jpeg kde kipi kwallet lcms libglvnd libnotify libtirpc lm-sensors mad mng mp3 mp4 mpeg multilib ncurses nls nptl ogg opengl openmp pam pango pcre pdf phonon plasma png policykit ppds pulseaudio qml qt4 qt5 readline sdl seccomp semantic-desktop spell split-usr ssl startup-notification svg tcpd tiff truetype udev udisks unicode upower usb vorbis widgets wxwidgets x264 xattr xcb xml xv xvid zlib" ABI_X86="64" ADA_TARGET="gnat_2018" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-2 php7-3 php7-4" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_8" PYTHON_TARGETS="python2_7 python3_8" RUBY_TARGETS="ruby25 ruby26" USERLAND="GNU" VIDEO_CARDS="nouveau" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LINGUAS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

=================================================================
                        Package Settings
=================================================================

dev-db/pgadmin4-4.17-r1::gentoo was built with the following:
USE="-doc" ABI_X86="(64)" PYTHON_SINGLE_TARGET="python3_8 -python3_6 -python3_7"
Comment 1 Aaron W. Swenson gentoo-dev 2020-12-13 20:24:17 UTC
Does this issue persist with 4.26?
Comment 2 Christian Reich 2020-12-17 15:21:59 UTC
had the exact same issue.
upgrading to dev-db/pgadmin4-4.28 fixed it for me!
even though I had to accept one more ~amd64 and apply use flags as followes:


=dev-python/flask-compress-1.8.0 ~amd64


# required by dev-python/flask-compress-1.8.0::gentoo
# required by dev-db/pgadmin4-4.28::gentoo[python_single_target_python3_8]
# required by @selected
# required by @world (argument)
>=app-arch/brotli-1.0.9-r1 python

thx for the hint :)
Comment 3 Jeff Hubbs 2020-12-17 16:25:58 UTC
I went through the above process and dev-db/pgadmin4-4.28 did emerge. Upon trying to start pgadmin4 from the KDE menu, it didn't launch Firefox...it inexplicably launched KImageMapEditor instead. /usr/bin/pgAdmin4 is left running but pointing Firefox to localhost:5432 won't connect and nmap doesn't show that port open either.
Comment 4 Aaron W. Swenson gentoo-dev 2020-12-17 18:15:41 UTC
(In reply to Jeff Hubbs from comment #3)
> I went through the above process and dev-db/pgadmin4-4.28 did emerge. Upon
> trying to start pgadmin4 from the KDE menu, it didn't launch Firefox...it
> inexplicably launched KImageMapEditor instead. /usr/bin/pgAdmin4 is left
> running but pointing Firefox to localhost:5432 won't connect and nmap
> doesn't show that port open either.

I don't think we'll be able to fix the launch bit for you.

You probably need to look at what setting you gave pgAdmin4, as it reuses settings from its first run and stores it as BrowserCommand to launch or open a tab in some browser. Try taking a look at that you have stored in ~/.config/pgadmin/pgadmin4.conf

It makes since that Firefox can't connect on port 5432, since that would be PostgreSQL's port and not bound by pgAdmin4. pgAdmin4 uses a random port each time it's opened. You can set it to a fixed port number if you'd like.

I don't know where the emerged document is on disk off the top of my head, but you can read the document in upstream's git:
https://git.postgresql.org/gitweb/?p=pgadmin4.git;a=blob;f=docs/en_US/desktop_deployment.rst;h=3453ab73eb2413c17df52d120165d09a098ad244;hb=HEAD