Delay a respawn of a service
Clash Royale CLAN TAG#URR8PPP
up vote
0
down vote
favorite
How can I delay the start of my service using respawn?
I am configuring my service in inittab like this:
vpn:2345:respawn:/etc/init.d/openvpn restart
and I am getting respawn too fast error and the service is disabled for 5 minutes.
how can I make respawn wait some time before trying to restart the service?
I am running a custom distribution of linux for ARM architecture (debian packages for ARM can be installed in this distribution)
linux kernel is : linux-3.10.x
Thanks!
services sysvinit
 |Â
show 1 more comment
up vote
0
down vote
favorite
How can I delay the start of my service using respawn?
I am configuring my service in inittab like this:
vpn:2345:respawn:/etc/init.d/openvpn restart
and I am getting respawn too fast error and the service is disabled for 5 minutes.
how can I make respawn wait some time before trying to restart the service?
I am running a custom distribution of linux for ARM architecture (debian packages for ARM can be installed in this distribution)
linux kernel is : linux-3.10.x
Thanks!
services sysvinit
Don't run it frominit
, rather install something like DJB'sdaemontools
.
â Satà  Katsura
Sep 25 '17 at 17:09
make a cron job for stopping and another for starting it at another time
â Joe
Sep 25 '17 at 17:18
You already asked this at unix.stackexchange.com/questions/394332 .
â JdeBP
Sep 25 '17 at 17:55
The init.d scripts return very quickly. They don't work well in an inittab respawn entry. The regular init system ought to be able to handle what you want. What Linux or Unix distribution and version number are you running?
â Mark Plotnick
Sep 25 '17 at 18:32
@JdeBP No, she didn't.
â Hauke Laging
Sep 25 '17 at 18:53
 |Â
show 1 more comment
up vote
0
down vote
favorite
up vote
0
down vote
favorite
How can I delay the start of my service using respawn?
I am configuring my service in inittab like this:
vpn:2345:respawn:/etc/init.d/openvpn restart
and I am getting respawn too fast error and the service is disabled for 5 minutes.
how can I make respawn wait some time before trying to restart the service?
I am running a custom distribution of linux for ARM architecture (debian packages for ARM can be installed in this distribution)
linux kernel is : linux-3.10.x
Thanks!
services sysvinit
How can I delay the start of my service using respawn?
I am configuring my service in inittab like this:
vpn:2345:respawn:/etc/init.d/openvpn restart
and I am getting respawn too fast error and the service is disabled for 5 minutes.
how can I make respawn wait some time before trying to restart the service?
I am running a custom distribution of linux for ARM architecture (debian packages for ARM can be installed in this distribution)
linux kernel is : linux-3.10.x
Thanks!
services sysvinit
services sysvinit
edited Sep 26 '17 at 7:02
asked Sep 25 '17 at 17:07
sabrina2020
10417
10417
Don't run it frominit
, rather install something like DJB'sdaemontools
.
â Satà  Katsura
Sep 25 '17 at 17:09
make a cron job for stopping and another for starting it at another time
â Joe
Sep 25 '17 at 17:18
You already asked this at unix.stackexchange.com/questions/394332 .
â JdeBP
Sep 25 '17 at 17:55
The init.d scripts return very quickly. They don't work well in an inittab respawn entry. The regular init system ought to be able to handle what you want. What Linux or Unix distribution and version number are you running?
â Mark Plotnick
Sep 25 '17 at 18:32
@JdeBP No, she didn't.
â Hauke Laging
Sep 25 '17 at 18:53
 |Â
show 1 more comment
Don't run it frominit
, rather install something like DJB'sdaemontools
.
â Satà  Katsura
Sep 25 '17 at 17:09
make a cron job for stopping and another for starting it at another time
â Joe
Sep 25 '17 at 17:18
You already asked this at unix.stackexchange.com/questions/394332 .
â JdeBP
Sep 25 '17 at 17:55
The init.d scripts return very quickly. They don't work well in an inittab respawn entry. The regular init system ought to be able to handle what you want. What Linux or Unix distribution and version number are you running?
â Mark Plotnick
Sep 25 '17 at 18:32
@JdeBP No, she didn't.
â Hauke Laging
Sep 25 '17 at 18:53
Don't run it from
init
, rather install something like DJB's daemontools
.â Satà  Katsura
Sep 25 '17 at 17:09
Don't run it from
init
, rather install something like DJB's daemontools
.â Satà  Katsura
Sep 25 '17 at 17:09
make a cron job for stopping and another for starting it at another time
â Joe
Sep 25 '17 at 17:18
make a cron job for stopping and another for starting it at another time
â Joe
Sep 25 '17 at 17:18
You already asked this at unix.stackexchange.com/questions/394332 .
â JdeBP
Sep 25 '17 at 17:55
You already asked this at unix.stackexchange.com/questions/394332 .
â JdeBP
Sep 25 '17 at 17:55
The init.d scripts return very quickly. They don't work well in an inittab respawn entry. The regular init system ought to be able to handle what you want. What Linux or Unix distribution and version number are you running?
â Mark Plotnick
Sep 25 '17 at 18:32
The init.d scripts return very quickly. They don't work well in an inittab respawn entry. The regular init system ought to be able to handle what you want. What Linux or Unix distribution and version number are you running?
â Mark Plotnick
Sep 25 '17 at 18:32
@JdeBP No, she didn't.
â Hauke Laging
Sep 25 '17 at 18:53
@JdeBP No, she didn't.
â Hauke Laging
Sep 25 '17 at 18:53
 |Â
show 1 more comment
1 Answer
1
active
oldest
votes
up vote
-1
down vote
If a service crashes on restart then it is not going to work if you delay its restart. But you can do that by putting a wrapper script in inittab
that looks like this:
#! /bin/bash
sleep 60
exec /path/to/service
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
-1
down vote
If a service crashes on restart then it is not going to work if you delay its restart. But you can do that by putting a wrapper script in inittab
that looks like this:
#! /bin/bash
sleep 60
exec /path/to/service
add a comment |Â
up vote
-1
down vote
If a service crashes on restart then it is not going to work if you delay its restart. But you can do that by putting a wrapper script in inittab
that looks like this:
#! /bin/bash
sleep 60
exec /path/to/service
add a comment |Â
up vote
-1
down vote
up vote
-1
down vote
If a service crashes on restart then it is not going to work if you delay its restart. But you can do that by putting a wrapper script in inittab
that looks like this:
#! /bin/bash
sleep 60
exec /path/to/service
If a service crashes on restart then it is not going to work if you delay its restart. But you can do that by putting a wrapper script in inittab
that looks like this:
#! /bin/bash
sleep 60
exec /path/to/service
answered Sep 25 '17 at 18:57
Hauke Laging
53.7k1282130
53.7k1282130
add a comment |Â
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f394357%2fdelay-a-respawn-of-a-service%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Don't run it from
init
, rather install something like DJB'sdaemontools
.â Satà  Katsura
Sep 25 '17 at 17:09
make a cron job for stopping and another for starting it at another time
â Joe
Sep 25 '17 at 17:18
You already asked this at unix.stackexchange.com/questions/394332 .
â JdeBP
Sep 25 '17 at 17:55
The init.d scripts return very quickly. They don't work well in an inittab respawn entry. The regular init system ought to be able to handle what you want. What Linux or Unix distribution and version number are you running?
â Mark Plotnick
Sep 25 '17 at 18:32
@JdeBP No, she didn't.
â Hauke Laging
Sep 25 '17 at 18:53