20250204将Ubuntu22.04的默认Dash的shell脚本更换为bash

20250204将Ubuntu22.04的默认Dash的shell脚本更换为bash

2025/2/4 23:45

百度:dash bash

https://blog.csdn.net/2201_75772333/article/details/136955776

【Linux基础】dash和bash简介

Dash(Debian Almquist Shell)和 Bash(Bourne Again Shell)是 Unix/Linux 系统中的命令行 shell,用于执行命令、管理文件系统、编写脚本等任务的工具。

Dash 作为一个轻量级的 shell,在某些特定的场景下具有优势,尤其是在需要追求速度和资源效率的环境中。然而,在需要更多功能和灵活性的情况下,可能会选择更复杂的 shell,如 Bash。在启动脚本中或需要追求性能的系统中。

五、dash和bash的切换

将Ubuntu shell环境修改为bash,

#选择No,将Ubuntu shell由dash修改为bash

sudo dpkg-reconfigure dash

rootroot@rootroot-HP-245-14-inch-G10-Notebook-PC:~$

rootroot@rootroot-HP-245-14-inch-G10-Notebook-PC:~$ ll /bin/sh

lrwxrwxrwx 1 root root 4 2月 3 22:33 /bin/sh -> bash*

rootroot@rootroot-HP-245-14-inch-G10-Notebook-PC:~$

rootroot@rootroot-HP-245-14-inch-G10-Notebook-PC:~$

Step 2. Set bash as default shell tool.

$ sudo rm /bin/sh

$ sudo ln -sf /bin/bash /bin/sh

相关推荐
walkskyer19 分钟前
使用 Golang `testing/quick` 包进行高效随机测试的实战指南
开发语言·后端·golang
南瓜胖胖28 分钟前
【R语言编程绘图-mlbench】
开发语言·机器学习·r语言
Rousson44 分钟前
硬件学习笔记--65 MCU的RAM及FLash简介
开发语言·前端·javascript
慧都小妮子1 小时前
跨平台浏览器集成库JxBrowser 支持 Chrome 扩展程序,高效赋能 Java 桌面应用
开发语言·python·api·jxbrowser·chrome 扩展程序
范纹杉想快点毕业1 小时前
C++多重继承详解与实战解析
开发语言·c++
shenyan~1 小时前
关于 smali:2. 从 Java 到 Smali 的映射
java·开发语言
天桥下的卖艺者1 小时前
R语言使用随机过采样(Random Oversampling)平衡数据集
开发语言·r语言
星star~1 小时前
MyBatis相关面试题
java·开发语言·mybatis
MABO-mb1 小时前
Java实现命令行图书管理系统(附完整源码)
java·开发语言