on 2018 Sep 25 10:06 PM
Hi,
I'm trying to create a systemd service script on RHEL7 to shutdown/startup the SAP app automatically if the server gets rebooted. I saw already some forums that talk about it, but didn't find a solution that works for my script.
Below, is the systemd service script that I'm using and it works for the startup of the SAP app, but not for the shutdown... As soon as I try to reboot the server, all the services are killed immediately without running the "ExecStop" command on the script.
Could you give me some light on how to solve this issue?
[Unit]
Description=SAP.service
After=local-fs.target network.target network-online.target
[Service]
Type=simple
RemainAfterExit=true
Environment="SID1=SID" "DAA=DAA"
KillMode=none
SendSIGKILL=no
ExecStart=/usr/bin/python /usr/sap/scripts/SAPstart.py
ExecStop=/usr/bin/python /usr/sap/scripts/SAPstop.py
TimeoutSec=60
[Install]
WantedBy=multi-user.target
Thanks in advance,
Carlos
Request clarification before answering.
Hi Carlos,
facing the same problem !!
Did you overcome ? if yes then how
Thanks
Moti
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 18 | |
| 7 | |
| 6 | |
| 6 | |
| 6 | |
| 4 | |
| 3 | |
| 3 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.