Ubuntu18.04关闭图形显示以减少图形界面对显卡的显存占用

有时我们需要训练使用显存,有时候显存太小以至于不能训练,于是我们可以关闭桌面显示器来充分利用GPU的显存

参考: How to disable GUI on boot in 18.04 (Bionic Beaver)?

  • 关闭GUI的开机启动,通过运行:
sudo systemctl set-default multi-user.target
  • 如果想要开启GUI的开机启动,通过运行:
sudo systemctl set-default graphical.target
  • 开始Gnome session在系统中没有GUI的时候:
sudo systemctl start gdm3.service

上述命令重启后生效

猜你喜欢

转载自blog.csdn.net/qq_31261509/article/details/90317331