Hello World,
We have noticed that a lot of people hit the same issue over and over again. When trying to connect via remote desktop protocol (rdp) to the Ubuntu machine, and after providing the credentials in the xRDP Login page, the user will only see a black screen displayed and the desktop interface is never loaded and displayed. This post will basically explain why this happens and how to reproduce the issue.
The “problem” is actually well known and there is really an simple and easy fix for that. So, let’s explain the situation…..
Overview
Reproducing the “Black Screen” Situation
Let’s assume that you have performed a successful xRDP installation (manually or using our famous xrdp-installer-xx.sh script) and you are ready to test your rdp connection to your Ubuntu machine. Let’s also assume that you are still logged on into your Ubuntu machine system locally with your user account (which could be called User1). So, you move to your Windows machine (or Linux machine), fire up your favorite remote desktop client and provide the ip address or the hostname
Click on picture for better Resolution
Since xRDP installation has been successful, you will be presented with the xRDP Login page where you will need to provide the user credentials on the Ubuntu machine. In our example, User1 (yes the one currently logged on locally on the ubuntu machine) account will be used
Click on picture for better resolution
If the credentials are correct, you will see your remote desktop session showing a black screen and that’s it !!!!! The desktop interface will never load within your remote session
Click on picture for better resolution
Black Screen situation Explained
As mentioned and explained multiple times, this situation will happen (or can happen) when the same user account is used concurrently locally and remotely. In other words, the problem is related to the fact that the same user account is already logged in locally and a remote connection is attempted at the same time. With xRDP software solution, a specific user account can be logged on either locally or remotely but not both….
The (Standard) Solution
To solve this issue, there is a simple fix. You need to ensure the account you are using to login via the remote desktop client is not currently logged on locally on the Ubuntu target machine. If this is the case, perform a logout operation as shown in the screenshot below….
Click on Picture for better Resolution
Try again the remote desktop session and you will see that magically, you will be able to perform your remote desktop connection and that your desktop interface will be loaded and made available for you
Click on Picture for better Resolution
As mentioned in the title, this is the most command and most standard approach to fix this issue. This is basically the recommended approach to be used.
However, there are other techniques (easier to implement that can be used) and we will share them with you soon…. In the next post, we will show you how to implement these techniques
Final Notes
Voilà ! This is it for today !
We hope that this post will be useful to all these people that have encountered the xRDP black screen situation. We have quickly and simply demonstrated how to overcome this minor but annoying xRDP “issue”. It’s important to understand how xRDP works and how sessions are created with the software. When using xRDP software, it will always create a new session for the logged on user. There is no way (as far as we know) to connect to the console session and start your session where you left it !
In a coming post, we will show you some tips and tricks that can be used to allow simultaneously local connections and remote connections…
Till next time
See ya
Thank you – you are AWESOME!!!
@Michael,
Thank you for your feedback and for visiting our blog. We are always happy when we can help in solving some issues with our modest blog 🙂
Till next time
See ya
I wouldn’t even consider myself a novice, but after I removed the group render from my pi user, xRDP would let me remote into my RPi via Windows Remote Desktop.
Larry
@Larry,
Thank you for the feedback and for visiting our blog. Since we are not working much with raspberry we cannot provide feedback here. Thank you for sharing the info; this might be valuable to others
Till next time
See ya
Thanks for taking the time to post this
@John,
Thank you for visiting our blog and providing positive feedback. Happy to see that the information can be useful and can help people out there 🙂
Till next time
See ya
Thanks, worked the 2nd option after a reboot.
@Sebastian,
Thank you for the feedback and for visiting our blog. Always nice to see that the info is helpful and nice to see that people confirm that the trick is working 🙂
Till next time
See ya
That’s a big help and simple! Thanks a lot!
@Betabbs,
Thank you for visiting our blog and providing feedback.. happy to see that you have been able to solve your issues 🙂
till next time
See ya
Thanks for the tips! I thought to try it other way around.
Perhaps I am wrong somewhere. Here is a list of stuffs I tried out.
-> launched an ubuntu instance in AWS
-> logging in to “user1” using CLI (success)
-> created a “user2” standard account using CLI
-> logging in over RDP using “user2” (success)
The RDP session gets launched with a CLI window opened.
however, the dreaded black screen sustains in background.
@Tapo,
Thank you for visiting our blog and sharing your experience. This is a known issue with xRDP… a single connection per user… You would have the same behavior if you login locally and quickly login through remote desktop. One session will get the full desktop the other will simply have a command line open and the black screen in background… There are some workarounds that you can use (see https://c-nergy.be/blog/?p=17371 and https://c-nergy.be/blog/?p=16698) but we do not recommend this because this workarounds can lead to other issues….
Hope this help
Till next time
See ya