3

Well, I'm running Ubuntu 12.04.2 and I have Thin installed by

gem install thin
sudo thin install
sudo /usr/sbin/update-rc.d -f thin defaults

and I have my configs at /etc/thin.

But after system reboot thin processes are not started unless I run sudo service thin start.

While running sudo /usr/sbin/update-rc.d -f thin defaults I got a warning:

update-rc.d: warning: thin stop runlevel arguments (0 1 6) do not match LSB Default-Stop values (S 0 1 6)

But after changing # Default-Stop: S 0 1 6 to # Default-Stop: 0 1 6 (without S) warning dissappeared. But this doesn't solve the problem.

Aso tried to reinstall thin, but problem still appears.

My Rails application thin log says:

>> Writing PID to tmp/sockets/shashechki_thin.0.pid
>> Using rack adapter
>> Thin web server (v1.5.1 codename Straight Razor)
>> Maximum connections set to 1024
>> Listening on /home/deploy/projects/shashechki/shared/sockets/shashechki_thin.0.sock, CTRL+C to stop
>> Writing PID to /home/deploy/projects/shashechki/shared/pids/shashechki_thin.0.pid
>> Using rack adapter
>> Thin web server (v1.5.1 codename Straight Razor)
>> Maximum connections set to 1024
>> Listening on /home/deploy/projects/shashechki/shared/sockets/shashechki_thin.0.sock, CTRL+C to stop
>> Exiting!
kishie
  • 151
  • 7
  • I noticed the same behaviour on Debian Wheezy and Thin installed with `thin install`. After trying many configurations and several update-rc.d setups I bypassed by putting the line `/etc/init.d/thin start` in /etc/rc.local. – fsoppelsa Jul 01 '13 at 12:13
  • You just put `/etc/init.d/thin start` before `exit 0`? If so this doen't help me :( – kishie Jul 01 '13 at 12:45

1 Answers1

2

While using RVM you have to create an rvm wrapper for thin with

rvm wrapper <ruby_version>@<gemset> bootup thin

and edit DAEMON variable at /etc/init.d/thin. The actual solution I found here

kishie
  • 151
  • 7