waayne
Posts: 4
Joined: Mon Jun 25, 2018 9:42 pm

[VNC] Cannot currently show the dekstop

Mon Jun 25, 2018 9:46 pm

Hey,

I have a problem with my Pi 3+. I activated the VNC server and tried to connect to it on my tablet via the VNCViewer app.
But when I am connected to it there is an error (see attachment).
What can I do to fix that?
Attachments
Screenshot_20180625-234118.png
Screenshot_20180625-234118.png (47.06 KiB) Viewed 59643 times

klricks
Posts: 6609
Joined: Sat Jan 12, 2013 3:01 am
Location: Grants Pass, OR, USA
Contact: Website

Re: [VNC] Cannot currently show the dekstop

Tue Jun 26, 2018 1:23 am

waayne wrote:
Mon Jun 25, 2018 9:46 pm
Hey,

I have a problem with my Pi 3+. I activated the VNC server and tried to connect to it on my tablet via the VNCViewer app.
But when I am connected to it there is an error (see attachment).
What can I do to fix that?
The RPi must be set to boot to desktop (service mode).
If a HDMI monitor is not attached then you need to specify a screen resolution in config.txt
Use GUI config tool or sudo raspi-config to do that.

If not booting to desktop then you need to use virtual mode. (Run vncserver from the command line).
Unless specified otherwise my response is based on the latest and fully updated Raspbian Buster w/ Desktop OS.

coldsprite
Posts: 2
Joined: Thu Jul 05, 2018 9:25 pm

Re: [VNC] Cannot currently show the dekstop

Thu Jul 05, 2018 9:27 pm

I have same problem.
I enabled service mode desktop auto login, and default resolution.
Still see same "Cannot currently show the desktop" error on VNC.

Thanks

coldsprite
Posts: 2
Joined: Thu Jul 05, 2018 9:25 pm

Re: [VNC] Cannot currently show the dekstop

Thu Jul 05, 2018 9:29 pm

I have the same problem.
Already tried the recommendation, still same error.

klricks
Posts: 6609
Joined: Sat Jan 12, 2013 3:01 am
Location: Grants Pass, OR, USA
Contact: Website

Re: [VNC] Cannot currently show the dekstop

Thu Jul 05, 2018 9:38 pm

coldsprite wrote:
Thu Jul 05, 2018 9:27 pm
I have same problem.
I enabled service mode desktop auto login, and default resolution.
Still see same "Cannot currently show the desktop" error on VNC.

Thanks
Do not use default resolution. Choose something else.
Unless specified otherwise my response is based on the latest and fully updated Raspbian Buster w/ Desktop OS.

jkellogg11
Posts: 1
Joined: Sun Jul 08, 2018 11:21 pm

Re: [VNC] Cannot currently show the dekstop

Sun Jul 08, 2018 11:34 pm

You need to install a window manager.

Check out this post.

viewtopic.php?f=66&t=133691

My .xsession-errors file showed this. After installing LXDE I could login.

[email protected]:~# cat .xsession-errors
Xsession: X session started for root at Wed 18 Apr 13:50:07 UTC 2018
Xsession: unable to start X session --- no "/root/.xsession" file, no
"/root/.Xsession" file, no session managers, no window managers, and no
terminal emulators found; aborting.

olafvandekuijt
Posts: 14
Joined: Mon Jul 09, 2018 6:35 am

Re: [VNC] Cannot currently show the dekstop

Mon Jul 09, 2018 6:49 am

Hi,

I had the same problem.
After changing the resolution to the highest it was solved (sudo raspi-config)

Olaf

pk_rulz
Posts: 1
Joined: Fri Aug 31, 2018 8:57 am

Re: [VNC] Cannot currently show the dekstop

Fri Aug 31, 2018 9:54 am

If everything was working fine and it stopped suddenly then there is possibility that you might have run out of space on the SD card.
I am listing it down to help someone who have such a problem

The following thread should help you to fix that issue
https://www.raspberrypi.org/forums/view ... hp?t=71520

In a nutshell
If you can connect over ssh, this should show you if your /dev/root is full

Code: Select all

df -h

If it is, this should help you locate the culprit folder/file. Remove it and vnc should work fine.

Code: Select all

sudo du -xh / | grep -P "G\t"
For more advanced options the thread link at the stop should help

demian
Posts: 1
Joined: Tue Oct 08, 2013 6:28 am

Re: [VNC] Cannot currently show the dekstop

Thu Oct 04, 2018 7:09 am

In my case...

I installed lxsession(sudo apt-get install lxsession)
, then work OK.

