Sponsored Content
Top Forums Shell Programming and Scripting Permission error when "touch"ing file with different user Post 303028944 by stomp on Friday 18th of January 2019 06:53:12 AM
Old 01-18-2019
Hi anaigini45,

you set extended permissions for the directory - but not for the files(You'l see that if you look at getfacl yourfile). The directory permissions are not inherited to the file. If you want to have it that way, you must set the extended permissions in some way.

Regards,
Stomp

--- Post updated at 12:53 PM ---
Anyway: You did not mention anything about your environment. Help could be more useful with details about that. My local version of setfacl does not support an -s option.

My setfacl here says it is possible to use the -d option to specify a default acl, which is used for any element, created in that directory. This may help you. Have a look into your manpage of setfacl.(I can not help you with other unices than linux here anyway).


Quote:
Originally Posted by RudiC
and added the "solved" tag.

To me this thread is not solved.

Last edited by stomp; 01-18-2019 at 08:08 AM..
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

"vi"-ing a constantly updated file

Hi, A bit of a dumb question here. Sorry folks. Suppose I have this file which is being updated at irregular intervals (a few seconds, a few minutes, who knows) by a background process. I 'vi' this file with the intention of editing it, so it opens up a temp copy as the usual... (8 Replies)
Discussion started by: Percy
8 Replies

2. UNIX for Advanced & Expert Users

Command similar to "touch" for modify File size

Hi All, I'm trying to find a command like similar to "touch" which would let me change the file size property. For ex: I have a file of size 1MB using the command i would like to set/update the size something like 1KB. Is it possible? Is there any such command which would accomplish this... (3 Replies)
Discussion started by: sriharshareddyk
3 Replies

3. Shell Programming and Scripting

Ignore "a line" within /etc/profile only when su'ing

Is there a way to ignore a command within /etc/profile only when su'ing as any particular user. For instance.... As root, if I run "su - oracle -c program" it is running a string in my profile called "echo "^2;$(hostname)-(ABC) @ $(who am i)^G". I don't want the above string to run if I... (9 Replies)
Discussion started by: lwif
9 Replies

4. UNIX for Dummies Questions & Answers

changing password with sudo user " permission denied"

HI All, I am using solaris i created a user adam and updated his permissions in vi sudoers file as follows adam ALL=(ALL) NOPASSWORD: ALL ........... when i create user by logging as sudo user . $ sudo useradd -d /home/kalyan -m -s /bin/sh kalyan sudo: not found ... (6 Replies)
Discussion started by: kalyankalyan
6 Replies

5. Shell Programming and Scripting

awk command to replace ";" with "|" and ""|" at diferent places in line of file

Hi, I have line in input file as below: 3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL My expected output for line in the file must be : "1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL" Can someone... (7 Replies)
Discussion started by: shis100
7 Replies

6. UNIX for Dummies Questions & Answers

Unix "look" Command "File too large" Error Message

I am trying to find lines in a text file larger than 3 Gb that start with a given string. My command looks like this: $ look "string" "/home/patrick/filename.txt" However, this gives me the following message: "look: /home/patrick/filename.txt: File too large" So, I have two... (14 Replies)
Discussion started by: shishong
14 Replies

7. UNIX for Dummies Questions & Answers

What is the significance of sh -s in ssh -qtt ${user}@${host} "sh -s "${version}"" < test.sh?

Please can you help me understand the significance of providing arguments under sh -s in > ssh -qtt ${user}@${host} "sh -s "${version}"" < test.sh (4 Replies)
Discussion started by: Sree10
4 Replies

8. UNIX for Dummies Questions & Answers

Using "mailx" command to read "to" and "cc" email addreses from input file

How to use "mailx" command to do e-mail reading the input file containing email address, where column 1 has name and column 2 containing “To” e-mail address and column 3 contains “cc” e-mail address to include with same email. Sample input file, email.txt Below is an sample code where... (2 Replies)
Discussion started by: asjaiswal
2 Replies

9. Shell Programming and Scripting

Bash script - Print an ascii file using specific font "Latin Modern Mono 12" "regular" "9"

Hello. System : opensuse leap 42.3 I have a bash script that build a text file. I would like the last command doing : print_cmd -o page-left=43 -o page-right=22 -o page-top=28 -o page-bottom=43 -o font=LatinModernMono12:regular:9 some_file.txt where : print_cmd ::= some printing... (1 Reply)
Discussion started by: jcdole
1 Replies

10. UNIX for Beginners Questions & Answers

How to run root level command , if user has "su -" permission in sudoers provided?

I am looking t run root level command on multiple servers, but all servers have only "su - " permission available in sudoers. please help me if any way that I can run command using help of "su -" My script for hosts in `cat hosts.txt`; do echo "###########################Server Name-... (5 Replies)
Discussion started by: yash_message
5 Replies
GETFACL(1)						    BSD General Commands Manual 						GETFACL(1)

NAME
getfacl -- get ACL information SYNOPSIS
getfacl [-dhinqv] [file ...] DESCRIPTION
The getfacl utility writes discretionary access control information associated with the specified file(s) to standard output. If the getconf(1) utility indicates that {_POSIX_ACL_EXTENDED} is not in effect for a file then the standard discretionary access permissions are interpreted as an ACL containing only the required ACL entries. The following option is available: -d The operation applies to the default ACL of a directory instead of the access ACL. An error is generated if a default ACL cannot be associated with file. This option is not valid for NFSv4 ACLs. -h If the target of the operation is a symbolic link, return the ACL from the symbolic link itself rather than following the link. -i For NFSv4 ACLs, append numerical ID at the end of each entry containing user or group name. Ignored for POSIX.1e ACLs. -n Display user and group IDs numerically rather than converting to a user or group name. Ignored for POSIX.1e ACLs. -q Do not write commented information about file name and ownership. This is useful when dealing with filenames with unprintable char- acters. -v For NFSv4 ACLs, display access mask and flags in a verbose form. Ignored for POSIX.1e ACLs. The following operand is available: file A pathname of a file whose ACL shall be retrieved. If file is not specified, or a file is specified as -, then getfacl reads a list of pathnames, each terminated by one newline character, from the standard input. For an explanation of the ACL syntax, see the setfacl(1) manual page. EXIT STATUS
The getfacl utility exits 0 on success, and >0 if an error occurs. EXAMPLES
getfacl / Retrieve ACL for the directory /. getfacl -d / Retrieve the default ACL for the directory /, if any. SEE ALSO
setfacl(1), acl(3), getextattr(8), setextattr(8), acl(9), extattr(9) STANDARDS
The getfacl utility is expected to be IEEE Std 1003.2c compliant. HISTORY
Extended Attribute and Access Control List support was developed as part of the TrustedBSD Project and introduced in FreeBSD 5.0. AUTHORS
Robert N M Watson BSD
September 4, 2009 BSD
All times are GMT -4. The time now is 05:28 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy