쉘 스크립트는 작동하지만 시스템 서비스로는 작동하지 않습니다.

쉘 스크립트는 작동하지만 시스템 서비스로는 작동하지 않습니다.

systemctl status그리고 journelctl -xe성공을 보여줍니다. 그러나 ps -A"cat"은 존재하지 않지만 쉘 스크립트를 실행하는 것만으로도 잘 작동합니다.

#!/bin/bash
/bin/stty  -F /dev/ttyS4 raw -echo  921600
/bin/stty  -F /dev/ttyGS0 raw -echo 9600
/bin/cat /dev/ttyS4 > /dev/ttyGS0&
/bin/cat /dev/ttyGS0 > /dev/ttyS4&
echo 'cat serial ports done'

[Unit]
Description=cats commands

[Service]
Type=simple
ExecStart=/bin/bash  /catscripts.sh

[Install]
WantedBy=multi-user.target

관련 정보