thebongobongoclub
Posts: 2
Joined: Tue Mar 26, 2013 4:34 am

VNC - doesn't quite work as it should?

Tue Mar 26, 2013 4:45 am

Dear All

I wonder if you might be able to help a little please?

I am trying to remotely control my RPi using VNC from a Mac.

I have installed the TightVNC Server, and I have installed Zeroconf plugin netatalk and avahi daemon as per the instructions here:
http://4dc5.com/2012/06/12/setting-up-v ... ac-access/

So far so good. If I look in the Finder sidebar, I can see the raspberrypi advertised, and I can use the Mac's default Screenshare VNC application to VNC in to the RPi.

My query is this:
Whenever I've used VNC in the past, be it to connect to a Windows or a Mac machine for the purposes of remotely controlling it, I see the current Windows Explorer or Mac Finder windows open on the remote machine. Now, when I use VNC to remotely control the RPi, all my open windows are gone, disappeared, and I get a completely "new" fresh desktop. So I can't really continue on with the work that I left open on the RPi as I would be able to if sitting directly in front of the RPi, and when I'm using VNC I have to start again, launching all the software etc.

Should this be so?

Can anybody please advise as to if something is wrong here? I would be most grateful. Thank you in advance for your assistance.

McNeil
Posts: 22
Joined: Sat Mar 23, 2013 10:30 am

Re: VNC - doesn't quite work as it should?

Tue Mar 26, 2013 5:11 am

TightVNC Server creates a new desktop when a client connects it.

If you want to control the desktop 0, you have to add :0 in its command line.

http://www.tightvnc.com/vncserver.1.php

I'm using X11VNC instead.

http://www.megaleecher.net/Raspberry_Pi_VNC_Setup

I had to add -httpport 5900 to get it to work.

Code: Select all

Exec=x11vnc -forever -usepw -display :0 -httpport 5900 -ultrafilexfer

thebongobongoclub
Posts: 2
Joined: Tue Mar 26, 2013 4:34 am

Re: VNC - doesn't quite work as it should?

Thu Mar 28, 2013 11:42 pm

Dear McNeil

thank you very much for your speedy reply, very appreciated.

I am having trouble getting your x11vnc solution to work on a fresh install of Wheezy. I get the Connection Refused message when trying to connect with Chicken of the VNC or OSX's internal Screen Sharing application, even though I seem to have followed the instructions given in your hyperlink to the letter...

"Could not connect to server
192.168.1.14:5900
Connection refused: connect()

the version of x11vnc is 0.9.13 -1.

Are there any other bits of software that need to be installed as well. No tightvncserver or suchlike.... I've literally only done the instructions given here:

http://www.megaleecher.net/Raspberry_Pi_VNC_Setup

Any advice most welcome! :-)

McNeil
Posts: 22
Joined: Sat Mar 23, 2013 10:30 am

Re: VNC - doesn't quite work as it should?

Fri Mar 29, 2013 3:54 pm

Try this in a terminal:

Code: Select all

cd /home/pi/
makedir .vnc
x11vnc -storepasswd /home/pi/.vnc/passwd
Then reboot your RPi.

sdjf
Posts: 1395
Joined: Fri Mar 16, 2012 5:20 am
Location: California
Contact: Website

Re: VNC - doesn't quite work as it should?

Fri Mar 29, 2013 4:55 pm

You might want to make sure that only one vncserver is running, and that it is actually running, when you try to connect to it. Rebooting will kill the old ones, but you might want to do a "ps ax" command to see what is actually running, before trying to connect, if you are with your Pi or can ssh in.
FORUM TIP: To view someone's posting history, sign in, click on their user name, then on "Search User's Posts." || Running ArchLinuxArm on Model 2B and 512MB Model B

cleverca22
Posts: 581
Joined: Sat Aug 18, 2012 2:33 pm

Re: VNC - doesn't quite work as it should?

Fri Apr 05, 2013 7:33 pm

the 'vncserver' script is setup to spawn an entirely new X session, usually at :1

it sounds more like you want x0vncserver, which is a bit more manual, but shares an existing X session

pawn88
Posts: 1
Joined: Mon Sep 02, 2013 1:20 am

Re: VNC - doesn't quite work as it should?

Mon Sep 02, 2013 1:46 am

FINALLY FIGURED IT OUT....!

It took me the whole day to figure this out. You can USE tightvnc as a remote to control the desktop on your Television/Monitor.
This is great if you want to hook up your RPi to a television and watch movies using your smart phone or tablet as a control. It is also great if you are a teacher and would like to teach a lesson using your smart phone/tablet to control a projector.

Step 1. Get your tightvnc install onto your RPi and working. I used this instruction to do that: http://elinux.org/RPi_VNC_Server

Step 2: Install raspi-config so you can boot to your desktop when you power on!
- git clone http://github.com/asb/raspi-config.git
- cd /raspi-config
- sh raspi-config
(a window will pop up and allow you choose the options...choose the one that will allow you to boot to the desktop...you may have to .. apt-get install lightdm .. to get it to work)

Step 3: Reboot your RPi

Step 4: Install a VNC Viewer/Client (e.g. Tightvnc Viewer) and SSH Client (e.g. puTTY) onto the computer you want to use as a controller

Step 5: Connet to your RPi using your SSH Client, then type "startx" or whatever boots to your desktop GUI (you have to wait until it fully load...may take some time)

Step 6: Open your VNC Viewer/Client, and make you are running on the same port (most likely 5900..but can be 5901 or 5902 or etc...). And the most important part is to uncheck the option where it says "Share remote Screen". If you share this, then you will be opening mutiple session...you don't want that! You only want ONE session, and everything one else gets booted out!

Sept 1st 2013
I am running kali-linux-1.0-armel-raspberrypi.img (the newer version has lots of bugs and won't let me do a lot of stuff)
I am using Raspberry Pi, Model B

Hope that helps....


#Hash Tag: RPI, Raspberry, Pi, Kali Linux, Tightvnc, Remote, Control, Share Screen

Return to “General discussion”