Path: csiph.com!news.swapon.de!fu-berlin.de!uni-berlin.de!not-for-mail From: Chris Angelico Newsgroups: comp.lang.python Subject: Re: Problems connecting to PostgreSQL Date: Sun, 8 Nov 2015 10:54:49 +1100 Lines: 18 Message-ID: References: <87wptt5qg4.fsf@Equus.decebal.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: news.uni-berlin.de cLnjNfWmzxzPT420pU3eVA5dZV+7Jpd4MUY9SWY/d+Kw== Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.002 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'root': 0.04; 'postgresql': 0.07; 'cc:addr:python-list': 0.09; 'postgres': 0.09; 'python': 0.10; 'python.': 0.11; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'omitting': 0.16; 'received:209.85.213.176': 0.16; 'received:io': 0.16; 'received:psf.io': 0.16; 'subject:Problems': 0.16; 'sudo': 0.16; 'used:': 0.16; 'wrote:': 0.16; '2015': 0.20; 'cc:2**0': 0.20; 'cc:addr:python.org': 0.20; 'permission': 0.20; 'denied': 0.22; 'role,': 0.22; 'file.': 0.22; 'am,': 0.23; 'this:': 0.23; 'header:In-Reply-To:1': 0.24; 'message-id:@mail.gmail.com': 0.27; 'another': 0.32; 'received:google.com': 0.35; 'could': 0.35; 'nov': 0.35; 'question,': 0.35; "isn't": 0.35; 'but': 0.36; 'received:209.85': 0.36; 'depends': 0.36; 'subject:: ': 0.37; 'received:209.85.213': 0.37; 'received:209': 0.38; 'your': 0.60; 'results': 0.66; 'cecil': 0.84; 'chrisa': 0.84; 'westerhof': 0.84; 'to:none': 0.91 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=Nx9KXc3mIZnnRMSGO6a4jfILEkqYmQT5fGbdh5ScCsU=; b=uiTKqylT2dz9xs4fCuJZ1Zu99tq+qaNXww4Bdhx4VMLhU3FuCyeA3cBjfniiIUSp0R qKbRB7rTW5MMW5zBtcegZ3XqbtGKi+2+R8uRSF10JOedGKMtlOCyvAngP3LJfCtS+/oD 76mtI/SL90bpwpwtRxhwdFkocU/+jMO9ns/MJlMXgKnnRzof748XFtXNXwYJLx0emvds eoHdvPi6ppxJMkqGekzNiX/xkrL3n2+Q2LArzLEvzyPjHI1G2+SobH0KUoQAWQaieaFb FojJi/i68habfNksSVDWJhDQrnVTQoKjCUrvhJ4xMqI4H6NEgJAFXQf62/TDw9+vZI0a PQxQ== X-Received: by 10.50.83.38 with SMTP id n6mr16007292igy.92.1446940489885; Sat, 07 Nov 2015 15:54:49 -0800 (PST) In-Reply-To: <87wptt5qg4.fsf@Equus.decebal.nl> X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.20+ Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Xref: csiph.com comp.lang.python:98411 On Sun, Nov 8, 2015 at 10:40 AM, Cecil Westerhof 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