Linux chsh命令

时间:2023年06月09日 阅读:123
以下内容仅是站长或网友个人学习笔记、总结和研究收藏。不保证正确性,因使用而带来的风险与本站无关!
淘客轩-衣食住行外卖生活好助手

Linux chsh命令

Linux 命令大全

Linux chsh命令用于更改使用者 shell 设定。

使用权限:所有使用者。

语法

shell>> chsh

在线示例

shell>> chsh
Changing fihanging shell for user1
Password: [del]
New shell [/bin/tcsh]: ### [是目前使用的 shell]
[del]
shell>> chsh -l ### 展示 /etc/shells 档案内容
/bin/bash
/bin/sh
/bin/ash
/bin/bsh
/bin/tcsh
/bin/csh

改变当前的shell。当前的shell 设置为//bin/bash,通过chsh命令,改变shell的设置/bin/csh。

# chsh
Changing shell for root.
New shell [/bin/bash]: /bin/csh //输入新的shell地址
Shell changed.

通过 -s 参数改变当前的shell设置

# chsh -s /bin/csh //改变当前设置为 /bin/csh
Changing shell for root.
Shell not changed.

Linux 命令大全

打赏
标签: Linux chsh命令

本文地址:https://www.momojc.cn/linux/linux-comm-chsh.html

上一篇:Linux uname 命令
下一篇:Linux userconf命令

关于本站 | 隐私政策 | 免责声明 | 广告合作 | 我要投稿 | 后台管理

CopyRight © 2023-2024 MOMO教程 WWW.MOMOJC.CN , All Rights Reserved.

站长E-mail:378074730@qq.com 网站已运行:  运行时长:0.028 秒

京ICP备20029690号-1京ICP备20029690号-2 京公网安备11011402013892号京公网安备11011402013892号 中国互联网违法和不良信息举报中心 网络违法犯罪举报网站

本网站托管于 腾讯云 .由网站卫士提供网站加速和攻击防御服务 提供CDN加速/防御服务.由zblogcn强力驱动 又拍云提供CDN加速/云存储服务 51la网站统计