Link to home
Start Free TrialLog in
Avatar of Intern
Intern

asked on

Changing File Permissions

I am using a user 'FTP' to ftp files to my Redhat box.  These files that get ftp'd come across with RW-R-R properties.  What I need to know is how can I automatically grant write priviliges to the group?

The 'FTP' user will put the files on the system, but the Oracle Database needs to be able to delete those files.  So the user 'ORACLE' and 'FTP' are in the same group, but 'ORACLE' can not delete the file because of the permissions on the file.

Is there anyway to change this?
Avatar of Lee W, MVP
Lee W, MVP
Flag of United States of America image

Try from a telnet or SSH session:

chmod 664 *.*

in the directory containing the files.
Avatar of Intern
Intern

ASKER

The problem is that we are FTP'ing from an VMS system and chmod is not a recognized command.  I really need to be able to change the permissions right after the file is moved over.  Is there a way to change the default settings for files that get ftp'd to the server?

So that everyfile that oracleftp sends it is open to everyone?
SOLUTION
Avatar of Lee W, MVP
Lee W, MVP
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 Intern

ASKER

the folder is set to 777
Avatar of Intern

ASKER

Can I create a job in linux that runs every 30 seconds that would run as the user 'FTP' in the /home/ftp directory that would do a

chmod 777 *.dat
ASKER CERTIFIED SOLUTION
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
SOLUTION
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 Intern

ASKER

I am using VSFTP - or Very Secure FTP.  I will look into it.
Avatar of Intern

ASKER

How can you delete a file if you are not the owner of that file???  How can 'ORACLE' delete a file owned by 'FTP'?

I changed the permissions on the file to 777 but ORACLE still can not delete the file.
At first, you don't have to set the permissions to 0777. It's enough to set them to 0666 because you probably don't want them to execute, do you?
What permissions has the directory from which you want to delete files? If ORACLE doesn't have write permissions this user won't be able to delete because he can't change the contents of the directory.
Just call chmod g+w DIRECTORY. Than try to delete the file with the ORACLE-user.

Ciao
Timo
Avatar of Intern

ASKER

The directory is set to 7777, I really don't care if people can execute them, I just want to be able to delete the files
Avatar of Intern

ASKER

Figured it out.  Needed it to be 0777 for the folder
That's what I meant. But it's enough to be 0770 because you probably don't want the rest of the world to delete/access your file.

Ciao
Timo
SOLUTION
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