Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit e45f1c5

Browse files
committedSep 21, 2020
Add SuccessExitStatus=100 to atuned.service
call os.Exit(100) when get killed signal Fix https://gitee.com/openeuler/A-Tune/issues/I1VCQY?from=project-issue Signed-off-by: Zhipeng Xie <[email protected]>
1 parent 4fb7a1b commit e45f1c5

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed
 

‎common/service/pyservice/pyservice.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@
1414
package pyservice
1515

1616
import (
17+
"bufio"
1718
"gitee.com/openeuler/A-Tune/common/config"
1819
"gitee.com/openeuler/A-Tune/common/log"
1920
"gitee.com/openeuler/A-Tune/common/registry"
20-
"bufio"
2121
"io"
2222
"os"
2323
"os/exec"
@@ -94,5 +94,5 @@ func listenToSystemSignals(cmd *exec.Cmd) {
9494
signal.Notify(signalChan, os.Interrupt, syscall.SIGTERM)
9595
<-signalChan
9696
_ = syscall.Kill(-cmd.Process.Pid, syscall.SIGKILL)
97-
os.Exit(-1)
97+
os.Exit(100)
9898
}

‎misc/atuned.service

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Requires=polkit.service
66
[Service]
77
Type=notify
88
ExecStart=/usr/bin/atuned
9+
SuccessExitStatus=100
910

1011
[Install]
1112
WantedBy=multi-user.target

0 commit comments

Comments
 (0)
Please sign in to comment.