[ssh_exec] refactor to not need /dev/stdin

/dev/stdin is not available on AIX
[tomcat] fix case where catalina.sh version is not available again