View Issue Details

IDProjectCategoryView StatusLast Update
0007017CentOS-6upstartpublic2014-03-11 00:32
Status newResolutionopen 
Platformx86_64OSCentOSOS Version6.5
Product Version6.5 
Target VersionFixed in Version 
Summary0007017: Upstart docs and reality appear to be different
DescriptionThere is very little useful information, either here in CentOS or upstream, on how to build a init.conf file from an inittab entry. Nothing saying "this is how you get started, and get the same results." So I built a toy application and wrote an init.conf script, and have run into all sorts of issues. Here is my toy:

# Test replacement for inittab
# sl:345:respawn:/bin/sleep 150
# "If init(8) finds that it's continuously respawning an entry
# more than 10 times in 2 minutes, it will...refuse to respawn
# this entry..."

start on runlevel [345]

stop on runlevel [S0126]

# respawn limit <count> <interval-seconds>
#respawn limit 10 120
exec /bin/sleep 150

pre-start script
  echo `/bin/date` "init: Start my sleepy daemon" >>/var/log/messages
end script

post-stop script
  echo `/bin/date` "init: Stop my sleepy daemon" >>/var/log/messages
end script
Steps To Reproduce1. Install and boot CentOS
2. Install toy script as /etc/init/sleepy.conf
3. Reboot the system
4. Monitor /var/log/messages, initctl status sleepy, "ps ax | egrep '[s]leep 150'

The toy script as it stands appears to work in its current form. It respawns.

Replacing "respawn" with "respawn limit 10 120" does NOT work. It launches once and then it sits there with "initctl status sleepy" reporting "stopped/waiting". I expect it, in this toy script, to behave exactly the same as the bare "respawn". note the quote from the pre-6 documentation for init(8) describing how the old system worked.

What i would like to see is a script that works EXACTLY like what we had on the inittab entry, that will do my little toy the same way on Centos 5 and Centos 6.5. Thank you.
Additional InformationI'm running this on 6.5; the pull-down for "Product Version" only goes to 6.4.

Most of the information about upstart applies to Unbuntu. The upstream user community has provided some information, but nothing says "take this inittab entry and build THIS file." Ditto the upstart site. (at least as far as I could find.)
TagsNo tags attached.




2014-03-11 00:32

reporter   ~0019492

When I submitted the bug, I didn't know where to put in the priority queue. Judging from the amount of traffic (and apparent mis-infomration), the priority on this bug could be higher, seeing as we sysadmins are going to be stuck with CentOS until 2022. It's a documentation thing mostly, although there might be code bugs, or at least code out of specification.

Issue History

Date Modified Username Field Change
2014-03-05 18:19 satch New Issue
2014-03-06 18:42 tigalch Product Version 6.4 => 6.5
2014-03-11 00:32 satch Note Added: 0019492