Instead of testing xeno_ssh_monitor input using a pipe to sed, use awk in the xeno_ssh command to continuously filter only initialization lines to the FIFO, minimizing what goes to the FIFO and improving performance for high-throughput SSH sessions.
For an example of how to do this in AWK, see this SO post (just search for "awk").
Instead of testing
xeno_ssh_monitor
input using a pipe tosed
, useawk
in thexeno_ssh
command to continuously filter only initialization lines to the FIFO, minimizing what goes to the FIFO and improving performance for high-throughput SSH sessions.For an example of how to do this in AWK, see this SO post (just search for "awk").