Home » RDBMS Server » Server Administration » Scope of privileges (and PLUSTRACE role) (merged) (10g)
Scope of privileges (and PLUSTRACE role) (merged) [message #433785] Fri, 04 December 2009 04:54 Go to next message
filiprus
Messages: 9
Registered: February 2009
Location: Singapore
Junior Member
Hello,

I have a strong suspicion that this is a newbie question, so please bear with me!

I am trying to grant user QREMUSER the PLUSTRACE role so that he can run AUTOTRACE.

When I connect as sysdba "sqlplus sys as sysdba" and do "GRANT PLUSTRACE TO QREMUSER" I get "Grant succeeded".

Now, the role is visible in user_role_privs for QREMUSER, but ONLY when I connect using "sqlplus QREMUSER/PASS", but not when I connect to QREM's own database using "sqlplus QREMUSER/PASS@QREMDB".

I have tried connecting as sys into QREMDB (sqlplus QREMDB as sysdba) and granting QREMUSER the PLUSTRACE role from there, but it still doesn't impact QREMUSER's @ QREMDB privileges/roles as seen in user_role_privs, and effectively makes using AUTOTRACE impossible.

Can someone please explain the scope of privileges in oracle and/or point me to the solution? I would be most thankful!

Thanks and Regards,

Filip
Re: Scope of privileges (and PLUSTRACE role) [message #433787 is a reply to message #433785] Fri, 04 December 2009 05:00 Go to previous messageGo to next message
JRowbottom
Messages: 5933
Registered: June 2006
Location: Sunny North Yorkshire, ho...
Senior Member
It sounds a lot like you're connecting to two different databases.
Re: Scope of privileges (and PLUSTRACE role) (merged) [message #433813 is a reply to message #433785] Fri, 04 December 2009 06:29 Go to previous messageGo to next message
filiprus
Messages: 9
Registered: February 2009
Location: Singapore
Junior Member
yes, but shouldn't

sqlplus QREMDB as sysdba -> GRANT PLUSTRACE TO QREMUSER

and a subsequent

sqlplus QREMUSER/PASS@QREMDB

be referring to the same one?
Re: Scope of privileges (and PLUSTRACE role) (merged) [message #433818 is a reply to message #433813] Fri, 04 December 2009 06:58 Go to previous messageGo to next message
Michel Cadot
Messages: 63802
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Prove us you are connected to the same database.
For instance, give the output of
select * from v$database
from both.

Regards
Michel
Re: Scope of privileges (and PLUSTRACE role) (merged) [message #433836 is a reply to message #433813] Fri, 04 December 2009 08:10 Go to previous messageGo to next message
joy_division
Messages: 4615
Registered: February 2005
Location: East Coast USA
Senior Member
filiprus wrote on Fri, 04 December 2009 07:29
yes, but shouldn't

sqlplus QREMDB as sysdba -> GRANT PLUSTRACE TO QREMUSER

and a subsequent

sqlplus QREMUSER/PASS@QREMDB[/email]

be referring to the same one?


No, why would you think that? the second one refers to a specific database QREMDB. In the first one, you are relying on environment variables as to which database you connect to.

It's analogous to the implicit conversion. If you don't tell Oracle specifically what you want, you are just playing Russian roulette.
Re: Scope of privileges (and PLUSTRACE role) (merged) [message #433848 is a reply to message #433818] Fri, 04 December 2009 08:50 Go to previous message
filiprus
Messages: 9
Registered: February 2009
Location: Singapore
Junior Member
Yes, yes, yes!

Thanks a lot Michel.

I was using the wrong connect string.

It should be

sqlplus qremuser@qremdb as sysdba

and not

sqlplus qremdb as sysdba

Thanks again!
Previous Topic: Issue in adding LIST partition in a table
Next Topic: Weird result from ORA 01994
Goto Forum:
  


Current Time: Sun Sep 25 16:16:47 CDT 2016

Total time taken to generate the page: 0.15008 seconds