
git-svn-id: svn+ssh://atelier.inf.usi.ch/home/bevilj/group-1@292 a672b425-5310-4d7a-af5c-997e18724b81
54 lines
2 KiB
HTML
54 lines
2 KiB
HTML
---
|
|
layout: page
|
|
category-page: intermediate
|
|
category-title: Intermediate commands
|
|
author: Joy Albertini
|
|
tags: directory user shell
|
|
title: chsh
|
|
previous-page: pages/cmd/interm/chroot.html
|
|
next-page: pages/cmd/interm/cowsay.html
|
|
---
|
|
|
|
The <code>chsh</code> command can be used to change the following user's login shell properties:
|
|
|
|
<ul>
|
|
<li>chenage Password of the user</li>
|
|
<li> shell local directory</li>
|
|
<li>Full name of the user</li>
|
|
<li>Office location</li>
|
|
<li>Office phone</li>
|
|
<li>home phone </li>
|
|
</ul>
|
|
|
|
<pre>
|
|
chsh [-flag] user
|
|
</pre>
|
|
|
|
<h3>Flags</h3>
|
|
|
|
<ul>
|
|
<li><b>-s</b>: set shell as the login shell</li>
|
|
<li><b>-l</b>: change the symbolic link and not the file or directory referred
|
|
by the symbolic link.
|
|
</li>
|
|
<li><b>-R</b>: change the ownership for each file in a folder, if encounter symbolic link
|
|
it will change the owenership of that symbolic link,
|
|
and the directory/file referred in the symbolic link, but the directory
|
|
is not further transversed.
|
|
</li>
|
|
<li><b>-RH</b>: change the ownership for each file in a folder, if a symbolic link is
|
|
encountered, it will change the owenership of that symbolic link,
|
|
the directory/file referred in the symbolic link, and all the
|
|
directories are further transversed.
|
|
</li>
|
|
<li><b>-RL</b>: if a symbolic link referencing a file of type directory
|
|
is specified on the command line or encountered during the traversal of a file hierarchy,
|
|
the chown command will change the user ID (and group ID, if specified) of the directory
|
|
referenced by the symbolic link and all files in the file hierarchy below it.
|
|
</li>
|
|
<li><b>-RP</b>: changes the ownership for each file in a folder, if encounter symbolic link it
|
|
will change the owenership of that symbolic link, but will not change the
|
|
the directory/file referred in the symbolic link, and
|
|
the directory is not further transversed.
|
|
</li>
|
|
</ul>
|