I know you can connect to a remote X11 server to use them like a local X11 system.
My question is: Can you connect multiple computers to work together and display (through their videos outputs) an unique instance of X11 desktop?
Or, another phrasing: Can you process and display an image using several X11 servers?
Take a look at Distributed Multihead X Project
X11 is a protocol. If you use it over the network, the GUI application that you run remotely, actually connects to your local X11 server. So yes, you can have multiple clients running applications on the server that display on different X11 servers. As for processing images using X11 server - what do you actually mean by that? The only thing comes to mind is multiple monitors. If so, then yes - you can use a dedicated X11 server per monitor.
If I understood your question correctly, you want to have multiple computers collaborate on displaying a single X11 display. This is not directly possible.
However, you can have multiple video cards in a single computer and use the Xinerama extension to have the multiple cards show a single logical X server. This can allow you to use a single machine to drive several monitors with ease. (With video cards that support multiple outputs, you ought to be able to get up to four or six monitors without too much hassle. Dozens might be very difficult.)
I can't think of any mechanism that would allow a single keyboard and mouse to reliably work across multiple monitors driven by multiple computers. But if your problem is significantly restricted (if it really is just viewing an image via several X servers), then you could write a client application that renders only a portion of the image and run multiple clients that each display only a portion of the image -- that when taken together, looks like the image is seamlessly displayed by several systems simultaneously. This is definitely a bit awkward though, as the coordination of the system will require some thought.
If you want to drag windows from one screen to another, or display a part of a window here and another part of it there, then no, this is not possible with existing out-of-the-box software. You can try to modify a "virtual" X server such as Xephyr such that it uses multiple backend X servers for portions of its framebuffer. This is not exactly trivial but should be much easier than writing your own multi-box X server from scratch.
If you want to clone one desktop to many displays connected to different computers, you can try running VNC or RDP clients on all displays but one.
Related
I am wondering if it is possible to write a program on Windows that communicates with a program within a Linux Virtualbox on the same machine. If this is possible, what is the best approach to doing this? Is there a way to do this without using the internet to communicate?
I found instructions showing how you could potentially use SSH, but I have never tried doing this before, so I do not know if using SSH to communicate would be the best option.
I was going to put this as a comment to a very vague question, but then it got too long.
It depends what you mean by "communicate"....
If the Windows machine should start a program on the Linux VM, you probably want plink.exe - see here.
If you want to transfer whole files, you probably want scp or FTP or FileZilla - see here.
If you want to send small messages occasionally, maybe netcat, also known as nc - see Netcat Cheatsheet here.
If you want full-on, high speed, continuous messages, maybe sockets or some messaging protocol like mqtt.
If you want to share data structures, like lists, queues or sets, you could allow both Windows and the Linux machine to access a shared Redis database - see here.
Or maybe it is enough to share a filesystem between the two machines - in which case you can make a Shared Folder in VirtualBox on your host and the VM can just mount that and read/write it. See diagram:
I'm using my Raspberry Pi 2 Model B as a small and super simple LAMP development server. However it is on the edge of acceptable performance, especially when it comes to bulk copying or handling large MySQL databases.
The set-up:
The Pi has no display attached
I access the device via SSH and WinSCP
I changed the GUI boot behavior via raspi-config to command line only
What makes me curious is that whenever I connect to the Pi via the Windows Remote Control tool I still get a GUI.
Therefore I'm wondering whether if there are any negative performance implications or if Raspbian does not load the GUI until explicitly requested from the remote control tool.
If there are negative implications, what configurations should I change? (PS: I like to have a GUI from time to time but I could do without it.)
Unless the RPi is very starved of memory, there will be no performance difference as long as the graphical interface isn't actively being used.
Having said that, I would not try to run a large database on it unless I was using a class 10 card or better and the database configuration was heavily tuned.
I'll start with a little background. A small project of mine has been to try to use my Android tablet as an external monitor for my laptop using a VNC client (vnc4server). There are two main options for doing this that I have seen. The simplest is to use xrandr and widen the screen, creating a section just for the tablet. However, this can cause some graphics issues if I understand correctly, although it has the benefit of permitting windows to cross displays. The other option is to run a separate desktop session for the VNC server.
I have chosen to go the route of a second desktop as the session can live and die without significantly affecting my main session and can in theory be tailored specifically to the tablet. A little tool called x2vnc allows me to connect to the VNC server in a similar manner to the more popular Synergy and use it like a n external monitor. I also have the nice little benefit of being able to easily and cleanly switch from landscape to portrait using xrandr.
This brings me to my current issue. So far, I have only been able to reliably use plain x-windows. Although this is entirely functional, I would prefer something more complete. Although xstartup examples have been posted for a variety of window managers, none of these seem to run properly. I suspect all of these are for headless systems. Gnome/Unity are each unforgivably slow and seem to conflict with my existing session. I also feel that these are a little too cluttered for my ten inch tablet. On the other hand, Xmonad simply crashes as soon as I try to open a second window in addition to not updating the graphics properly.
I would like to know anything that will lead me in the direction of a better stable desktop environment. This includes configuration tips and alternate window managers.
I am currently running Ubuntu 12.04 with gnome-xmonad (recently Unity). My xstartup is plain x-window-manager. I have tried any readily available examples for gnome and xmonad that I have been able to find.
Have 4 DVI output. Seems I hopefully will have driver support on this. Details are sketchy online about supporting 4 outputs, but seems possible.
My question is from the Linux group and Virtualbox pros.... Will the seamless method of VirtualBox allow me to use all 3 of my monitors for multiscreen. I'd like to stick with Ubuntu and run Visual C# and other tools from my VirtualBox. Compiz effects are just too amazing to want Aero Glass.
What do you think, will my system be able to use the multiple monitors with VirtualBox and this graphics card? I've googled for hours and am still searching for answers.
Edit:
I tried virtualbox last night. Pretty slick, though I had an error in installing Visual C#NET. However, it wouldn't let you drag between multiple screens??? Is this something the host must resolve, or does the guest session need to have special settings for multiple monitors? Haven't been able to find anything in google supporting multiple monitors with virtualbox.
You should be able to configure your screens just fine. Don't know the exact details for an ATI setup, but you should be able to use Xinerama to create a single large virtual desktop, and then just run VirtualBox (though honestly, I prefer KVM, which runs on modern CPUs which provide native virtualization support) full-screen on one of those monitors. You would then be able to have three screens dedicated to Ubuntu, and the forth dedicated to Windows.
You might want to look into the non-Xinerama method of multiple displays. Each display is then treated as its own screen (so you'd have :0.0, :0.1, :0.2, and :0.3 for your X displays). You cannot move applications between the screens, but you get four independent desktops. I personally find that more useful than the idea of a single stretched desktop over multiple displays; when I used a laptop as my primary system, that's what I did, and when I get a second monitor for my computer, I'll likely return to that means of doing things. You'll have to investigate the specifics for such a setup with ATI, but the X server supports it, so it's just a matter of looking at your ATI driver's documentation to put the pieces together.
I recently started using Linux (where I work is a Microsoft shop, so I only code in C#, work with MS products etc).
I'm trying to understand at a high level how some basic things in Linux hang together.
I've been reading www.linfo.org
Anyway I've never quite got what X is.
From reading this article it seems to me that X is layer that sits on top of the operating system (one X server sitting on top of the OS??) and X client applications make requests to the X server.
I think KDE, Xfce and Gnome are display managers, are they X server clients then?
I'm quite confused where everything sits.
Any explanation would be really appreciated!
It's all very modular and flexible; however this leads to complexity.
The "X Server" drives the display device. It provides graphics services to clients, and those services are pretty simple - such as:
"Give me a window frame to draw in"
"Put this bitmap here"
"Draw a horizontal black line 100px wide"
"Render the text 'hello' at (100,100)"
"Tell me if any mouse clicks or key presses have been aimed at my window frame"
There is a library called Xlib, provided by X, that has a standard interface for all these simple services. Any program that wants to use the X server's display eventually uses this client library and is called an X Client. Xlib knows how to connect to an arbitrary X server - on the local machine, or via TCP/IP across the LAN, or across the world - to call these services.
The Window Manager, which is just another X client program, is in charge of the "look and feel" of the desktop - how you move and arrange windows, etc. Because the window manager draws all the window decorations, it can make the desktop look like WindowsXP, or a Mac, or NeXTSTEP.
Part of the philosophy of X was to define "mechanism and not policy" - meaning, they give you tools to do it, but don't tell you how to use those tools. One such tool is the window manager, which can be replaced at will.
Many modern X applications are written to use a desktop enviroment such as Gnome or KDE. This offers these programs a consistent set of buttons and controls to draw, and a consistent interface for some things not traditionally included in X, but often considered part of a desktop - such as how to respond to drag-and-drop or how to present a standard file chooser dialog box.
The desktop environment usually provides an object model or programmatic interface that takes care of making all the simple X client requests and lets the program handle more important things. Removing these low-level calls yields another important benefit - platform independence.
Many desktop environments include a window manager, so that the look and feel of window controls and buttons is consistent and works with the desktop metaphor provided by the environment. However, it can usually still be switched out.
The separation of the X Server (running the display) and the X Client (wanting to use the display) has a few implications:
The graphics system is separate from the GUI programs, and they are separated about as completely as a web browser and web server are.
So the GUI program might not be displaying on the local machine - just like a web browser doesn't have to point at a web server on the local machine.
A machine can run JUST the client, with the X server elsewhere.
The machine with the display doesn't have to run the client - it can run JUST the X server, and all the clients can run on a dedicated machine. This is the original thin client: big programs running on big central server - with graphical user interaction handled by dedicated hardware on the desk in front of the user.
You need to know what your X server's network address is so you can tell GUI programs where to display their GUI. (this is usually done by setting the DISPLAY environment variable)
You can display many programs, from many different machines, all on the same desktop at the same time. It is all handled seamlessly, including cut-and-paste.
X11 is a network protocol, currently at release 7 (hence X11R7). It encapsulates graphics and input information, and connects an X client (application or window manager) running on a local or remote machine to the X server currently driving the local screen and input devices.
Gnome, KDE, XFCE, and LXDE are desktop environments; they contain pieces that talk to/with the X server (metacity, kwin, etc.), but also consist of specifications that applications must follow and libraries that are available in order for an application to "belong" to the DE.
In addition, it's worth remembering that the X server is just another program that gets run under linux. There's nothing special about it, it just happens to know how to grab onto the graphics card and take over the monitor using video drivers.
You can (theoretically) run linux very happily without ever running an X server - although of course, you would be limited to the command line programs.
That's how linux organises itself - kernel at the base, then a set of programs that provide functionality to higher level programs, which themselves provide functionality to higher level programs, all building up into a complete stack of software oriented to whatever the job of the machine is (say, general desktop, software development, web server, etc).
Beyond the kernel and it's modules, nothing is 'special'.
Wikipedia has some info about it.