4 ms·
I'm not sure it's even "ready for the server". I have a server without a monitor I'd like to VNC to. Unfortunately X doesn't start without a physical monitor p
by IshKebab 11y ago
I'm not sure it's even "ready for the server".
I have a server without a monitor I'd like to VNC to. Unfortunately X doesn't start without a physical monitor plugged in because it uses it for autodetection. It's such a silly problem that you can even buy fake "monitor" dongles to plug in to trick X into thinking that there is one.
I don't feel like spending money on a software problem so I followed the standard workaround - create a static xorg.conf file. This is very suboptimal because what happens if I later plug in a real monitor?
Ok so now X starts. Sort of. Actually lightdm starts and I still can't get X11vnc to connect to the `:0` display. Apparently there is a workaround involving the MIT magic cookie but at this point I've given up.
In fact does X even support monitor hot-plugging?
Oh and also, if the wifi connection goes down and X isn't running it doesn't automatically reconnect! Wtf? I assume this is because the thing that does the reconnecting is a GUI tool of some sort.
Madness.
- phireal 11y agoAll that sounds more like PEBKAC than anything else. I've had multiple VNC servers running on headless machines for longer than I can remember. Using x11vnc to connect to a VNC server is like SSHing into localhost instead of just opening up a terminal. You're approaching the task the wrong way around. Wifi not reconnecting sounds like your system has a graphical widget handling the network connections. No X = no graphical programs = no network connections.
- exDM69 11y ago> In fact does X even support monitor hot-plugging? Yes, it does. It's called XRandR. Not sure how your desktop system handles it, is there a pretty graphical widget or how you configure it, I don't use a desktop GUI, I set it up with the xrandr command line tool (which is more easily repeatable than a GUI, albeit less discoverable). > I assume this is because the thing that does the reconnecting is a GUI tool of some sort. You're probably using network-manager, which is a graphical widget in Gnome (KDE has something similar). There are other methods of setting up Wifi (I use wifi-menu on Arch Linux).
- laumars 11y agoIn fairness to Linux, you're not actually building a "server" there. A typical server would be running on over ethernet rather than WiFi and on server board with support for remote management (eg IPMI or iLO) which would have mitigated the VNC issues you were having (though anecdotally I've never had any problems running X + VNC on a headless Linux box on the rare occasions I've needed to) But arguments about VNC aside, the vast majority of the time you don't want nor need a GUI running on a server to begin with. Aside maybe some game servers, any Linux server daemon is command line configurable so you're better off saving your RAM and managing your server via SSH (or better yet, Vagrant / Puppet / equivalent) In my experience, Linux is actually very good on servers. But by this I mean "proper" servers. Personally I'd still rather run FreeBSD, but many of the same arguments for and against Linux are applicable for FreeBSD as well.
- IshKebab 11y agoWho says a server can't use wifi? A server is just a computer that primarily provides services to other computers. And who says I don't want to run a GUI? I don't live in the 70s.
- teddyh 11y ago> I have a server without a monitor I'd like to VNC to. That’s your problem right there. You can’t (or, rather, don’t) “VNC” to Unix servers. For normal remote access, you use SSH. If you really need to run a graphical X program continuously on a server, you run a virtual X server program like “Xvfb”, and point your graphical X program to that. You can then “VNC” all you like to this virtual X server. All without a monitor or even a graphics card or a mouse on the actual server. This thinking – the idea that a server has something one can refer to as “the” screen, or “the” mouse – is completely and utterly wrong, and betrays a thinking born from Microsoft Windows and other desktop-only-oriented operating systems.
- maxerickson 11y agoMicrosoft is going to ship a headless version of Windows Server: https://technet.microsoft.com/en-us/library/mt126167.aspx https://technet.microsoft.com/en-us/library/mt126167.aspx
- osullivj 11y agoI had a play with the headless Windows 2016 TP3 on Azure late last year and blogged my experience here [1]. You can even run GUI programs on it; I found it useful to run Sys Internals Process Explorer to track what was really happening with the Containers. Obviously there's no desktop with file explorer etc. [1] https://etrading.wordpress.com/2015/10/13/windows-containers/ https://etrading.wordpress.com/2015/10/13/windows-containers...
- teddyh 11y agoThe problem is that all server software written with Windows in mind already assume that their interface is a screen and a mouse, and will try to create a main window, dock icon, and show popups when something happens. How will they work on a headless Windows server?
- JoeAltmaier 11y agoConfused: remote desktop makes any server not headless.