Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am using TikaJAXRS on my server to process files, a part of Apache Tika project. I made a service wrapper to run it. So normally, I run it with service tikaserver start. But basically, the command is: /usr/bin/java -jar /usr/bin/tika-server-1.3.jar

This command launches a listener on localhost:9998. So, this is not a basic executable command, but launches a listener. This may be the point that makes it harder to follow.

I want to control it with Supervisord. I tried many methods, different wrappers and commands, but no luck.

What I tried lastly:

[program:tika]
command=/usr/bin/java -jar /usr/bin/tika-server-1.3.jar
autostart=true
autorestart=true
startsecs=0
startretries=10
redirect_stderr=true
numprocs=1
user=root

It says exited: tika (exit status 1; not expected)

There must be something about Stop signal or something else. But I am no expert with this.

Does any of you have any experience to control Tika or similar processes with Supervisord? All I need is that it should be restarted if/when it dies.

Thanks!

share|improve this question

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.