赞
踩
startxfce4
在使用xserver时往往会报:
cannot open /dev/tty0 (permission denied)
添加所在用户到tty组中
gpasswd -a 用户名 tty
还不行的话试一下下面的方法:
vim /etc/X11/Xwrapper.config
里面原来内容如下:
allowed_users=anybody
needs_root_rights=yes
改为(在=前后加上空格):
allowed_users = anybody
needs_root_rights = yes
关于出现:
xf86OpenConsole: Cannot open virtual console 2 (Permission denied)
尝试:
sudo chown 用户名 /dev/tty2
xf86OpenConsole: Cannot open virtual console 2 (Permission denied)
关于出现:
xf86EnableIOPorts: failed to set IOPL for I/O (Function not implemented)
Fatal server error:
no screens found
提示找不到显示器,可能是~/.bashrc(如果安装了zsh则为~/.zshrc)下的DISPLAY参数配置错了,
wsl1应该为:
export DISPLAY=localhost:自定义端口
wsl2应该为:
export DISPLAY=`cat /etc/resolv.conf | grep nameserver | awk '{print $2}'`:自定义端口
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。