nikitakaps
Posts: 1
Joined: Fri May 24, 2019 3:42 pm

Re: [VNC] Cannot currently show the dekstop

Fri May 24, 2019 3:47 pm

I tried everything mentioned in this thread, but nothing worked. What helped me was deleting the /home/pi/.profile using sudo rm .profile
After rebooting I was automatically logged in and everything worked as before. Hope this helps!

Anantasak
Posts: 1
Joined: Sun Jun 09, 2019 7:30 am

Re: [VNC] Cannot currently show the dekstop

Sun Jun 09, 2019 7:37 am

For some case:

Found that problem cause by lxsession file damage. Try PD by running lxsession and find out which package broken then reinstall specific package.
[email protected]:~ $ lxsession
lxsession: error while loading shared libraries: /usr/lib/arm-linux-gnueabihf/libgtk-x11-2.0.so.0: nonzero padding in e_ident
Fixed by checking md5 libgtk-x11-2.0.so.0 a.k.a libgtk-x11-2.0.so.0.2400.31
[email protected]:/usr/lib/arm-linux-gnueabihf $ md5sum libgtk-x11-2.0.so.0.2400.31
845a355f212cfb3ac3e9cb6926002615 libgtk-x11-2.0.so.0.2400.31
then rerun install package
sudo apt-get install --reinstall libgtk2.0-0
to resolved lxsession
[email protected]:/usr/lib/arm-linux-gnueabihf $ lxsession
** Message: main.vala:102: Session is (null)
** Message: main.vala:103: DE is (null)
** Message: main.vala:107: No session set, fallback to LXDE session
** Message: main.vala:113: No desktop environnement set, fallback to LXDE

User avatar
RottenRonnie
Posts: 4
Joined: Thu Feb 26, 2015 1:15 am
Location: Charlottetown PE, Canada
Contact: Website

Re: [VNC] Cannot currently show the dekstop

Fri Jun 14, 2019 4:45 pm

I used these steps to get the RealVNC server to work after reading the posts above:
(Note that resetting the max resolution in raspi-config had no effect and I was still seeing the error message.)

Code: Select all

[email protected]:~ $ cat .xsession-errors 
The error that I saw:

Code: Select all

/usr/bin/x-session-manager: 33: exec: /usr/bin/lxsession: not found

Code: Select all

[email protected]:~ $ ls /usr/share/xsessions
lightdm-xsession.desktop  openbox.desktop
[email protected]:~ $ cat /usr/share/xsessions/lightdm-xsession.desktop 
[Desktop Entry]
Version=1.0
Name=Default Xsession
Exec=default
Icon=
Type=Application
[email protected]:~ $ sudo apt-get install --reinstall lxsession
Success!!! I'm currently logged into the regular pixel desktop. :mrgreen:

macd2point0
Posts: 1
Joined: Wed Jun 26, 2019 2:29 am

Re: [VNC] Cannot currently show the dekstop

Wed Jun 26, 2019 2:35 am

Changing the resolution worked for me. That's all i got.

Andyroo

Re: [VNC] Cannot currently show the dekstop

Wed Jun 26, 2019 2:19 pm

macd2point0 wrote:
Wed Jun 26, 2019 2:35 am
Changing the resolution worked for me. That's all i got.
N Buster it seems that you need to set the resolution before using VNC either by the GUI or command line raspi-config.

SimUK
Posts: 7
Joined: Wed Jun 26, 2019 10:06 am

Re: [VNC] Cannot currently show the dekstop

Wed Jun 26, 2019 2:23 pm

.
Last edited by SimUK on Mon Jul 22, 2019 6:34 pm, edited 1 time in total.

seandex
Posts: 2
Joined: Sun Dec 10, 2017 11:08 am
Location: Los Angeles - Korea Town

Re: [VNC] Cannot currently show the dekstop

Thu Jun 27, 2019 7:46 am

klricks wrote:
Tue Jun 26, 2018 1:23 am
waayne wrote:
Mon Jun 25, 2018 9:46 pm
Hey,

I have a problem with my Pi 3+. I activated the VNC server and tried to connect to it on my tablet via the VNCViewer app.
But when I am connected to it there is an error (see attachment).
What can I do to fix that?
The RPi must be set to boot to desktop (service mode).
If a HDMI monitor is not attached then you need to specify a screen resolution in config.txt
Use GUI config tool or sudo raspi-config to do that.

If not booting to desktop then you need to use virtual mode. (Run vncserver from the command line).
Where is the example for the config.txt?

Man in a van
Posts: 138
Joined: Sat Dec 27, 2014 2:41 pm
Location: Staffordshire, UK.

