You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Operating system (and distribution, if any): Linux
Enhancement Request
Current behavior
We are using iperf-vsock to test the performance of Firecracker's [1] vsock implementation. In Firecracker, we have implemented vsock opting for the hybrid vosck/UDS design. The guest uses an AF_VSOCK socket, whereas Firecracker by-passes the host kernel's vhost code and forwards the traffic to a Unix domain socket.
During our performance testing, we sometimes see errors like: IOError(Os { code: 104, kind: ConnectionReset, mess age: "Connection reset by peer" }) when Firecracker is trying to read from the host Unix socket file descriptor.
We are not sure what is causing this, but our best guess at the moment is that this is happening because iperf3 doesn't seem to have the machinery to terminate connections. IIUC, when a peer wants to shut down an established connection, it needs to send a VSOCK_OP_SHUTDOWN packet, but iperf3 doesn't support this. The protocol allows hooks for accept, listen, connect, send, recv and init, but there isn't any hook for terminating an established connection.
We believe that the error we see might due to the lack of properly closing connections because when we see the failures, they are always during the end of the test.
Again, I want to clarify that we are not sure that the failure we see is indeed due to this lack of API in iperf-vsock. We are opening the issue to see if anybody else has observed something similar and because we think that adding the missing functionality is worth it regardless.
Desired behavior
Add logic in iperf-vsock to handle shutting down vsock connections
Implementation notes
As a very superficial, initial, thought, we could extend struct protocol to include a hook like int (*shutdown)(struct iperf_test *). This would only be implemented by the vsock back-end.
Happy to hear thoughts
The text was updated successfully, but these errors were encountered:
Context
Enhancement Request
We are using
iperf-vsock
to test the performance of Firecracker's [1] vsock implementation. In Firecracker, we have implemented vsock opting for the hybrid vosck/UDS design. The guest uses anAF_VSOCK
socket, whereas Firecracker by-passes the host kernel's vhost code and forwards the traffic to a Unix domain socket.During our performance testing, we sometimes see errors like:
IOError(Os { code: 104, kind: ConnectionReset, mess age: "Connection reset by peer" })
when Firecracker is trying to read from the host Unix socket file descriptor.We are not sure what is causing this, but our best guess at the moment is that this is happening because iperf3 doesn't seem to have the machinery to terminate connections. IIUC, when a peer wants to shut down an established connection, it needs to send a
VSOCK_OP_SHUTDOWN
packet, but iperf3 doesn't support this. The protocol allows hooks foraccept
,listen
,connect
,send
,recv
andinit
, but there isn't any hook for terminating an established connection.We believe that the error we see might due to the lack of properly closing connections because when we see the failures, they are always during the end of the test.
Again, I want to clarify that we are not sure that the failure we see is indeed due to this lack of API in
iperf-vsock
. We are opening the issue to see if anybody else has observed something similar and because we think that adding the missing functionality is worth it regardless.Add logic in
iperf-vsock
to handle shutting down vsock connectionsAs a very superficial, initial, thought, we could extend
struct protocol
to include a hook likeint (*shutdown)(struct iperf_test *)
. This would only be implemented by the vsock back-end.Happy to hear thoughts
The text was updated successfully, but these errors were encountered: