Chinaunix首页 | 论坛 | 博客
  • 博客访问: 421467
  • 博文数量: 125
  • 博客积分: 2838
  • 博客等级: 少校
  • 技术积分: 1410
  • 用 户 组: 普通用户
  • 注册时间: 2010-08-05 09:45
文章分类

全部博文(125)

文章存档

2012年(13)

2011年(5)

2010年(107)

我的朋友

分类: LINUX

2010-08-05 11:45:27

Using /etc/skel

/etc/skel to ensure that all new users on your system get the same initial settings.

The /etc/skel directory is the directory used by useradd to create the default settings in a new user's home directory.

To change the location of /etc/skel, edit /etc/default/useradd.

Code Listing 7.1

# useradd defaults file
GROUP=100
HOME=/home
INACTIVE=-1
EXPIRE=
SHELL=/bin/bash
SKEL=/etc/skel

Typically files included in /etc/skel are .rc files for shell initialization, but you could also include a public_html directory, a custom dircolors file, or anything else.

Code Listing 7.2

% ls -A /etc/skel
.bash_profile  .bashrc  .maildir  .screenrc  .tcsh.config
阅读(1047) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~