!["systemctl restart"와 "systemctl start"의 차이점은 무엇입니까?](https://linux55.com/image/6055/%22systemctl%20restart%22%EC%99%80%20%22systemctl%20start%22%EC%9D%98%20%EC%B0%A8%EC%9D%B4%EC%A0%90%EC%9D%80%20%EB%AC%B4%EC%97%87%EC%9E%85%EB%8B%88%EA%B9%8C%3F.png)
두 개의 서비스 A와 B가 있습니다. 여기서 B는 A에 의존합니다. 이는 A의 서비스 단위에서 After와 Requires를 B로 설정했음을 의미합니다.
After=B.service
Requires=B.service
이제 B 서비스를 중지하면 서비스 A도 중지됩니다. 그러면 B를 시작할 때 중지한 후 서비스 A가 시작되지 않아 수동으로 시작해야 합니다.
systemctl stop B (A is also stopped)
systemctl start B (A is not started)
systemctl start A (I have to start A manually)
그러나 서비스 A가 중지되고 서비스 B를 다시 시작하면 B와 A가 모두 systemctl에 의해 시작됩니다.
systemctl stop A
systemctl restart B (B and A both are started)
내 질문은 서비스 장치 유형 A의 경우 시작과 다시 시작의 차이점이 무엇입니까?