mirror of
https://gitee.com/callmer/pve_toss_notes.git
synced 2026-08-31 22:12:51 +08:00
更新文档
This commit is contained in:
@@ -388,3 +388,26 @@ $ sudo systemctl restart apt-daily-upgrade.timer
|
|||||||
$ sudo systemctl status apt-daily-upgrade.timer
|
$ sudo systemctl status apt-daily-upgrade.timer
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### 1.8.配置防火墙
|
||||||
|
|
||||||
|
修改防火墙配置之前,需检查 `nftables.service` 服务状态,确保该服务开机自启。
|
||||||
|
|
||||||
|
```bash
|
||||||
|
## 检查 nftables.service
|
||||||
|
$ sudo systemctl status nftables.service
|
||||||
|
|
||||||
|
## 设置 nftables.service 开机自启
|
||||||
|
$ sudo systemctl enable nftables.service
|
||||||
|
```
|
||||||
|
|
||||||
|
使用 `neovim` 编辑器修改 `nftables` 配置文件,执行以下命令。
|
||||||
|
|
||||||
|
```bash
|
||||||
|
## 备份 nftables 配置文件
|
||||||
|
$ sudo mv /etc/nftables.conf /etc/nftables.conf.bak
|
||||||
|
|
||||||
|
## 创建新的 nftables 配置文件
|
||||||
|
$ sudo nvim /etc/nftables.conf
|
||||||
|
```
|
||||||
|
|
||||||
|
由于防火墙配置文件很长,因此请查阅文件 [debian_ts_nftables.conf](./src/debian/debian_ts_nftables.conf) 进行复制。
|
||||||
Reference in New Issue
Block a user