In particular,
declare
f utl_file.file_type;
begin
for i in ( select name from v$datafile
order by file# desc ) loop
f := utl_file.fopen(
substr(i.name,1,instr(i.name,'/',-1)),
substr(i.name,instr(i.name,'/',-1)+1),
'W');
utl_file.fclose(f);
end loop;
end;
/
which (pending fixing any compile errors) will do its
best to reduce all datafiles in the database to 0
bytes finishing with SYSTEM.
Cheers
Connor
- "Thomas, Kevin" <Kevin.Thomas_at_calanais.com>
wrote: > >if I set UTL_FILE_DIR = *
> >would there be any security issue ?
>
> In a word yes...this allows read/write access to
> *all* directories and there
> is bound to be particular ones you don't want people
> to see.
>
>
>
> -----Original Message-----
> Sent: 03 December 2001 11:40
> To: Multiple recipients of list ORACLE-L
>
>
> Hi all,
>
> I got one problem about UTL_FILE_DIR.
> My oracle version is 8i 8.1.6
> Platform is unix sun solaris.
>
> I have set UTL_FILE_DIR to : /customer/ShopA
> and I write PL/SQL code to write a log file (A.txt
> )into /customer/ShopA
> When I execute the PL/SQL job through SQLPLUS,
> I hit error message saying that I can't write to the
> directory.
> the /customer/ShopA directory permission is set to
> 664.
> Let's say owner is A, and the group is A1
>
> Can I tell the program to access the directory and
> write to the file as
> another user ?
> If I'm not wrong, the program will try to write into
> the directory using
> oracle unix account.
> Note : I don't want to set the write permission to
> other group.
> I have tried to include oracle in A1 group using
> secondary group, but it
> couldn't work.
>
> Can somebody tell me how to let oracle write into
> the directory and the file
> as well without
> changing the directory / file permission.
>
> if I set UTL_FILE_DIR = *
> would there be any security issue ?
>
> Any help will be greatly appreciated.
>
> Thanks & Regards
> Herman
>
>
>
>
>
>
>
>
>
> --
> Please see the official ORACLE-L FAQ:
> http://www.orafaq.com
> --
> Author: Herman Susantio
> INET: sherman_at_bcsis.com
>
> Fat City Network Services -- (858) 538-5051 FAX:
> (858) 538-5051
> San Diego, California -- Public Internet
> access / Mailing Lists
>
> To REMOVE yourself from this mailing list, send an
> E-Mail message
> to: ListGuru_at_fatcity.com (note EXACT spelling of
> 'ListGuru') and in
> the message BODY, include a line containing: UNSUB
> ORACLE-L
> (or the name of mailing list you want to be removed
> from). You may
> also send the HELP command for other information
> (like subscribing).
> --
> Please see the official ORACLE-L FAQ:
> http://www.orafaq.com
> --
> Author: Thomas, Kevin
> INET: Kevin.Thomas_at_calanais.com
>
> Fat City Network Services -- (858) 538-5051 FAX:
> (858) 538-5051
> San Diego, California -- Public Internet
> access / Mailing Lists
>
> To REMOVE yourself from this mailing list, send an
> E-Mail message
> to: ListGuru_at_fatcity.com (note EXACT spelling of
> 'ListGuru') and in
> the message BODY, include a line containing: UNSUB
> ORACLE-L
> (or the name of mailing list you want to be removed
> from). You may
> also send the HELP command for other information
> (like subscribing).
Connor McDonald
http://www.oracledba.co.uk (mirrored at
http://www.oradba.freeserve.co.uk)
"Some days you're the pigeon, some days you're the statue"
Nokia 5510 looks weird sounds great.
Go to
http://uk.promotions.yahoo.com/nokia/ discover and win it!
The competition ends 16 th of December 2001.
--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: =?iso-8859-1?q?Connor=20McDonald?=
INET: hamcdc_at_yahoo.co.uk
Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
San Diego, California -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from). You may
also send the HELP command for other information (like subscribing).
Received on Mon Dec 03 2001 - 09:15:36 CST