skip to Main Content

I’m trying to get pgadmin4 installed on my Centos 7.6 machine, and I followed the below tuto :
https://computingforgeeks.com/how-to-install-pgadmin-on-centos-fedora/

However, when I run:
”’
python /usr/lib/python2.7/site-packages/pgadmin4-web/setup.py
”’

I get the following error:

Traceback (most recent call last): File
“/usr/lib/python2.7/site-packages/pgadmin4-web/setup.py”, line 413, in

setup_db() File “/usr/lib/python2.7/site-packages/pgadmin4-web/setup.py”, line 347, in
setup_db
app = create_app() File “/usr/lib/python2.7/site-packages/pgadmin4-web/pgadmin/init.py”,
line 711, in create_app
from flask_compress import Compress ImportError: No module named flask_compress

Any idea what I’ve missed ?
Thanks in advance.

2

Answers


  1. Chosen as BEST ANSWER

    Ok i managed to get 'initialization' using pip install Flask-Compress

    However when running http://localhost/pgadmin I get an internal server error (500), as follows:

    ''''

    [Tue Dec 17 15:27:04.174126 2019] [:error] [pid 13510] [remote ::1:224] mod_wsgi (pid=13510): Target WSGI script '/usr/lib/python2.7/site-packages/pgadmin4-web/pgAdmin4.wsgi' cannot be loaded as Python module.
    [Tue Dec 17 15:27:04.174151 2019] [:error] [pid 13510] [remote ::1:224] mod_wsgi (pid=13510): Exception occurred processing WSGI script '/usr/lib/python2.7/site-packages/pgadmin4-web/pgAdmin4.wsgi'.
    [Tue Dec 17 15:27:04.174168 2019] [:error] [pid 13510] [remote ::1:224] Traceback (most recent call last):
    [Tue Dec 17 15:27:04.174181 2019] [:error] [pid 13510] [remote ::1:224]   File "/usr/lib/python2.7/site-packages/pgadmin4-web/pgAdmin4.wsgi", line 36, in <module>
    [Tue Dec 17 15:27:04.174197 2019] [:error] [pid 13510] [remote ::1:224]     from pgAdmin4 import app as application
    [Tue Dec 17 15:27:04.174202 2019] [:error] [pid 13510] [remote ::1:224]   File "/usr/lib/python2.7/site-packages/pgadmin4-web/pgAdmin4.py", line 109, in <module>
    [Tue Dec 17 15:27:04.174210 2019] [:error] [pid 13510] [remote ::1:224]     app = create_app()
    [Tue Dec 17 15:27:04.174215 2019] [:error] [pid 13510] [remote ::1:224]   File "/usr/lib/python2.7/site-packages/pgadmin4-web/pgadmin/__init__.py", line 244, in create_app
    [Tue Dec 17 15:27:04.174222 2019] [:error] [pid 13510] [remote ::1:224]     create_app_data_directory(config)
    [Tue Dec 17 15:27:04.174226 2019] [:error] [pid 13510] [remote ::1:224]   File "/usr/lib/python2.7/site-packages/pgadmin4-web/pgadmin/setup/data_directory.py", line 42, in create_app_data_directory
    [Tue Dec 17 15:27:04.174234 2019] [:error] [pid 13510] [remote ::1:224]     os.chmod(config.SESSION_DB_PATH, 0o700)
    [Tue Dec 17 15:27:04.174246 2019] [:error] [pid 13510] [remote ::1:224] OSError: [Errno 1] Operation not permitted: '/var/lib/pgadmin4/sessions'
    

    ''''


  2. You need to install Flask-Compress:

    https://pypi.org/project/Flask-Compress/

    Run the following command in your terminal:

    pip install Flask-Compress

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search