Re: Something I don't understand with the use of schemas - Mailing list pgsql-hackers

From Jim C. Nasby
Subject Re: Something I don't understand with the use of schemas
Date
Msg-id 20051212200503.GX54639@pervasive.com
Whole thread Raw
In response to Re: Something I don't understand with the use of schemas  ("Joshua D. Drake" <jd@commandprompt.com>)
Responses Re: Something I don't understand with the use of schemas
Re: Something I don't understand with the use of schemas
List pgsql-hackers
On Sat, Dec 10, 2005 at 09:18:32AM -0800, Joshua D. Drake wrote:
> >
> >However there is an effort to get rid of root in some Unix lands,
> >separating its responsabilities with more granularity.  Maybe there
> >could be an effort, not to hand-hold the true superusers, but to
> >delegate some of its responsabilities to other users.
> >  
> Like sudo?

I think it would be a huge benefit to have something equivalent to sudo
for psql (though maybe it could be generalized more). Having to change
to a different connection/authorization anytime you need to do something
requiring superuser is a real pita, and encourages things like making
yourself a superuser.

In the case of shell commands like createdb, sudo is indeed a pretty
viable alternative; you just need to do something like sudo -u
postgres command. But there's no equivalent for psql; if you sudo -u
postgres psql it's the equivalent of su - root (though at least you
wouldn't need to know the password to the postgres account).

I'd love to see something like SUDO ALTER USER ... SUDO REINDEX ... etc.
That would make it easy to do 'normal' work with a non-superuser
account.
-- 
Jim C. Nasby, Sr. Engineering Consultant      jnasby@pervasive.com
Pervasive Software      http://pervasive.com    work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf       cell: 512-569-9461


pgsql-hackers by date:

Previous
From: Guillaume LELARGE
Date:
Subject: Re: Something I don't understand with the use of schemas
Next
From: Andrew Dunstan
Date:
Subject: Re: Different length lines in COPY CSV