Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Solr dead but pid file exists #3

Closed
brandon-lile opened this issue Jul 13, 2012 · 8 comments
Closed

Solr dead but pid file exists #3

brandon-lile opened this issue Jul 13, 2012 · 8 comments

Comments

@brandon-lile
Copy link

For some reason, when using these scripts, on the first run, I always get 'solr dead but pid file exists'. It never happens from then on however. I have tested this on multiple boxes (10+), and they all have the same result. Doesn't work initially, but works everytime after.

All are CentOS 6.2 boxes incase you were curious. Any ideas?

@jbusby
Copy link
Owner

jbusby commented Jul 13, 2012

Did you have Solr running on these boxes prior to installing this script? It will look for /var/run/solr.pid when you run the start command, if that file already existed you would get this message.

@brandon-lile
Copy link
Author

I'll give it a shot and reply back with my results

@brandon-lile
Copy link
Author

There is not a pid file for solr beforehand

@brandon-lile
Copy link
Author

This is very strange. It seems as if I have to wait a certain amount of time after running chkconfig. I ran chkconfig through fabric, then ssh'd into the box and manually started it and it worked.

@jbusby
Copy link
Owner

jbusby commented Jul 13, 2012

Can you post the fabric script?

@brandon-lile
Copy link
Author

The whole thing is huge. I'll just post the necessary area

# place init script for solr
put('install/solr.initd', '/etc/init.d/solr', use_sudo=True)
put('install/solr.start', '/opt/solr/example/solr.start')
put('install/solr.conf', '/etc/solr.conf', use_sudo=True)
sudo('chmod +x /etc/init.d/solr')
sudo('chmod +x /opt/solr/example/solr.start')
append('/etc/profile', 'export JAVA_HOME=/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre', use_sudo=True)
sudo('sudo chkconfig --add solr')
sudo('service solr start')

The file has already been configured

EDIT*
It's not a matter of time. If I'm ssh'd into the box and run service solr start directly after the fabfile finishes, it works correctly.

@jbusby
Copy link
Owner

jbusby commented Jul 13, 2012

I'm assuming the problem occurs on the last line? I only have a centos 5 VM to test on right now and I can't recreate issue. I have a centos 6 VM at home, I'll have a look tonight. In the mean time if you find the solution please let me know.

@jbusby
Copy link
Owner

jbusby commented Jul 12, 2013

I'm closing this, as I'm unable to recreate it.

@jbusby jbusby closed this as completed Jul 12, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants