Home » Infrastructure » Unix » HP-UX : Directory Alias & UNIX account
HP-UX : Directory Alias & UNIX account [message #159767] Tue, 21 February 2006 06:34 Go to next message
vivebaloo
Messages: 3
Registered: February 2006
Junior Member
Hi,

Our Oracle 10Gr2 OLAP db runs on a HP-UX server.

We would like to create this kind of directory :

CREATE OR REPLACE DIRECTORY my_test AS '$path';

where $path is set at the logon of an unix user. This directory is used by an old EXPRESS program running with this package :

execute DBMS_AW.execute('call PIPX70')

1) Can anybody tell me if it is possible ?

2) In case of the first answer is 'yes', wich user has to set '$path' ???

Thanks in advance and sorry for my french poor english...Wink

R.GEGOUE
Re: HP-UX : Directory Alias & UNIX account [message #159768 is a reply to message #159767] Tue, 21 February 2006 06:37 Go to previous messageGo to next message
vivebaloo
Messages: 3
Registered: February 2006
Junior Member
I forgot this :

ERROR: (ORA-36786) File my_test/PIPX70 does not exist or cannot be accessed.
In EXPPGM!PIKX70 PROGRAM:
otf &joinchars(DIR_ALIAS(my_test _typfic) '/' _restit)
Re: HP-UX : Directory Alias & UNIX account [message #159835 is a reply to message #159768] Tue, 21 February 2006 18:54 Go to previous messageGo to next message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
At unix login, you can insert your environment into a table. You can make the rows distinguishable per user by including the unix username or whatever in the insert statement.
http://www.oracledba.co.uk/tips/env_vars.htm
Re: HP-UX : Directory Alias & UNIX account [message #159845 is a reply to message #159835] Tue, 21 February 2006 20:43 Go to previous messageGo to next message
rleishman
Messages: 3728
Registered: October 2005
Location: Melbourne, Australia
Senior Member
I'm pretty sure there's no way to create a DIRECTORY object that dynamically determines its target.

The reason for DIRECTORY objects with READ/WRITE privs is because UTL_FILE and EOTs access the file system as the oracle user, with all its inherent privs.

If you could dynamically change the target of a DIRECTORY, you could point it to $ORACLE_HOME and start blowing away files - or worse - point it to the location of the DB data files.

_____________
Ross Leishman
Re: HP-UX : Directory Alias & UNIX account [message #159887 is a reply to message #159845] Wed, 22 February 2006 01:56 Go to previous messageGo to next message
vivebaloo
Messages: 3
Registered: February 2006
Junior Member
Lot ok thanks for both of you !

R.GEGOUE
Re: HP-UX : Directory Alias & UNIX account [message #160014 is a reply to message #159845] Wed, 22 February 2006 14:29 Go to previous message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
   EXECUTE IMMEDIATE 'create or replace directory MY_PATH as '''||v_path||'''';
   --EXECUTE IMMEDIATE 'grant read on directory MY_PATH to PUBLIC';

Ross it correct - the directory definition can be changed dynamically, but all concurrent users will access the last definition.

[Updated on: Wed, 22 February 2006 14:34]

Report message to a moderator

Previous Topic: ftp issue
Next Topic: Encrypt Password to connect to the back-end database
Goto Forum:
  


Current Time: Tue Apr 16 09:52:14 CDT 2024