mirror of
https://gitee.com/callmer/pve_toss_notes.git
synced 2026-08-31 22:12:51 +08:00
update 5.PVE配置模板虚拟机.md.
This commit is contained in:
@@ -397,4 +397,25 @@ Time to change your default shell to zsh:
|
|||||||
Do you want to change your default shell to zsh? [Y/n] y
|
Do you want to change your default shell to zsh? [Y/n] y
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### 1.10.清理系统
|
||||||
|
|
||||||
|
Debian 模板虚拟机已经配置完成,在将其转换为模板前需要对系统进行清理。
|
||||||
|
|
||||||
|
逐条执行以下命令,注意命令中的空格:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
## 清理系统软件包
|
||||||
|
sudo apt clean && sudo apt autoclean && sudo apt autoremove --purge
|
||||||
|
|
||||||
|
## 清理系统缓存
|
||||||
|
sudo rm -rvf /var/cache/apt/* /var/lib/apt/lists/* /tmp/*
|
||||||
|
|
||||||
|
## 清理系统日志
|
||||||
|
sudo find /var/log/ -type f |xargs sudo rm -rvf
|
||||||
|
|
||||||
|
## 清理命令历史记录文件
|
||||||
|
rm -rvf ~/.bash_history ~/.zsh_history
|
||||||
|
|
||||||
|
## 清理命令历史
|
||||||
|
history -c
|
||||||
|
```
|
||||||
|
|||||||
Reference in New Issue
Block a user