How to add a user and set environments for the user?
2008-06-01 14:48
721 查看
1. How to add a user and login with new user in Solaris?
#bash
#groupadd users
#useradd -d /export/home/robert -m -g users robert
Keep in root user
#passwd robert
#chown -R robert:users /export/home/robert
Notes, you must change the ower of the home directory. Otherwise you can't login JDS correctly with this user.
You can add the user with smc, the command is /usr/sadm/bin/smc &
Please also refer to http://publish.it168.com/2007/0510/20070510002004.shtml
2. How to set the environment variants for a user?
1) (In process level) Add the scripts of export into the start shell script.
2) (In user level) Add the scripts of export into the .profile in user home directory.
3) (In global level) Add the scripts of export into the /etc/profiie.
Note, please note that you must add the scripts of export into the specific file directory. Don't encapsulate them in a shell, and invoke the shell in profile. Because environment works inside its process or its child processes.
3. References,
http://bbs.chinaunix.net/archiver/?tid-1034081.html
http://topic.csdn.net/t/20061120/10/5170346.html
http://blog.csdn.net/hotsolaris/archive/2008/05/14/2443685.aspx
#bash
#groupadd users
#useradd -d /export/home/robert -m -g users robert
Keep in root user
#passwd robert
#chown -R robert:users /export/home/robert
Notes, you must change the ower of the home directory. Otherwise you can't login JDS correctly with this user.
You can add the user with smc, the command is /usr/sadm/bin/smc &
Please also refer to http://publish.it168.com/2007/0510/20070510002004.shtml
2. How to set the environment variants for a user?
1) (In process level) Add the scripts of export into the start shell script.
2) (In user level) Add the scripts of export into the .profile in user home directory.
3) (In global level) Add the scripts of export into the /etc/profiie.
Note, please note that you must add the scripts of export into the specific file directory. Don't encapsulate them in a shell, and invoke the shell in profile. Because environment works inside its process or its child processes.
3. References,
http://bbs.chinaunix.net/archiver/?tid-1034081.html
http://topic.csdn.net/t/20061120/10/5170346.html
http://blog.csdn.net/hotsolaris/archive/2008/05/14/2443685.aspx
相关文章推荐
- How to add a user and set environments for the us
- How to fix the issue that GEM_HOME and/or GEM_PATH not set issue for rvm in mac version 10.12
- How to create fully custom Role, User, Event, Resource classes for use with the Security and Scheduler modules
- How to set bmp for your UserControl in the toolbox
- How to Use JSONKit for iOS and the Rotten Tomatoes API
- The robot API &&How to add and use sensor.
- How To List All The Named Events Set For A Database [ID 436036.1]
- How to enable USB selective suspend and system wake in the UMDF driver for a USB device
- 如何设置Java桌面程序界面外观(How to Set the Look and Feel)
- how to set a user-defined process as the system key process
- How to add a new user in linux and add it to a new group
- ABAP code to find all the User Exits and BADIs for any transaction
- How to get and set the system socket buffer in AIX?
- PHP executable not found. Install PHP 7 and add it to your PATH or set the php.executablePath s
- How to switch a photo from jpg to png, and how to resize the photo for mac?
- How to add a user to the sudoers list
- How to Modify the Password for SYSMAN and other Enterprise Manager Users at the OMS Level and Reposi
- 如何设置Java桌面程序界面外观(How to Set the Look and Feel)
- [原] XAF How to see and edit the time part in the DatePropertyEditor for the System.DateTime property
- How to separate the implementation and definition for template function in c++