diff --git a/Software/Development/System/Linux/User/Linux_常用目录_文件集合.md b/Software/Development/System/Linux/User/Linux_常用目录_文件集合.md index b57a204..d5233ad 100644 --- a/Software/Development/System/Linux/User/Linux_常用目录_文件集合.md +++ b/Software/Development/System/Linux/User/Linux_常用目录_文件集合.md @@ -5,6 +5,7 @@ | /etc/systemd/system | Systemd 服务配置目录 | | /lib/firmware | 设备固件目录,该目录下保存着设备运行时所需的固件程序 | | /lib/systemd/system | Systemd unit files 一般指向 /usr/lib/systemd/system | +| /proc/sys/net/ipv4/conf | 可在该目录下查看创建的和已经存在的网卡设备文件 | | /sys/class/drm/card\-\-\/status | 显示设备状态 | | /sys/class/drm/card\-\-\/modes | 显示设备所支持的显示模式 | | /sys/class/drm/card\-\-\/edid | 如果包含 EDID,此节点为映射的 EDID 文件| diff --git a/Software/System/Linux/Modules/Network/Linux_网络配置.md b/Software/System/Linux/Modules/Network/Linux_网络配置.md index 8728be5..b9bd2c8 100644 --- a/Software/System/Linux/Modules/Network/Linux_网络配置.md +++ b/Software/System/Linux/Modules/Network/Linux_网络配置.md @@ -162,3 +162,21 @@ sudo systemctl restart networking.service ``` 一般而言,/etc/resolv.conf 文件是个软链接,其配置比较复杂,推荐使用 resolvconf 工具进行配置。 + +## 桥接 + +```bash +# Create a new bridge and change its state to up +ip link add name type bridge +ip link set up +# To add an interface (e.g. eth0) into the bridge, its state must be up +ip link set up +ip link set master +# Show the existing bridges and associated interfaces +bridge -d link +# OR +brctl show +# This is how to remove an interface from a bridge +ip link set nomaster +ip link delete type bridge +```