Run Kibana in Linux as a service

I'm accessing a Linux VM through a terminal and I want to run Kibana as a service, so when I exit it will still be running.

What are the best ways to do this? Write a script?

Your question looks similar to this past post, which may provide some helpful suggestions: Running kibana as a service on Linux

I don't have root access to do service start so that's not an option to me.

Usually a supervisor process (e.g. the init system) is used to reliably run any daemon for a long time. Without root permissions it is usually not possible to register new processes with the init system. If your linux distribution uses systemd as the init process and is configured to use lingering user sessions, you might be able to use that to avoid the need for root permissions.

Could you give us more details about your deployment environment and requirements?

Linux machine in stage and uses sysvinit. I do not have root access and network access but I can transfer files to the machine.

I've set up the ELK stack and it runs, and I am able to set ElasticSearch and Filebeat to run as service. Just not sure how to do the same for Kibana-5.4.0-linux-x86_64.

So you just want to start Kibana in the background. There is no built-in support for that, because there is the nohup posix tool, that does that. From a shell you should be able to just execute

$ nohup bin/kibana &

from the directory Kibana was unpacked into.

Alternatively you can use a tool like screen or tmux to create a long-lived shell session, that can be detached from.

I want to point out again, that this is not a recommended way of running any service reliably. The official deb or rpm packages provide init scripts and unit files for proper integration with some popular init systems and supervisors.

Thanks. Don't dep or rpm packages requires root access to run or configure the files?

Yes, they do. And that is by design, because you don't want an unprivileged user to be able to modify the system in such a way that it might impact stability or security of the system overall.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.