Open a terminal and type following command to enable the remote desktop:
$ gconftool-2 -s -t bool /desktop/gnome/remote_access/enabled true
To disable the “Ask for Confirmation” dialog
$ gconftool-2 -s -t bool /desktop/gnome/remote_access/prompt_enabled false
If you check
System -> Preferences -> Remote Desktop
you will see that it is now turned ON.
You can turn it back OFF again from the command line using this command:
$ gconftool-2 -s -t bool /desktop/gnome/remote_access/enabled false
Now login to your Linux system from SSH & by using above commands, enable or disable the remote desktop.
Once you do that, you can use VNC Viewer from the remote machine to access the gui of your linux system.
11 thoughts on “Configure Remote Desktop from Command Line”
what command for kde desktop ?
I don’t know the command for kde, but i will let you know when i will find it.
thanks for effective article! your online site is exceptionally useful for me. i bookmarked your online site!
Pingback: Configure Remote Desktop from Command Line | Linux Explore
your instrtuctions on turnign off the confirmation is wrong it should be set to “false” thanks you
Thanks for reporting :), issue fixed.
I have RHL5 Client. The values are accepted but VNC connection is been rejected. I also have KDE instead of gnome. Any help is appreciated.
Please check that remote desktop is enabled as showing in this post. If it is enabled, Please check your iptables, it may be on which is denying vnc connection request.
KDE does not have the menuu choice to enable Remote Desktop. I have found the command line way to set it, but it still doesn’t work. We also have RHL5 Server which have Gnome running, so I can se the Remote Desktop screen. I eventually resort to use x0vncserver, which is not that great because of a few limitation but it’s working.
You are right, KDE does not have this option. This is gnome specific command.
Just use the command: vino-preferences after ssh