Я думаю, что вы можете решить эту проблему с помощью "раздельного туннелирования". В основном, какой-то трафик через VPN, а какой-то нет.
Судя по быстрому поиску, HMA может этого не предложить. из:https://vpn-services.bestreviews.net/vpn-comparison-hidemyass-vs-purevpn/:
An additional feature offered by PureVPN is Split Tunneling, where you have the option to use only certain applications through the VPN, while sending other information through your local LAN or WAN. This gets rid of the cumbersome need to disconnect and reconnect to the server if you want to access a corporate network or have some programs that do not work well with a VPN.
Наша корпоративная сеть VPN использует разделенный туннель. Таким образом, корпоративный трафик проходит через VPN, но пропускная способность для видео на YouTube, которые смотрят люди, не будет.
В вашем случае, если вы используете PureVPN, вы можете настроить его так, чтобы только одно приложение проходило через VPN, или все приложения, кроме одного, проходили через vpn.
Как использовать PureVPN для этого:https://www.youtube.com/watch?v=6eII1xUeO18
Лучшее объяснение раздельного туннелирования:https://www.youtube.com/watch?v=dFGAXSUSsVg
Похоже, у вас много ssh-соединений...
Попробуйте это,
#!/usr/bin/bash
GREEN=0
YELLOW=1
RED=2
pid=(`/bin/ps -eo fname,pid | /usr/bin/awk '{ if ($4 == "abc") print $2}'`)
if [ ${#pid[@]} -gt 0 ]
then
message="sshd Server is running. PID: ${pid[@]}"
status=$GREEN
else
message="sshd Server is stopped."
status=$RED
fi
echo $message
exit $status
если вам нужен только PID службы ssh, попробуйте следующее
#!/usr/bin/bash
GREEN=0
YELLOW=1
RED=2
pid=`cat /var/run/sshd.pid`
if test $pid
then
message="sshd Server is running. PID: $pid"
status=$GREEN
else
message="sshd Server is stopped."
status=$RED
fi
echo $message
exit $status