package vchan
All checked builds passInstall
dune-project
Dependency
Authors
Maintainers
Sources
sha256=7e48b5da5ad6b88c1e197fef483da06cc5fda9a3382ad8620d92de25859c5fe5
sha512=b2f107bf7384908e786dc45f1c5c3796662ea01032fe6639047151d5b3b30e46e82d4f6592548ee085fc1409f93986ff75e446812206122ffdd12da8f82b6e44
Description
This is an implementation of the Xen "libvchan" or "vchan" communication protocol in OCaml. It allows fast inter-domain communication using shared memory.
README
This is an implementation of the Xen "libvchan" or "vchan" communication protocol in OCaml. It allows fast inter-domain communication using shared memory.
Linux configuration
Make sure your systems are properly configured. You may need to:
sudo modprobe xen-evtchn
sudo modprobe xen-gntdev
sudo modprobe xen-gntalloc
mount -t xenfs xenfs /proc/xenTo use in Linux
To connect as a server to a client with domid 'domid' and using the string 'port' to denote the connection:
open Vchan_lwt_unix
open_server ~domid ~port ()
>>= fun (ic, oc) ->
Lwt_io.write_line oc "hello"
>>= fun () ->
Lwt_io.flush oc
>>= fun () ->
Lwt_io.close ic
>>= fun () ->
Lwt_io.close ocTo connect as a client, replace open_server with open_client.
To use the command-line
On both of your VMs, find their domain ids:
xenstore-read domidOn the domain with domid <server domid>, listen for a single connection from <client domid> on <port>:
xencat -l <client domid> <port>On the domain with domid <client domid>, connect to <server domid>:
xencat <server domid> <port>So to transfer a file foo from domid 1 to domid 2:
On domain 2, listen for the connection and retrieve the file:
xencat -l 1 foo > copy-of-fooOn domain 1, transmit the file:
cat foo | xencat 2 foo
Dependencies (8)
-
xenstore_transport
>= "1.0.0" -
xenstore
>= "1.2.2" -
mirage-flow
>= "4.0.0" - io-page
-
cstruct
>= "6.0.0" -
lwt
>= "2.5.0" - dune
-
ocaml
>= "4.08.0"
Dev Dependencies (1)
-
ounit2
with-test
Optional Dependencies
None
Used by (4)
Conflicts
None
Build status
Results of building vchan with each compiler on check.ci.ocaml.org, run of against opam-repository 7cdc698. All results for this package.
Each result links to its build log. To keep crawlers from overloading the site, build logs require a GitHub sign-in (see ocurrent/opam-health-check). On your first log, GitHub asks you to “Authorize opam-health-check”, the OCurrent app that runs these checks; it sees only your public profile, not your repositories. The sign-in lasts 30 days.
| Version | OCaml 4.11 | OCaml 4.14 | OCaml 5.2 | OCaml 5.4 | OCaml 5.5 |
|---|---|---|---|---|---|
| 6.0.2 (this version) | good | good | good | good | good |
- good Package successfully built
- partial One of the dependencies failed to build
- bad Package failed to build
- n/a Package is not available in this environment
- internal Internal failure