我使用默认的 vino-server 包通过 VNC 访问我的 CentOS 6 工作站。
它工作正常,但只有在我本地登录工作站之后。我需要在登录之前启动 vino-server,就在我选择用户名和密码的 Gnome 登录屏幕上。
由于个人原因,我需要使用 Vino 而不是 vnc-server 或任何其他软件包。
我已经尝试插入/usr/libexec/vino-server &,/etc/gdm/Init/Default但这并没有解决问题。
创建将启动vino 的桌面文件:
# cat > /usr/share/gdm/autostart/LoginWindow/vino-server.desktop << 'EOF'
[Desktop Entry]
Name=Remote Desktop
Comment=GNOME Remote Desktop Server
Exec=/usr/libexec/vino-server
Icon=preferences-desktop-remote-desktop
Terminal=false
Type=Application
EOF
Run Code Online (Sandbox Code Playgroud)
为gdm用户更改vino的一些设置1(vino在其下运行):
# su -s /bin/sh -l gdm -c \
'gconftool-2 --set --type=bool \
/desktop/gnome/remote_access/enabled true'
# su -s /bin/sh -l gdm -c \
'gconftool-2 --set --type=bool \
/desktop/gnome/remote_access/prompt_enabled false'
Run Code Online (Sandbox Code Playgroud)
请注意,您所能做的就是登录。用户登录后,VNC 会话结束。会话结束时,您将能够重新连接到 GDM。
您还需要禁用 SELinux 2或者最好编写所需的规则以让用户gdm运行vino-server。
1我从“从命令行启用远程 VNC?”的答案中获得了详细信息。来自询问 Ubuntu SE。
2修改/etc/selinux/config为SELINUX=permissive或使用setenforce。
| 归档时间: |
|
| 查看次数: |
12735 次 |
| 最近记录: |