Re: [VNC] Cannot currently show the dekstop

Thu Jun 27, 2019 10:51 am

seandex wrote:
Thu Jun 27, 2019 7:46 am
klricks wrote:
Tue Jun 26, 2018 1:23 am
waayne wrote:
Mon Jun 25, 2018 9:46 pm
Hey,

I have a problem with my Pi 3+. I activated the VNC server and tried to connect to it on my tablet via the VNCViewer app.
But when I am connected to it there is an error (see attachment).
What can I do to fix that?
The RPi must be set to boot to desktop (service mode).
If a HDMI monitor is not attached then you need to specify a screen resolution in config.txt
Use GUI config tool or sudo raspi-config to do that.

If not booting to desktop then you need to use virtual mode. (Run vncserver from the command line).
Where is the example for the config.txt?

Code: Select all

sudo raspi-config
Select 7 Advanced Operations

Select 5 Resolution

Andyroo

Re: [VNC] Cannot currently show the dekstop

Thu Jun 27, 2019 11:27 am

The entries in config.txt are three lines

Code: Select all

# uncomment if hdmi display is not detected and composite is being output
hdmi_force_hotplug=1

# uncomment to force a specific HDMI mode (this will force VGA)
hdmi_group=2
hdmi_mode=35
But the values differ depending on the mode and are set by lines 1539 onwards of raspi-config (as of the time of this posting).

BUT it is getting more complex with additions for the Pi 4 (HDMI vs Composite) so I would just follow Man in a vans process above

I cannot remember if the GUI version of the configuration tool has resolution controls and the Pi computers I can get to at the mo are running Lite.

Shad0w1and
Posts: 1
Joined: Fri Jul 05, 2019 12:07 am

Re: [VNC] Cannot currently show the dekstop

Fri Jul 05, 2019 12:09 am

Man in a van wrote:
Thu Jun 27, 2019 10:51 am
seandex wrote:
Thu Jun 27, 2019 7:46 am
klricks wrote:
Tue Jun 26, 2018 1:23 am


The RPi must be set to boot to desktop (service mode).
If a HDMI monitor is not attached then you need to specify a screen resolution in config.txt
Use GUI config tool or sudo raspi-config to do that.

If not booting to desktop then you need to use virtual mode. (Run vncserver from the command line).
Where is the example for the config.txt?

Code: Select all

sudo raspi-config
Select 7 Advanced Operations

Select 5 Resolution
Thanks, this worked for me!

tom408881465
Posts: 1
Joined: Thu Jul 25, 2019 3:01 am

Re: [VNC] Cannot currently show the dekstop

Thu Jul 25, 2019 3:06 am

Hi
I had the same problem.
I changed Boot Options, set boot into a desktop ,it was solved.

gufronra
Posts: 1
Joined: Thu Aug 29, 2019 1:03 am

Re: [VNC] Cannot currently show the dekstop

Thu Aug 29, 2019 1:10 am

I had the same problem. just reboot your raspberry (don't close vnc session that show black screen "Cannot currently show the desktop") and wait a minute till raspberry full loaded the desktop :D

The German
Posts: 11
Joined: Sun Feb 08, 2015 9:49 pm

Re: [VNC] Cannot currently show the dekstop

Sun Sep 08, 2019 11:35 pm

I could not switch away from GNOME to KDE or another desktop, the automatic logon did not work anymore and VNC never worked after the initial installation and updates. I like to tinker, but "Buster" is a piece of crap that should not have been released with all the bugs and incompatibilities. The PI 4 is pretty much useless to me as there is no real compatible and stable OS. Disappointing.

cyberflame
Posts: 1
Joined: Wed Sep 25, 2019 6:46 am

Re: [VNC] Cannot currently show the dekstop

Wed Sep 25, 2019 6:50 am

I've tried all of these things, none of which work.

ohilton576
Posts: 1
Joined: Sun Sep 29, 2019 8:12 pm

Re: [VNC] Cannot currently show the dekstop

Sun Sep 29, 2019 8:14 pm

Why are you trying to use VNC anyway?
I found that good old windows RDP (Remote Desktop) works just fine. Use port 3389. Sorted. No need for any additional apps like vnc or anydesk.

ahammedx007
Posts: 1
Joined: Thu Oct 10, 2019 11:10 am

Re: [VNC] Cannot currently show the dekstop

Thu Oct 10, 2019 11:16 am

Code: Select all

sudo raspi-config
Select 7 Advanced Operations

Then

Select 5 Resolution
Thanks, this worked for me!

Return to “Troubleshooting”