IPC fgets failed, error 0 (No error information)

I get the error "VirtualHere Client: IPC fgets failed, error 0 (No error information)" in the syslog pretty consistently, which necessitates a restart of the service.

This is running on Debian 8, and I am communicating with VirtualHere via the named pipes client API from a Java application. Given the error from VirtualHere is "fgets failed", I assume that I am breaking the /tmp/vhclient pipe somehow.

I have tried writing to the stream via:
a) Java FileOutputStream
b) JNA (using fopen, fputs, fclose)
c) simply shelling out and using echo to write to the pipe

I am reading the /tmp/vhclient_response stream via Java FileInputStream. I've left that piece alone.

Same error each time, it usually takes a few connects+disconnects to get it to occur. Sometimes it's after a hub add, sometimes after disconnect, it seems like it'll happen anytime.

As a side note, I wrote a bash script to simply echo a series of commands one after the other to the pipe while tailing the response pipe in another window, and that it rock solid.

Do you have any clues you can offer/things to check? Can you verify that this is a fail on the /tmp/vhclient pipe and not the response? I'm open to ideas.

Thanks.

#3

That wasn't exactly it, but it gave the clue to track it down.

I was tacking a newline on all of my commands - I shouldn't have been. Once I removed that, it's running smooth as can be.

So basically, issue between my keyboard and chair. Many thanks.