| 1 | If you are having problems with !VirtualBox's shared clipboard functionality and are using either an X11-based host system or an X11-based guest then it is possible to enable logging functionality which will give you a glimpse into what is happening inside. This glimpse will be from the point of view of the X11 clipboard component, so if you are for example running a Windows guest on a Linux host, you will see when the host component thinks that the guest component has asked for the clipboard contents, but not directly when an application on the guest has asked the guest component for data. |
| 2 | |
| 3 | For background, the shared clipboard mechanism is made up of a component running on the host and one running on the guest which communicate using !VirtualBox's host-to-guest communication mechanism. The host component represents all applications running on the guest and vice versa. Some examples of what this means are: |
| 4 | |
| 5 | * if an application on the guest takes ownership of the clipboard there, the host component takes ownership of the clipboard on the host. If an application on the host asks it what data formats it has on offer, the host component asks the guest component which asks the owner application on the guest, and the host component returns this information. |
| 6 | * If an application on the host asks for data from the clipboard, the host component asks the guest component which asks the owner application. |
| 7 | * If an application on the host then takes ownership of the clipboard on the host, the host component tells the guest component which takes over ownership of the guest clipboard from the application which had it. |
| 8 | |
| 9 | The sort of information that you will see will include: |
| 10 | |
| 11 | * The component is starting or stopping. |
| 12 | * An application has asked the component what data formats the shared clipboard has on offer. |
| 13 | * An application has asked for clipboard data. |
| 14 | * The other component has announced that it an application at its end is taking control of the clipboard, so this component should take control of the clipboard at its end to represent the remote application. |
| 15 | * An application at this end has taken control of the clipboard, so this component has relinquished control and asked the other end to take control over the clipboard there to represent the application. |