Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Default Permissions

Posted on 2004-04-02
2
Medium Priority
?
354 Views
Last Modified: 2012-05-04
Hi,

I have a directory with drwx------ permissions.

Whenever I create a new find inside this directory, it has -rw-r--r-- permissions. I want it to be -rw------- by default.

Same with new directories that I create inside this dir: by default I want drwx------ instead of drwxr-xr-x.

Is there a way to change this?
I use tcsh.
Thanks!
0
Comment
Question by:slavikn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 14

Accepted Solution

by:
chris_calabrese earned 200 total points
ID: 10740722
Permissions on new files are set by the umask setting of the process creating the file, and not by any settings on the directory they're being created inside of.

To create flles that are -rw------- and directories that are drwx------, use 'umask 077'. You can issue this command directly from the command-line in the shell, or in a startup file such as .login/.profile.
0
 
LVL 1

Author Comment

by:slavikn
ID: 10740949
Thanks.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A metadevice consists of one or more devices (slices). It can be expanded by adding slices. Then, it can be grown to fill a larger space while the file system is in use. However, not all UNIX file systems (UFS) can be expanded this way. The conca…
Using libpcap/Jpcap to capture and send packets on Solaris version (10/11) Library used: 1.      Libpcap (http://www.tcpdump.org) Version 1.2 2.      Jpcap(http://netresearch.ics.uci.edu/kfujii/Jpcap/doc/index.html) Version 0.6 Prerequisite: 1.      GCC …
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Suggested Courses

609 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question