Home » SQL & PL/SQL » SQL & PL/SQL » How to connect SYS from SQLPLUS
How to connect SYS from SQLPLUS [message #174430] Mon, 29 May 2006 04:17 Go to next message
sruthi
Messages: 23
Registered: May 2006
Junior Member

Dear all

I could connect DB usnig TOAD,OEM for SYS. But when i try to connect from SQLPLUS it is giving the follwing error.


ORA-01031: insufficient privileges.

Note: This is from cleint mechine.


Farook Quisar
Re: How to connect SYS from SQLPLUS [message #174473 is a reply to message #174430] Mon, 29 May 2006 05:40 Go to previous messageGo to next message
Littlefoot
Messages: 21826
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Is this the issue ONLY with the SYS user, or do you get the same message when connecting as a non-privileged user (such as "scott", for example)?
Re: How to connect SYS from SQLPLUS [message #174477 is a reply to message #174473] Mon, 29 May 2006 05:59 Go to previous messageGo to next message
sruthi
Messages: 23
Registered: May 2006
Junior Member
thank you for the answer.

The error is coming only when i connect with SYS, there is no problem for other schemas.

Re: How to connect SYS from SQLPLUS [message #174519 is a reply to message #174477] Mon, 29 May 2006 07:51 Go to previous messageGo to next message
Littlefoot
Messages: 21826
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
What level of access is granted to you at the operating system level? Are you, perhaps, a restricted user? What happens if you change it to "Administrator" (if you have a privilege to do that)?
Re: How to connect SYS from SQLPLUS [message #175455 is a reply to message #174519] Fri, 02 June 2006 05:37 Go to previous messageGo to next message
Bijupm
Messages: 16
Registered: February 2006
Junior Member
Try this


connect sys/password@database as sysdba;
Re: How to connect SYS from SQLPLUS [message #175571 is a reply to message #175455] Fri, 02 June 2006 23:20 Go to previous messageGo to next message
sruthi
Messages: 23
Registered: May 2006
Junior Member
Thanks Bijupm,

I did try as u suggested(connect sys/password@database as sysdba; ), but it is gving the error:"ORA-12154: TNS:could not resolve service name". But Im able to connect from OEM or TOAD without any problem.


Sruthi
Re: How to connect SYS from SQLPLUS [message #175578 is a reply to message #175571] Sat, 03 June 2006 00:53 Go to previous messageGo to next message
Frank
Messages: 7901
Registered: March 2000
Senior Member
How exactly did you connect when you got your initial 'insufficient privileges' error?
Re: How to connect SYS from SQLPLUS [message #175606 is a reply to message #175578] Sat, 03 June 2006 04:38 Go to previous messageGo to next message
sruthi
Messages: 23
Registered: May 2006
Junior Member
hi Frank,

Sorry the actual error is: "ORA-01031: insufficient privileges".


sruthi
Re: How to connect SYS from SQLPLUS [message #175609 is a reply to message #174430] Sat, 03 June 2006 05:10 Go to previous messageGo to next message
gajini
Messages: 262
Registered: January 2006
Senior Member
If u've to connect as SYSDBA or SYS(who is having SYSDBA privilege) from client,u should have password file
authentication or OS authentication.So create a password file,so that u can connect as SYS to the server from client.

[Updated on: Sat, 03 June 2006 05:11]

Report message to a moderator

Re: How to connect SYS from SQLPLUS [message #175610 is a reply to message #175609] Sat, 03 June 2006 05:30 Go to previous messageGo to next message
sruthi
Messages: 23
Registered: May 2006
Junior Member
hi gajini,

Please notice that I can still connect from TOAD or OEM without any error. The error is coming only when i try to connect from SQL*PLUS.

Sruthi

Re: How to connect SYS from SQLPLUS [message #175615 is a reply to message #174430] Sat, 03 June 2006 06:05 Go to previous messageGo to next message
gajini
Messages: 262
Registered: January 2006
Senior Member
Can u tell me how u r trying to connect to database,

i.e, whether u r trying to connect as,

sys/passwd as sysdba

or

sys/passwd@database as sysdba
Re: How to connect SYS from SQLPLUS [message #175617 is a reply to message #175615] Sat, 03 June 2006 06:25 Go to previous messageGo to next message
sruthi
Messages: 23
Registered: May 2006
Junior Member
hi gajini

I tried both , but in vien. Gving the same error.

Re: How to connect SYS from SQLPLUS [message #175618 is a reply to message #174430] Sat, 03 June 2006 07:01 Go to previous messageGo to next message
gajini
Messages: 262
Registered: January 2006
Senior Member


Try the following,in SQLNET.ORA ,set
sqlnet.authentication_services = (NONE) or comment it by,
#sqlnet.authentication_services = (TNS)
Re: How to connect SYS from SQLPLUS [message #175621 is a reply to message #175617] Sat, 03 June 2006 07:47 Go to previous messageGo to next message
Art Metzer
Messages: 2480
Registered: December 2002
Senior Member
Is there a file called login.sql in the directory from which you are launching SQL*Plus? Does it contain any calls that your user does not have permissions to execute? Failing that, I would hunt down any glogin.sql file, and similarly look for subprogram calls your user is not privileged to make.
Re: How to connect SYS from SQLPLUS [message #175645 is a reply to message #175621] Sat, 03 June 2006 23:28 Go to previous messageGo to next message
sruthi
Messages: 23
Registered: May 2006
Junior Member
hi Art Metzer,

There is no calls in the login.sql which is not having permission to the user. Remind you that the user is SYS. And as per your suggetion I commented out all the commands in login.sql and still in vien. And one more thing I can still access the SQLPLUS from TOAD for sys, but when i try to connect directly it is gving the error.

thnks
Farook Quisar.
Re: How to connect SYS from SQLPLUS [message #180852 is a reply to message #174430] Wed, 05 July 2006 08:55 Go to previous messageGo to next message
Chewie71
Messages: 19
Registered: October 2005
Location: WIU
Junior Member
Did this ever get resolved? I'm having the exact same problem. Cannot connect to the database through SQLPlus or RMAN.

$ rman target sys/syspass@dbname

...gets this result...

RMAN-00554: initialization of internal recovery manager package failed
RMAN-04005: error from target database:
ORA-01031: insufficient privileges

Going into SQLPlus...
$ sqlplus /nolog
SQL> connect sys/syspass@dbname as sysdba

gets this result...

ERROR:
ORA-01031: insufficient privileges

Help!!

Thanks,
Matt
Re: How to connect SYS from SQLPLUS [message #180854 is a reply to message #180852] Wed, 05 July 2006 09:03 Go to previous messageGo to next message
orausern
Messages: 826
Registered: December 2005
Senior Member
To: Chewie71. In your scenario:
Connecting as sys remotely also requires that password file be set up. was that done?

Re: How to connect SYS from SQLPLUS [message #180856 is a reply to message #180854] Wed, 05 July 2006 09:11 Go to previous messageGo to next message
Chewie71
Messages: 19
Registered: October 2005
Location: WIU
Junior Member
nirav_hyd wrote on Wed, 05 July 2006 09:03

To: Chewie71. In your scenario:
Connecting as sys remotely also requires that password file be set up. was that done?




Yes...I used the orapwd command to create the password file in $ORACLE_HOME/dbs.

Thanks,
Matt
Re: How to connect SYS from SQLPLUS [message #180858 is a reply to message #180856] Wed, 05 July 2006 09:18 Go to previous message
orausern
Messages: 826
Registered: December 2005
Senior Member
Chewie71, then it is something I do not know.
Previous Topic: error: group by / having
Next Topic: Looking for a Book
Goto Forum:
  


Current Time: Sun Sep 21 17:18:29 CDT 2025