- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: homedir permission
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 10:37 AM
06-06-2002 10:37 AM
homedir permission
I set up umask as 027 within the /etc/profile. But why when I create a new user, its home directory permission is 755?
But any directories I created under this homedir, the permission is the same as what I think, 750...
Crystal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 10:40 AM
06-06-2002 10:40 AM
Re: homedir permission
How are you creating the user?
The creation process is setting permissions on the home directory without regard to your umask.
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 11:35 AM
06-06-2002 11:35 AM
Re: homedir permission
Before adding the users, check the umask with:
# umask
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 11:39 AM
06-06-2002 11:39 AM
Re: homedir permission
I put the umask in /etc/profile as 027 and logged out and logged on...
Then ran the command "useradd -m test", and check the permission of /home/test, it is
drwxr-xr-x.
I tried several systems and they gave me the same result...
Crystal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 11:45 AM
06-06-2002 11:45 AM
Re: homedir permission
I did another test:
1.Change the umask from 027 to 022 in /etc/profile, log out and log on.
2. useradd -m testnew
3. the new homedir is the same 755
If it is true that no matter what the umask is, it won't change the home directory's permission.
Now my question is :
Can I change this defaul setting to make the new created homedir 750?
Tx, Crystal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 11:46 AM
06-06-2002 11:46 AM
Re: homedir permission
Did you try creating with sam ? are you getting the same result there ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 11:47 AM
06-06-2002 11:47 AM
Re: homedir permission
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 11:50 AM
06-06-2002 11:50 AM
Re: homedir permission
# umask ( display current umask)
During my test, the HOME directory was created depend on the umask. So I believe the same.
Setting permission to $HOME directories is up on your wish. But if you share the same HOME directory with another user/group, then set the permission accordingly. To change permission:
# chmod
# chown
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 12:10 PM
06-06-2002 12:10 PM
Re: homedir permission
You have to be careful using useradd because it also does a "chown -R" to change the ownership of the files in the home directory.
I had an SA who set up a pseudo root account with / as his home directory. All the files on the system were subsequently owned by him. This was a pop3 mail server. Mail delivery was broken until I restored the files to their proper owners.
Marty
P.S. The SA now has a nickname of "chown boy".
:-)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 12:35 PM
06-06-2002 12:35 PM
Re: homedir permission
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 12:46 PM
06-06-2002 12:46 PM
Re: homedir permission
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 12:53 PM
06-06-2002 12:53 PM
Re: homedir permission
I think the last question was for me. Yes, I checked it during that time and found SAM uses this command/script for adding user, create home directory, copy files from /etc/skel etc:
/usr/sam/lbin/upusrfiles
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 01:02 PM
06-06-2002 01:02 PM
Re: homedir permission
After the "chown boy" incident, we have frowned upon using useradd and use SAM to create new users. The only problem we have with SAM is creating accounts with duplicate UIDs.
We use duplicate UIDs (including the use of UID 0 - pseudo root) for auditing purposes. It is not recommended by HP, but auditing wants accountability. What auditing wants, auditing gets.
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2002 06:16 PM
06-06-2002 06:16 PM
Re: homedir permission
This is really intresting.
Martin: I had same problem with you.
Why I raised the issue here is because I used the SAM to create a new id which is exactly the same as another account "ftp". After I created the account, I got a problem. The new account took over the "ftp" account, which means "ftp" was replaced by the new account name. This was not what I expected. Others cannot use "ftp" login name at that moment....
I did some investigation and found that if I ran the command useradd with the option -o, I could get the problem fixed. Tow duplicate accounts can exist on the system. So,I ran it. Unfortunately, I got a new problem, because the ftp account is required to have 555 permission for its home directory. When I checked the permission of ftp homedir, it was changed to 755. "ftp" couldn't be used again.
Guess what? The problem mentioned above happened on a trusted machine. When I tested it on an untrusted machine, the ftp home directory permission wasn't changed and the ftp account could be used.
I was thinking that was because of umask setting. Actually, it is not related...
It really made me confused...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-07-2002 07:27 AM
06-07-2002 07:27 AM
Re: homedir permission
"man sam" should tell you how.
I can't remember the exact procedures. I set it up years ago.
Generally. I have a file called /etc/sam/custom.tasks
It has one line:
UG_ADD_USER POST /etc/sam/doprofile
/etc/sam/doprofile is my profile customization script.
If you need more help email me and I will give you samples and procedures.
Rory
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-07-2002 08:09 AM
06-07-2002 08:09 AM
Re: homedir permission
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-07-2002 09:30 AM
06-07-2002 09:30 AM
Re: homedir permission
In our shop we recognized that using NFS to cross-mount filesystems would raise huge issues if we didn't enforce uniqueue UID NOs.
I built a script that nightly gathers every NIS server's /etc/passwd file and those of a few critical servers that don't use NIS. The script massages the aggregate password files and produces a UID.REGISTER file. Errors are emailed to the root recipients of each platform that identify UID collisions and handle(ie loginname) collisions.
We add users to each platform manually by assigning the next UID available by vi'g the UID.REGISTER file and entering the placeholder which "reserves" the new UID. Then we simply create the user's /etc/passwd entry, add the user to any groups (except their default group), make their IAP(home account), setting the permissions and ownerships and finally set the user's initial password.
We have a similar need to control our GIDs but this is an issue we haven't tackled yet
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-07-2002 11:06 AM
06-07-2002 11:06 AM
Re: homedir permission
How about a little encouragement? Assign some points!
:-)
Marty