diff --git a/packaging/dependencies/amazon-cloudwatch-agent-ctl b/packaging/dependencies/amazon-cloudwatch-agent-ctl index df5e381f7a..b972dd307d 100755 --- a/packaging/dependencies/amazon-cloudwatch-agent-ctl +++ b/packaging/dependencies/amazon-cloudwatch-agent-ctl @@ -158,7 +158,7 @@ agent_stop() { fi if [ "${SYSTEMD}" = 'true' ]; then - service "${agent_name}" stop || return + systemctl stop "${agent_name}.service" || return else stop "${agent_name}" || return fi