Link to home
Start Free TrialLog in
Avatar of Steve Wales
Steve WalesFlag for United States of America

asked on

ORA-1031 connecting /@sid as sysdba in SQLPLUS and RMAN

Environment:

OS: Oracle Linux 2.6.39-400.21.2.el6uek.x86_64
DB: Oracle 11.2.0.3 plus April 2013 CPU

I have a couple of databases on a relatively newly created server that I'm having issues with.

I can set ORACLE_HOME and ORACLE_SID e-vars and do either of the below just fine:

sqlplus / as sysdba
rman target /

However, for either if I attempt to add "@SID" after the connect string:

sqlplus /@test as sysdba
rman /@test

I am getting ORA-01031 insufficient privileges

I have been getting along just fine until I had to clone one database to another.  When I was trying to use RMAN to connect to both target and auxiliary at the same time I found the error above and thought I'd try it out in SQLPlus to see what I could see.

I have spent the last several hours searching google, EE, Oracle Support and haven't found much yet.

Things done so far:

* Verified permissions on oracle binary (set as 6751).
* Oracle OS user is a member of the dba group
* Checked the group setting in $ORACLE_HOME/rdbms/lib/config.c
* Reset the SYS password and recreated the password file to the same password
* Remote_Login_Passwordfile is set to EXCLUSIVE
* Tried adding SQLNET.AUTHENTICATION_SERVICES=(ALL) to sqlnet.ora on the server
* As a part of an earlier RMAN issue I created descriptors for the database instances in listener.ora

I'm wondering if I have something wrong with my listener configuration since the base connect (/ as sysdba) works just fine but it's not until I add @sid that starts giving me grief.

Any insights would be greatly appreciated.
Avatar of Franck Pachot
Franck Pachot
Flag of Switzerland image

Hi,
Does it work when providing the user/password such as:
sqlplus sys/syspassword@test as sysdba
?
ASKER CERTIFIED SOLUTION
Avatar of MikeOM_DBA
MikeOM_DBA
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Steve Wales

ASKER

@franckpachot:

Yes that works.

@MikeOM_DBA:

My main concern with this question was operation for RMAN duplicate.  I have no real reason to connect to sqlplus that way.

I've been working in Windows world for the last couple of years and we've just started back in Linux.  In Windows, when cloning a database this works fine:

set ORACLE_SID=test
rman target /@prod auxiliary /

Then I do the duplicate target test and it works just fine.

I have been doing some extra testing and managed (finally) to get around it like this:

[oracle@orav11 test]$ set ORACLE_SID=test
[oracle@orav11 test]$ rman

Recovery Manager: Release 11.2.0.3.0 - Production on Thu Jun 20 07:40:47 2013

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

RMAN> connect target 'sys@prod'

target database Password: 
connected to target database: PROD (DBID=xxxxxxxxxx)

RMAN> connect auxiliary /

connected to auxiliary database: TEST (not mounted)

RMAN> 

Open in new window


Once I managed to get both databases connected to RMAN I could perform the duplicate.  Still not sure why I can manually connect from the RMAN prompt while it doesn't work from the command line, but it's working now and that's all I really care about.
I've requested that this question be closed as follows:

Accepted answer: 0 points for sjwales's comment #a39262510

for the following reason:

Expert comments were (a) asking more questions and then (b) stating that what I was trying to do didn't work.

I did some further testing on my own and managed to come up with my own solution.

Thanks for the responses though.
Actually, I will accept this as the answer since this is what led me to my solution.

Thanks :)