Ubuntu常用操作-杂记

  • 笔记本关闭盒盖睡眠
sudo nano /etc/systemd/logind.conf

找到 #HandleLidSwitch=suspend,修改为

HandleLidSwitch=ignore
  • 安装ssh服务
sudo apt update
sudo apt install openssh-server

默认情况root用户无法直接连接,需修改配置并重启服务

# /etc/ssh/sshd_config
PermitRootLogin yes

重启:

systemctl restart sshd
  • kvm web管理端
sudo apt install cockpit cockpit-machines
sudo systemctl start cockpit

个性化配置

  • 网卡驱动

当网卡为Realtek RTL8101E/RTL8102E/RTL8103E/RTL8105E/RTL8106E/RTL8107E FE 100M网卡时(例如Dell灵越14R
-,ubuntu或openmediavault等debian系统中的驱动默认为r8169,这会产生一些诡异的问题(例如:无法连接网络,无法获取dhcp,网速慢等),所以需要重装网卡驱动。参考链接:

https://github.com/ghostrider-reborn/realtek-r8101-linux-driver
https://gitee.com/rily/realtek-r8101-linux-driver