Database link creation error

From: Ram Raman <veeeraman_at_gmail.com>
Date: Fri, 6 Mar 2009 15:24:25 -0600
Message-ID: <effc058d0903061324q1caed6bcq7a74185d9accaaac_at_mail.gmail.com>



Hi all,

I seem to get error with database link creation. It looks like a very simple thing, but I am not sure what I am missing. I have modified the user name and the directory name slightly, but other than it is the same. The link creation seem to work OK with other user names that I have created like MM, DUMMY, TEST, etc. They all work. I can assure you the passwd was the same in both cases. It is just that when for the user DMUE113R (different from the real id I used) I get this error:

/throra10/scripts/DCL/script_location >sqlplus

SQL*Plus: Release 10.2.0.2.0 - Production on Fri Mar 6 15:09:18 2009

Copyright (c) 1982, 2005, Oracle. All Rights Reserved.

Enter user-name: / as sysdba

Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.2.0 - 64bit Production With the Partitioning, OLAP and Data Mining options

SYS_at_HRDEV> _at_create_user.sql\
Enter value for user_name: VV

old   1: create user &&user_name
new   1: create user VV
old   2:    identified by &&user_name
new   2:    identified by VV

User created.

SYS_at_HRDEV> _at_grant_sys_privs.sql
old 1: grant create session to &&user_name new 1: grant create session to VV

Grant succeeded.

old 1: grant create table to &&user_name new 1: grant create table to VV

Grant succeeded.

old 1: grant create procedure to &&user_name new 1: grant create procedure to VV

Grant succeeded.

old 1: grant create view to &&user_name new 1: grant create view to VV

Grant succeeded.

SYS_at_HRDEV>

SYS_at_HRDEV>
SYS_at_HRDEV> grant create database link to VV;

Grant succeeded.

SYS_at_HRDEV> conn VV
Enter password:
Connected.
VV_at_HRDEV> create database link HRTST
  2 connect to SYSADM identified by passwd   3 using 'HRTST';

Database link created.

VV_at_HRDEV> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.2.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options
/throra10/scripts/DCL/script_location >sqlplus

SQL*Plus: Release 10.2.0.2.0 - Production on Fri Mar 6 15:11:19 2009

Copyright (c) 1982, 2005, Oracle. All Rights Reserved.

Enter user-name: / as sysdba

Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.2.0 - 64bit Production With the Partitioning, OLAP and Data Mining options

SYS_at_HRDEV> _at_create_user.sql
Enter value for user_name: DMUE113R

old   1: create user &&user_name
new   1: create user DMUE113R
old   2:    identified by &&user_name
new   2:    identified by DMUE113R

User created.

SYS_at_HRDEV> _at_grant_sys_privs.sql
old 1: grant create session to &&user_name new 1: grant create session to DMUE113R

Grant succeeded.

old 1: grant create table to &&user_name new 1: grant create table to DMUE113R

Grant succeeded.

old 1: grant create procedure to &&user_name new 1: grant create procedure to DMUE113R

Grant succeeded.

old 1: grant create view to &&user_name new 1: grant create view to DMUE113R

Grant succeeded.

SYS_at_HRDEV> grant create database link to DMUE113R;

Grant succeeded.

SYS_at_HRDEV> conn DMUE113R
Enter password:
Connected.
DMUE113R_at_HRDEV> create database link HRTST   2 connect to SYSADM identified by passwd   3 using 'HRTST';
create database link HRTST

                     *

ERROR at line 1:
ORA-01031: insufficient privileges

DMUE113R_at_HRDEV>

 Thanks.

--
http://www.freelists.org/webpage/oracle-l
Received on Fri Mar 06 2009 - 15:24:25 CST

Original text of this message