xrdp: VNC Problem connecting
Hi, I have xrdp 0.9.1 on ubuntu 16.04 and I want to connect to kvm vm via vnc using xrdp. When I’m connecting I get
VNC error - problem connecting
some error
Here is the log:
[20170531-09:28:33] [DEBUG] xrdp_wm_log_msg: VNC started connecting
[20170531-09:28:33] [DEBUG] xrdp_wm_log_msg: VNC connecting to localhost 5901
[20170531-09:28:36] [DEBUG] VNC error 1 after security negotiation
[20170531-09:28:36] [DEBUG] VNC error before sending share flag
[20170531-09:28:36] [DEBUG] VNC error before receiving server init
[20170531-09:28:36] [DEBUG] VNC error before receiving pixel format
[20170531-09:28:36] [DEBUG] VNC error before receiving name length
[20170531-09:28:36] [DEBUG] VNC error before receiving name
[20170531-09:28:36] [DEBUG] xrdp_wm_log_msg: VNC error - problem connecting
[20170531-09:28:36] [DEBUG] Closed socket 16 (AF_INET6 :: port 33870)
[20170531-09:28:36] [DEBUG] xrdp_wm_log_msg: some problem
[20170531-09:28:36] [ERROR] xrdp_wm_log_msg: Error connecting to: localhost
[20170531-09:28:36] [DEBUG] xrdp_mm_module_cleanup
[20170531-09:28:36] [DEBUG] VNC mod_exit
[20170531-09:28:36] [DEBUG] return value from xrdp_mm_connect 1
The vnc server should be working, because I was able to connect to it via vnc client.
Please may you help me?
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 4
- Comments: 36 (10 by maintainers)
[SOLVED]
I got the same error in CentOS 7.5 with Xfce desktop. I had struggled for several days with no result.
Recently, I found a solution coincidentally. I created a CentOS 7.5 virtual machine with “minimal” installation. Then I installed
xrdpand startedxrdpservice, without realizing that I didn’t have any desktop environment. When I attempted to connect the vm from my Windows, I got definitely the same error stated above.Soon, I found my stupid mistake, followed by a strange thing: whether installing a desktop environment or not,
xrdpalways throws the same error. I realized the cause of this issue is not a bug of xrdp, tigervnc-server or Xfce, but the fact that xrdp doesn’t know what desktop environment to start, let alone how to start. It’s the real problem, and we can fix it easily.Here were my steps:
Now, xrdp works perfectly with Xfce and openbox.
Finally, where did I get these names? like
~/.xsessionand~/.Xclients?Well, I found all these in the following scripts:
startwm.shXsessionXclientsFor example, the last part of
/etc/X11/xinit/Xsessionin CentOS 7.5 says:Apparently, X11 will search
$HOME/.xsessionand$HOME/.Xclientsfor desktop environments.Seems like this is related to issue #847
I had the same error and was able to get xrdp running on kali by simply moving to lxde.
Not ideal but better than nothing. Hope this helps someone like it helped me. 😃
Simplified from https://forums.kali.org/showthread.php?34751-How-to-set-up-xrdp-on-the-AWS-Kali-image
Not sure if this would apply for a lot of people, but I was having the following errors is log
Apparently the value -depth 8 was causing the error. Found out that my Windows RDP setting was getting set to “Low Bandwidth” setting and color depth was being set at 8. Changed to default 32 and issue was solved.
I reproduced the issue. Please wait patiently until the bug is fixed. Not to use VNC is a workaround.
Ubuntu 16.04.2 LTS xrdp 0.9.2
https://pastebin.com/u54NN1Wp Fedora 26 xrdp 0.9.3 firewall/selinux disabled
https://pastebin.com/fSSJgc9f On Ubuntu at least Xorg session is working On Fedora 26 i unsuccessfully tried xrdp 0.9.1, 0.9.2, 0.9.3 - Xorg or Xvnc sessions not working, at least for me. UPD: After some more experimenting I’ve found what causing this errors. Steps to reproduce(I’m using Fedora with “clean” MATE+Lightdm setup): Install fresh fedora server w/o GUI. $ sudo dnf groupinstall ‘base-x’ ‘fonts’ $ sudo dnf install mate-desktop mate-control-center mate-terminal mate-settings-daemon caja caja-open-terminal mate-polkit mate-session-manager lightdm-gtk lightdm mate-menus mate-themes mate-panel marco oddjob-mkhomedir xrdp xrdp-selinux $ sudo authconfig --enablemkhomedir --update With this setup I stumbled upon:
It is not sufficient to install xrdp-selinux package, you should patch, recompile and reinstall xrdp policy: $ cd /usr/share/doc/xrdp-selinux/ $ sudo cp xrdp.te{,.old} $ sudo cat << EOF > xrdp.patch
$ sudo patch xrdp.te xrdp.patch $ sudo checkmodule -M -m -o xrdp.mod xrdp.te $ sudo semodule_package -o xrdp.pp -m xrdp.mod $ sudo semodule -i xrdp.pp Eliminating this two conditions gives me working xrdp with Xvnc session, but much faster Xorg session still gives me [DEBUG] Closed socket 25 (AF_UNIX) errors. To make Xorg session working properly I have to make additional Xorg.wrap rights adjustments. After that I have fully working xrdp setup on Fedora 26: $ sudo rpm -qa | egrep “rdp|^selin” selinux-policy-3.13.1-260.1.fc26.noarch selinux-policy-targeted-3.13.1-260.1.fc26.noarch xrdp-0.9.2-12.fc26.x86_64 xrdp-selinux-0.9.2-12.fc26.x86_64 selinux-policy-minimum-3.13.1-260.1.fc26.noarch xorgxrdp-0.2.2-1.fc26.x86_64
I did update the Xvnc stanza of /etc/xrdp/sesman.ini, but the problem persists.
[Xvnc] param=Xvnc param=-bs param=-nolisten param=tcp param=-localhost param=-dpi param=96 param=-AcceptCutText=0 param=-SendCutText=0 param=-SendPrimary=0 param=-SetPrimary=0