Skip to Content
Menu
This question has been flagged
2 Replies
2478 Views

ubuntu@ip-172-26-11-98:/opt/odoo17$ sudo systemctl status odoo17.service

● odoo17.service - Odoo17

     Loaded: loaded (/etc/systemd/system/odoo17.service; enabled; vendor preset: enabled)

     Active: failed (Result: exit-code) since Wed 2024-04-17 13:06:11 IST; 5s ago

       Docs: db.py", line 4, in

Apr 17 13:06:11 ip-172-26-11-98 odoo-bin[1360853]:     from psycopg2.extras import Json

Apr 17 13:06:11 ip-172-26-11-98 odoo-bin[1360853]: ModuleNotFoundError: No module named 'psycopg2'

Apr 17 13:06:11 ip-172-26-11-98 systemd[1]: odoo17.service: Main process exited, code=exited, status=1/FAILURE

Apr 17 13:06:11 ip-172-26-11-98 systemd[1]: odoo17.service: Failed with result 'exit-code'.


Avatar
Discard

Did you solve this issue? I'm facing the same problem.

Best Answer

In my case I was getting this error but I finally found the root of the problem, and it was because of the externally managed libraries. You can check all the discussion and answers here:
https://stackoverflow.com/questions/75608323/how-do-i-solve-error-externally-managed-environment-every-time-i-use-pip-3
What worked for me was setting this before loading the requierements (as a workaround in the suggested answer in the post I mentioned):
python3 -m pip config set global.break-system-packages true

Avatar
Discard
Best Answer

Hi,Try to Install the requirement 'psycopg2-binary ' instead of psycopg2

use the below script to install the requirement

pip install psycopg2-binary 


Hope it helps

Avatar
Discard
Author

i already ran this command "pip install psycopg2-binary"
Requirements already satisfied but the odoo cant run..

while run odoo status command

"ModuleNotFoundError: No module named 'psycopg2._psycopg'"

in my local machine dont have any problem while installing odoo17 i am facing problem in aws ubuntu.