Stop Using "failing" but actually succeeding?

So I'm running VirtualHereUniversal as a service on a MacOS Virtual Machine. I have a USB dongle that I connect to with 
VirtualHereUniversal -t "USE,<address>"

I get OK, then I disconnect with

VirtualHereUniversal -t "STOP USING,<address>"

And I get FAILED and if I immediately VirtualHereUniversal -t "LIST" it will say the device is still in-use by me, but if I wait around 1 second and list the devices again it will show it is no longer in use by me.

This maybe because the device is an iLok USB which is interacting with iLok license manager which is delaying the disconnect process? Either way if I could just give the stop using a longer timeout so it didn't report failure when it actually succeeded that would be great, or if I'm doing something wrong then that would also be good to know!

Worst comes to worse I could do some check to see if it has actually failed with a LIST but I'd prefer not to if I can avoid it! Thanks in advance for any replies!

 

#2

What type of OS/machine are you running the virtualhere server on?

#3

I'm running the server on a raspberry pi with the linux raspberry pi OS (which I think is a form of debian?)

#4

Ok it looks like I'm running into this: Note that there is a 5 second timeout to the response. If the api call takes more than 5 seconds it will return FAILED regardless.

Here: Client API | VirtualHere

Anyway to extend that timeout?

#5

It shouldnt take 5+ seconds to stop using an iLok. This is why i was asking what OS/server you are using. A pi should be very quick. 

Can you take a look in syslog (or journalctl) and grep for vhusbd and then find the time when the ilok is stopped being used. Can you paste that part of the log here. Does that show 5+ seconds between operations?

 

#6

Here's the log of when the commands are being called on the client:

14:31:07  + VirtualHereUniversal -t USE,waveshare-pi.1121

14:31:07  OK

[...]

14:32:12  + VirtualHereUniversal -t 'STOP USING,waveshare-pi.1121'

14:32:15  FAILED

Here's the corresponding server logs:

Jul 08 14:20:53 waveshare-pi vhusbdarm64[560]: 10.1.101.51 connected as connection 124 (Standard TCP)
Jul 08 14:31:07 waveshare-pi vhusbdarm64[560]: Device 1121 [088e:5036] BOUND to connection 124
Jul 08 14:32:17 waveshare-pi vhusbdarm64[560]: Device 1121 [088e:5036] UNBOUND from connection 124
Jul 08 14:32:17 waveshare-pi vhusbdarm64[560]: Unmanaging device 1121 [088e:5036]
Jul 08 14:32:17 waveshare-pi vhusbdarm64[560]: Found Full speed device [088e:5036] "iLok, iLok" at address 1121

It looks like the client is noping out before the server does anything? Not entirely sure. It may also be due to the VM being a bit on the slow side, or the pi which is running USB 2.0 could be slowing it down as well.

#7

That is strange. It does looks like the client is delaying by those 5 seconds. What about if you stop using from the GUI client (and dont use the API)? Is that ok then, is it quick to stop using?