What a pain in the ass. You would think that the only open source implementation of RDP server would have more notoriety. Ubuntu supports xrdp quite well, but support outside of Ubuntu seems to be nonexistent for whatever reason. Xrdp support seems to have been dropped for CentOS beginning with version 6.
All of my other machines are Windows, so it seemed like a good idea to have a network display interface that all of them could talk to the linux box with. Having an RDP server right on the linux machine means that the Remote Desktop Client already installed on all the Win7/Win8/Windows Server 2012 machines on my network can access this machine without having to install some strange flavor of VNC.
Some people seem to think that xrdp is no longer maintained, however they recently merged with the FreeRDP project, and the xrdp package is actively maintained in Ubuntu… just not CentOS/RHEL universe. There was a pull request not 3 hours ago on their github.
Anyways, let’s go on. My box is a $150 newegg special atom-powered nettop, which means it’s i686 with no vt-x/vt-d support. My instructions differ slightly from this guy’s but not by much. You can use the x64 files but I’m not sure if they improve your experience any. I’ve also corrected some of his typos. In addition to CentOS 6.4, this will work with Scientific Linux 6.x and RHEL 6.
So this is basically four phases.
- Install/Update RPMs
- Install dependencies
- Install old 0.5.0, then compile 0.6.0 on top of that
- Manual configuration of xrdp
What a huge pain. But totally worth it. Full instructions below the cut.
Step 1:
#rpm -Uvh http://pkgs.repoforge.org/rpmforge-release/rpmforge-release-0.5.3-1.el6.rf.i686.rpm
#rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
#yum -y update
#yum repolist
Step 2:
#yum install -y xrdp tiger-vncserver autoconf automake libtool openssl-devel pam-devel libX11-devel libXfixes-devel
Step 3:
Download the latest version of xrdp. That’s probably going to be 0.6.0. Unzip/tar it to a folder on your desktop
#cd /home/username/Destkop/xrdp-v0.6.6/
#chmod u+x bootstrap
#./bootstrap
#chmod u+x configure
#./configure
#make
#make install
This will compile a bunch of stuff.
#groupadd tsusers
#groupadd tsadmins
Fantastic. All the easy work is done, now let’s modify a bunch of config files manually.
Step 4:
#nano -w /etc/group
Now add these two lines to the group file. Note it is group, not groups.
tsusers:x:501:YOURUSERNAME
tsadmins:x:502:root
Setting up the password for xrdp/vnc
#su YOURUSERNAME
#vncpasswd
Insert your password twice
#exit
To return root user
Edit VNC server files
#nano -w /etc/sysconfig/vncservers
Add to end of vncservers file. You can adjust the resolution from microsoft’s RDC app, but it’s good to have a resolution to start with.
VNCSERVERS=”1:YOURUSERNAME”
VNCSERVERARGS[1]=”-geometry 1355×768 -depth 16″
Edit another text file
#nano -w /etc/rc.local
Dump this line at the end on a new line
/etc/xrdp/xrdp.sh start
And then start up the service. Awesome. You shouldn’t need to muck around with the firewall, but if you do the port number is 3389
#chkconfig vncserver on
#service vncserver start
#/etc/xrdp/xrdp.sh start
And… behold! Hopefully it was worth it.
Hi there,
I installed xRdp on a CentOS 6.4 server.
Everything seems to work fine except for… after login via Rdp the screen remains black and the only thing you see is your mouse.
Any idea about it?
Thanks in advance
Pingback: Setup CentOS on Hyper-V Windows 8.1 | Old fart gets MS in CS and other musings
Works like charm.. thank you for your efforts..
Well, it works, finally!
I don’t know exactly what went wrong, some days ago, but I’d put my 5 cents on the idea that it was due to a different compile procedure used to make xrdp work.
Now, installing a new centOS vm and following step-by-step your procedure everything works well!
Thanks again!
Glad to hear it worked on the new CentOS 6.4 VM!
Concise and accurate instructions. Works perfectly. Thank you so much.
Thanks from France.
I added xrdp in /etc/init.d and K/S links in rcX.d folders.
It works well on a VM.
Philippe
Found your instructions to be very helpful. Found I had to adjust iptables, and then it worked great. Thanks!
xrdp is available in the EPEL repository. Saves you building from scratch.
Very good tutorial many thanks!
Hi, i installed Centos 6.4 x64 and then i did exactly the same steps as above.
But no matter what i do when i connect to xrdp and put there correct credentials it always stops at:
sending login info to session manager, please wait…
xrdp_mm_process_login_response: login failed
Where is the catch?
Installed on CentOS 6.4.. I get a gnome-menu on a black screen with no mouse cursor and nothing works in the session.
same issue
sending login info to session manager, please wait…
xrdp_mm_process_login_response: login failed
I am getting the below error when i try the ‘service vncserver start’ command,
Starting VNC server: ”1:Nick” /etc/init.d/vncserver: line 52: ”1: syntax error: operand expected (error token is “”1″)
I copy and pasted everything as you suggested. I am runing CEntros 6.5 – could that be the issue?
this is what the config fiel looks like
VNCSERVERS=”1:Nick”
VNCSERVERARGS[1]=”-geometry 1355×768 -depth 16″
“Regardless of this puzzle about where her suitcase might have absent, we acknowledge that we produced a customer service error once we spoke to Ms. Hanlon about her absent piece of baggage,” says Benson. “Recognizing that she didn’t have insurance coverage, which our plan was a reimbursement of only $250, we by no means will need to have questioned her to take the time to generate an itemized listing.”.
christian red bottoms http://www.coomtranscol.com/cl/christian-red-bottoms.html
Skip step 3 on CentOS 5 (64-bits) and it works flawessy. No “xrdp_mm_process_login_response: login failed” error anymore.
With a little tunning you can even install an alternative DE like razorqt/openbox much lighter than gnome.
Sorry I meant CentOS 6.5 and NOT CentOS 5
This worked w/o a glitch!
Wonder if it will work on debian distros?
Thanks much!
If you need it on Debian, I would use the version in the Ubuntu repositories.
Pingback: [HELP] XRDP not working CentOS
Thanks for posting this – worked like a charm.
The package name for VNC on your yum command isn’t formatted correctly – you have tiger-vncserver when it should be tigervnc-server.
Thanks!
After point
#su YOURUSERNAME
I have a message
su: user xxx does not exist
Any ideas what is wrong and how to fix this?
The fact that Mr McGuigan, 37, had” pals school bus with shotguns”.
Often times contractors will easily meet you. Contractors who work
under the aggregate and school bus trowel the top,
they have been listed below to nominate a website is the primary goal for small-business contracting.
Feel free to visit my web-site; web page – Eleanore -
For those that got message: “xrdp_mm_process_login_response: login failed”.
Observe that group file has already those lines, but without the users.
Make sure to leave only those two lines in STEP 4 with your users.
I did followings to install centos 6.5 x86_64 with xrdp within virtualbox
1. installed centos with minimal option
2. yum install epel-release # this adds epel repo which contains xrdp
3. yum install tigervnc-server
4. yum install xrdp
5. yum groupinstall “Fonts”
6. yum install icewm xterm
7. create user for vnc then set its vncpassword:
useradd myuser
passwd myuser
su – myuser
vncpasswd
8. Edit config files /etc/sysconfig/vncservers
VNCSERVERS=”2:myuser”
VNCSERVERARGS[2]=”-geometry 800×600 -nolisten tcp -localhost”
/etc/sysconfig/iptables
-A INPUT -m state –state NEW -m tcp -p tcp –dport 3389 -j ACCEPT
9. (re)start services: vncserver xrdp iptables
10. ensure that service will start after reboot:
chkconfig xrdp on
(vncserver will be started by xrdp with login – starting vncserver is not required)
11. connect to server with RDP
Because /etc/xrdp/startwm.sh starts the graphical user interface and because cannot find window managers it starts an xterm window. From the xterm window I can start icewm or edit /etc/xrdp/startwm.sh and add icewm to sessions :
SESSIONS=”gnome-session blackbox fluxbox startxfce4 startkde icewm xterm”
This way icewm process remains running when xrdp service is restarted – however this happens rarely.
Awesome article. You should use social websites
to increase traffic and make your site go viral. There
are tools which automate this time consuming process.Visitors can flood your blog in no time,
just search in google for:
Rixisosa’s Social Automation