Linux FAQ

1 post / 0 new
Michael
Linux FAQ

When running virtualhere on your embedded device (e.g raspberry pi, beagle, ubuntu), it is important that you have the latest firmware. For example on the raspberry pi, run the sudo rpi-update utility.

What functionality does the VirtualHere software provide?

VirtualHere will make your USB device appear local and yet be connected in a remote location. All communication takes place transparently using a network instead of a USB cable, thereby allowing remote access to USB devices. There are many benefits to enabling remote access to USB devices, including not needing to have your USB device actually present near your computer, being able to share the device among different computers on the network or over the Internet, and being able to centrally manage USB devices in an office environment.

Can more than one client use the same USB device simultaneously?

No, not physically possible

How to i start VirtualHere when my device boots?

For init.d based systems (Raspberry pi, Ubuntu...):

You need to put a startup script into init.d and set the correct runlevel for booting. To do this, please follow the steps below for the raspberry pi:

  1. ssh to your raspberry pi
  2. wget https://www.virtualhere.com/sites/default/files/usbserver/vhusbdarm
  3. sudo chmod +x ./vhusbdarm
  4. sudo mv vhusbdarm /usr/sbin
  5. wget http://www.virtualhere.com/sites/default/files/usbserver/scripts/vhusbdpin
  6. sudo chmod +x ./vhusbdpin
  7. sudo mv vhusbdpin /etc/init.d
  8. sudo update-rc.d vhusbdpin defaults
  9. sudo reboot

Note: for other architectures you will need to download a different file (see table) in Step 2 and change the NAME entry in the file downloaded in step 5 so they match

For systemd based systems (e.g Beaglebone):

Create a text file /etc/systemd/system/virtualhere.service with the following contents

[Unit]
Description=VirtualHere USB Sharing
Requires=avahi-daemon.service
After=avahi-daemon.service
[Service]
ExecStartPre=/bin/sh -c 'logger VirtualHere settling...;sleep 1s;logger VirtualHere settled'
ExecStart=/usr/bin/vhusbdarmhf
Type=idle
[Install]
WantedBy=multi-user.target

Then:

  1. systemctl daemon-reload
  2. systemctl enable virtualhere
  3. systemctl start virtualhere

VirtualHere sometimes takes a lot of CPU why is that?

Converting the USB protocol and communicating it over the network is quite CPU intensive and therefore CPU usage will spike while the USB device is being accessed. This is only temporary and not a problem.

What are the server arguments?

You can find the arguments by running the server with the -h command.

For example on the raspberry pi:

pi@raspberrypi:~ $ ./vhusbdarmpi3 -h
vhusbdarmpi3 v3.2.9
VirtualHere USB Server for Raspberry Pi (Optimized build)
Share USB Devices over the network
(C) VirtualHere Pty. Ltd 2010-2017
https://www.virtualhere.com

usage: vhusbdarmpi3 [-hlbiu] [-c ] [-r ]

options:
   -b run as daemon in the background
   -c configuration file
   -h display this usage
   -l display license text
   -i prefer ipv6 (dual/stack)
   -r log to file instead of syslog

How do i edit the settings for the server?

See here for more information

How do i edit the settings for the Client?

The client has several command line options and configurable settings, see here for more information

Does the server support IPv6?

Yes

Does VirtualHere require Internet access to run?

No, Internet access is not required.

How can i control who has access to what devices?

See here for information

My Android device doesn't have a USB socket?

Most recent or larger Android devices have USB host enabled in the kernel, and a Micro USB slot. You need to have a Micro USB to Host OTG cable such as this http://www.amazon.com/Electronics-Micro-USB-OTG-Cable/dp/B005GGBYJ4 to convert the socket.

What Linux library dependencies does the VirtualHere USB Server require?

None!

My device only has two USB ports, I want to share more devices!

Just plug in a USB hub and VirtualHere will then share all devices connected to that hub as well. The server supports up to 122 devices and 5 hubs deep.

Can I share my USB devices over the Internet?

Yes

What are the licensing terms?

The terms can be found here

TLDR: The license basically says if you are an end user you can share one device for free using a Generic build of the VirtualHere USB Server. If you want to resell VirtualHere (on your device), or you are an end user and want to share unlimited USB devices from your server, or you want to use a CPU optimized build of VirtualHere you need to purchase a license.

My server is behind a NAT/Firewall how can my client access the server?

If your server does not have a public IP or is behind a firewall and your client(s) have public IP's you can use a "reverse connection", where the server initiates the connection to the client instead. In the Client, right click USB Hubs -> Specify Hubs -> Firewall/NAT -> Enable Reverse Connections. On the Server, edit the config.ini file and add the list of client IP's to the ReverseClients setting. With this setting the server will initiate a connection to each client listed, and the client will be listening for this connection. If the server cannot connect to the client, it will keep trying every 15 seconds. See here for more information