下载后可任意编辑编写 shell 管理脚本:shell 的作用:Shell 是一个特别的应用程序,它介于操作系统内核与用户之间,负责接收用户输入的操作指令并进行解释,将需要执行的操作传递给内核执行
Shell 程序有很多种,windows 里的 cmd
exe 也是 shell 的一种
在 linux/unix 操作系统中,能够使用的 shell 程序有很多种,常见的 shell 如下:Bsh:早期的 unix shell 程序,实现了最基本的命令解释其功能
Csh:使用 C 语言的语法风格,更加适合为用户提供命令交互操作
Ksh:结合了 bsh 和 csh 两者的功能优势
Bash:是 bsh 的升级替代品,目前大多数 linux 默认的 shell 程序
Zsh:更多的基于交互式操作系统考虑设计
Shell 环境的切换:通过配置文件/etc/shells 可以了解系统所支持的 shell 程序的路径
查看当前 linux 系统中能够使用的 shell 程序的列表:[root@localhost ~]# cat /etc/shells/bin/sh/bin/bash/sbin/nologin/bin/dash/bin/tcsh/bin/csh[root@localhost ~]#有一部分 shell 程序实际上是其他 shell 程序的符号链接文件:[root@test ~]# ls -l /bin/*sh-rwxr-xr-x
1 root root 938832 Jul 18 2024 /bin/bashlrwxrwxrwx
1 root root 4 Jun 24 22:11 /bin/csh -> tcsh (tcsh 是 csh 的兼容升级版本)-rwxr-xr-x
1 root root 109672 Oct 17 2024 /bin/dashlrwxrw