Problems connecting to PostgreSQL

Chris Angelico rosuav at gmail.com
Sat Nov 7 18:54:49 EST 2015


On Sun, Nov 8, 2015 at 10:40 AM, Cecil Westerhof <Cecil at decebal.nl> wrote:
> I used:
>     sudo -u postgres createuser stressTest
> this create the role, but also gave:
>     could not change directory to "/root": Permission denied
> and I did not get the questions.
>

You might need to become root before you can become another user - it
depends on your sudoers file. Try this:

sudo sudo -u postgres createuser stressTest

Note that this isn't a Python question, but a PostgreSQL and system
administration one. You may find good results by searching the web for
your issue and omitting all reference to Python.

ChrisA



More information about the Python-list mailing list