ITPub博客

首页 > Linux操作系统 > Linux操作系统 > Not copying any file from skel directory into it.

Not copying any file from skel directory into it.

原创 Linux操作系统 作者:zjrodger 时间:2013-05-06 00:02:54 0 删除 编辑

在RHEL 5或CentOS5中安装oracle11g时,

groupadd oinstall

groupadd dba

mkdir -p /u01/oracle ( /u01/oracle 就在这里安装Oracle 11g)

建立用户:

useradd -g oinstall -G dba -d /u01/oracle oracle

结果报错:

useradd: warning: the home directory already exists.

Not copying any file from skel directory into it.

进入/u01/oracle目录,没有.bash_profile’,.bashrc,bash_logout

原因:

系统添加用户的标准步骤

1.编辑/etc/passwd与/etc/group

2.创建用户主目录

3.从/etc/skel拷贝文件与目录

4.让新用户获得其主目录与文件的拥有权限

5.给新用户一个密码

解决办法:

依旧使用上面的脚本建用户,然后手动拷贝配置文件到/u01/oracle下。

cp /etc/skel/.bash_profile /u01/oracle

cp /etc/skel/.bashrc /u01/oracle

cp /etc/skel/.bash_logout /u01/oracle

这样既可。

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/25851087/viewspace-759794/ ,如需转载,请注明出处,否则将追究法律责任。

上一篇: 没有了~
请登录后发表评论 登录
全部评论

注册时间:2013-04-14

  • 博文量
    42
  • 访问量
    560424