dbTalk Databases Forums  

Phantom user in db--'128'

comp.databases.postgresql.general comp.databases.postgresql.general


Discuss Phantom user in db--'128' in the comp.databases.postgresql.general forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Taber, Mark
 
Posts: n/a

Default Phantom user in db--'128' - 11-19-2004 , 09:19 AM






I posted this earlier, and got no responses.
While using pg_dump and pg_restore (or attempting to restore, more
precisely), the process failed because of a missing user, user '128'. I
never created such a user, and when going to Privileges, such a user does
not exist in the list. However, while going out and checking some of the
tables, this user shows up as a user with privileges on them (however, not
on all tables). How do I get rid of this user? And how do I ensure that it
doesn't get created again? I'd like to understand what is really going on
before hacking the user table.
Thanks in advance.


Mark Taber
State of California
Department of Finance
Infrastructure & Architecture

916.323.3104 x 2945
mark.taber (AT) dof (DOT) ca.gov



Reply With Quote
  #2  
Old   
Tom Lane
 
Posts: n/a

Default Re: Phantom user in db--'128' - 11-19-2004 , 09:42 AM






"Taber, Mark" <Mark.Taber (AT) dof (DOT) ca.gov> writes:
Quote:
While using pg_dump and pg_restore (or attempting to restore, more
precisely), the process failed because of a missing user, user '128'. I
never created such a user, and when going to Privileges, such a user does
not exist in the list. However, while going out and checking some of the
tables, this user shows up as a user with privileges on them (however, not
on all tables). How do I get rid of this user? And how do I ensure that it
doesn't get created again? I'd like to understand what is really going on
You had a user with usesysid 128, whom you dropped, but he still had
privileges on some tables --- DROP USER is not good about detecting
dangling references.

I'd suggest recreating the user (CREATE USER foo WITH SYSID 128) and
then being careful to REVOKE all his privileges before you drop him
again. Or you can just manually edit the dump file to remove the
attempts to GRANT him privileges.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match



Reply With Quote
  #3  
Old   
Taber, Mark
 
Posts: n/a

Default Re: Phantom user in db--'128' - 11-19-2004 , 10:53 AM



Thanks! Worked like a charm.


Mark Taber
State of California
Department of Finance
Infrastructure & Architecture

916.323.3104 x 2945
mark.taber (AT) dof (DOT) ca.gov

-----Original Message-----
From: Tom Lane [mailto:tgl (AT) sss (DOT) pgh.pa.us]
Sent: Friday, November 19, 2004 7:42 AM
To: Taber, Mark
Cc: pgsql-general (AT) postgresql (DOT) org
Subject: Re: [GENERAL] Phantom user in db--'128'

"Taber, Mark" <Mark.Taber (AT) dof (DOT) ca.gov> writes:
Quote:
While using pg_dump and pg_restore (or attempting to restore, more
precisely), the process failed because of a missing user, user '128'.
I never created such a user, and when going to Privileges, such a user
does not exist in the list. However, while going out and checking some
of the tables, this user shows up as a user with privileges on them
(however, not on all tables). How do I get rid of this user? And how
do I ensure that it doesn't get created again? I'd like to understand
what is really going on
You had a user with usesysid 128, whom you dropped, but he still had
privileges on some tables --- DROP USER is not good about detecting dangling
references.

I'd suggest recreating the user (CREATE USER foo WITH SYSID 128) and then
being careful to REVOKE all his privileges before you drop him again. Or
you can just manually edit the dump file to remove the attempts to GRANT him
privileges.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.