I'm trying to set up KStars with Ubuntu 20.04 Desktop 64-bit on my RPi with SSD. I got the OS running (haven't installed KStars yet).
I got VNC to work, but only if a monitor is plugged in when the system boots. Without the monitor, VNC doesn't work, and, of course, I want
to mount this headless on my telescope.
I worked around things with one of the
fake monitor dongles
, but I was hoping someone would know how to fix the problem with software. Is there a way to setup Ubuntu so that VNC can run headless, but accept VNC connections? I have no problems doing this with Raspberry Pi OS.
You need to edit the user config file in the /boot directory and set the right hdmi parameters. After that you probably need to right click in the desktop when connected via VNC and set the resolution as well. Then it should always work when connecting via VNC. Search for Jo’s post on this forum from summer last year where this all is explained or send me an email.
Thanks for all the great work on the multistar internal guiding!!!
I have the same set up and as long as you can access initially with a monitor I would set up NoMachine in this situation. The web site gives all the instructions. Set up V8 version for Raspberry Pi on the Pi and make a note of the IP address of the Pi. It will start NoMachine at boot up thereafter. Then set up on the computer that you want to access the Pi from. Follow instructions . Provided both are accessing the same wifi network you should be able to create a connection icon on the computer that you want to view and control the Pi with allows easy connection. There are various options about how to view the remote desktop, choose whatever suits. I find using a static IP address on the Pi helps with this connection.
Thanks to all. Sure enough, adding some magic to config.txt did the trick.
I used the incantation on
Jo's post Wouter pointed to
, where he suggested adding the following to the bottom of the config file (he said it was usercfg.txt, but as @astronerd points out, it is called config.txt) so that the screen resolution was reasonable as well.
I have to say, though, it seems a little more sluggish than Raspberry Pi OS (e.g. as if the gpu isn't connected right). I'll try and follow through to see if I can get everything running. Not awful, just a bit slower in graphics...
I've been running the Ubuntu 20.10 for a couple weeks now on my 8Gb RPi 4 with SSD.
Bottom line is I'm very likely going to stick with it.
The good news:
The VNC connection seems a bit more reliable for Ubuntu--RaspberryPi OS vnc seemed to freeze every now and then. This was usually fixable by disconnecting and re-connecting, but a bit annoying. Sometimes it took a bit more prodding to wake up. For my network, I'm using a pair of powerline adapters and wired ethernet.
Also, the graphics are much clearer. E.g. the HFR numbers on the full-field focus image were never very readable--I always wondered why people didn't complain about it With Ubuntu, they're perfectly readable. Same resolution, 1920x1080 on both.
The bad news
The windowing responsiveness is worse (until yesterday, see below).
In fact, the responsiveness was much worse, until yesterday, and I wasn't sure what I was going to do (since I do like the reliability and picture quality). Doing some googling yesterday, I found some posts suggesting removing a desktop background, and going with a solid color background. I had this
California Nebula pic
as my background. I swapped it out for a solid black background, and, sure enough, responsiveness is now about what the RPi4 OS's responsiveness was (with the CA Neb background). That's not not blindingly fast by any means, but it's workable. I guess that somehow Ubuntu's x11vnc vnc-server is serving up more picture quality at the expense of latency, but I can't seem to find a control to trade it off a little--I tried the obvious quality user setting, set to Auto but tried medium and low, but that did nothing for me.
I guess you could say that RPi OS can handle a background and Ubuntu can't so RPi OS is a bit quicker, and I'd agree with that.
Let me know if you have any further suggestions--I'm running the following to start VNC on Ubuntu:
/usr/bin/x11vnc -auth guess -forever -loop -noxdamage -repeat -rfbauth PASSWORD_FILE -rfbport 5900 -shared -display :0
and using the default VNC server for Raspberry Pi OS, not changing any parameters.
I'm using the same RealVNC VNC Viewer as my client on my Mac for both systems.
The VNC client estimates: "Line-speed estimate: 26121 kbits/s (RTT ~0ms)" which sounds fast to me.
Ken: Thanks for the suggestion, but at this point I'd prefer not to run xpra, but rather keep the Ubuntu windowing environment.
I run ubuntu 20.04 64-bit on my Pi4's for imaging, and I like it. Even seems to work just fine in 2 GB of RAM.
I find that remote desktop programs are noticeably more GUI-responsive than VNC.
There are *many* to choose from
, but I've settled on
. It's free, updated, robust, has clients for all my OSs, and it's much faster than VNC. Formerly used TeamViewer, but the license nagging was too onerous.
Another GUI speed-up for ubuntu on Pi is to run the Mate desktop rather than the default ubuntu desktop. Between mate and NoMachine, I find ubuntu on the pi quite snappy, and the software support is much better than raspberry OS.
I agree. I run Ubuntu Mate 20.1 with NoMachine as remote desktop on RPi4 8GB. I had a similar experience with Team Viewer. VNC works well in Raspian/Raspberrry Pi OS but I never found it worthwhile in Ubuntu due to connection issue and constant drop outs. No Machine is easy to set up and nearly always connects.