The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Advanced & Expert Users
Google UNIX.COM


UNIX for Advanced & Expert Users Advanced UNIX and Linux questions go here. Expert-to-Expert.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Newly created files default group and write permissions goldfish UNIX for Dummies Questions & Answers 2 02-20-2008 03:39 PM
Files created in last 24 hours jayaramanit Shell Programming and Scripting 1 09-08-2007 01:34 AM
How to list files Created in last 2 hrs rsonakiya UNIX for Dummies Questions & Answers 2 05-12-2004 12:22 PM
new directory - how to force files created in it to inherit grp,own and permissions avisb UNIX for Dummies Questions & Answers 2 04-26-2002 01:47 PM
Two Files Created For Every One? Atama UNIX for Dummies Questions & Answers 1 04-12-2002 01:44 PM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 07-16-2008
Registered User
 

Join Date: Jul 2008
Posts: 3
files created with different permissions

Hi,

Within a SQL file i am calling 5 shell scripts in back ground and redirecting their outputs to different log files in a specific directory.
Now when I observed is, the log files are created with different permissions even though i did not do any thing specific.

For example in run_scripts.sql I am doing:
! nohup /u36/app/1SR/v69/111.sh > /nw_disk1/oradb/flatfile/log/111.log &
! nohup /u36/app/1SR/v69/222.sh > /nw_disk1/oradb/flatfile/log/222.log &
! nohup /u36/app/1SR/v69/333.sh > /nw_disk1/oradb/flatfile/log/333.log &
! nohup /u36/app/1SR/v69/444.sh > /nw_disk1/oradb/flatfile/log/444.log &
! nohup /u36/app/1SR/v69/555.sh > /nw_disk1/oradb/flatfile/log/555.log &

After the scripts are executed when i checked in /nw_disk1/oradb/flatfile/log directory: ls -ltr *.log

-rw-r--r-- 1 oracle dba 1059 Jul 16 06:15 111.log
-rw-r--r-- 1 oracle dba 1428 Jul 16 06:15 222.log
-rw-r----- 1 oracle dba 1059 Jul 16 06:15 333.log
-rw-r----- 1 oracle dba 1212 Jul 16 06:15 444.log
-rw-r----- 1 oracle dba 1129 Jul 16 06:15 555.log

How this is possible? Only first 2 log files have read permissions for others.

Thanks in advance.
Reply With Quote
Forum Sponsor
  #2  
Old 07-16-2008
Registered User
 

Join Date: Jul 2008
Posts: 7
Why don't you try to chmod the file when your script has executed writing to the output file?
Reply With Quote
  #3  
Old 07-16-2008
...@...
 

Join Date: Feb 2004
Location: NM
Posts: 4,297
Unless you own the files - and those are owned by oracle - your umask will not affect permissions on those files - in the case when they already existed to start with and you are just overwriting them. Or if you execute a umask statement somewhere in your code, obviously.
Reply With Quote
Google The UNIX and Linux Forums
Reply

Tags
file permissions

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 05:26 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0