LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS
User Name
Password
CentOS This forum is for the discussion of CentOS Linux. Note: This forum does not have any official participation.

Notices


Reply
  Search this Thread
Old 03-31-2017, 05:31 PM   #1
jimb.smith
LQ Newbie
 
Registered: Mar 2017
Posts: 4

Rep: Reputation: Disabled
Can't automatically create an empty directory when new user is created.


So i'm trying to make it so when I create a new user either by using useradd or adduser, an empty directory named "whatever" is automatically created under that users home directory.

I've tried playing around with the /etc/default/useradd config file but no luck.

I'm not trying to change every new users home directory but rather just have an empty directory automatically be created the same time a new user is created.
 
Old 03-31-2017, 06:58 PM   #2
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
Add it to /etc/skel/.
 
Old 04-02-2017, 11:02 AM   #3
jimb.smith
LQ Newbie
 
Registered: Mar 2017
Posts: 4

Original Poster
Rep: Reputation: Disabled
Thanks, that was exactly what I was looking for.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
No ~/Maildir created automatically with Webmin and ISPConfig. User = root rlj4214 Linux - Server 4 12-12-2014 08:31 PM
Create SFTP only user and allow access to already created directory amitpatil Linux - Server 10 06-05-2013 04:12 AM
changing home directory permission in user management after user created in suse(KDE) hamedhsn Linux - Security 4 04-06-2011 09:18 PM
Created user in Webmin - how to lock that user in specified directory? guest Linux - Security 1 04-18-2009 07:21 PM
Samba: automatically create a domain user's home directory sfoo Linux - Newbie 1 03-04-2008 03:26 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS

All times are GMT -5. The time now is 05:21 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration