0

There is service named filebeat. It works on oracle linux 6.8 machine,

chkconfig --list 

it does not show but when run this command

ps -ef | grep filebeat

ps -ef | grep filebeat root 2583 18280 0 10:10 pts/7 00:00:00 grep filebeat root 14456 1 0 Mar27 ? 00:00:00 /usr/share/filebeat/bin/filebeat-god -r / -n -p /var/run/filebeat.pid --

/usr/share/filebeat/bin/filebeat -c /etc/filebeat/filebeat.yml -path.home /usr/share/filebeat -path.config /etc/filebeat -path.data /var/lib/filebeat -path.logs /var/log/filebeat

root 14457 14456 2 Mar27 ? 16:41:54 /usr/share/filebeat/bin/filebeat -c /etc/filebeat/filebeat.yml -path.home /usr/share/filebeat -path.config /etc/filebeat -path.data /var/lib/filebeat -path.logs /var/log/filebeat

I can see that the service is working and I also could not find in /etc/init.d

And I checked the log file it writes into log file.

lsof filebeat returns;

COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME

filebeat 14457 root 2w REG 252,1 8995935 529475 filebeat

and

  ps p 14457

  PID TTY      STAT   TIME COMMAND

  14457 ?        Sl   1001:57 /usr/share/filebeat/bin/filebeat -c 

  /etc/filebeat/filebeat.yml -path.home /usr/share/filebeat -path.config 

  /etc/filebeat -path.data /var/lib/filebeat -path.logs /var/log/fileb

how can I find where is the location of filebeat service file in order to start or stop?

5
  • systemd command works on redhat 7 OS not for redhat 6.8 OS Apr 25, 2018 at 7:38
  • My oversight... Could it be installed manually then? Apr 25, 2018 at 7:39
  • No it can not be,it designed for RHEL 7. Apr 25, 2018 at 7:42
  • Use the lsof command ti dicipher the process writing to the log file and work your way back from there. Apr 25, 2018 at 9:21
  • lsof filebeat command returns; filebeat 14457 root 2w REG 252,1 8995935 529475 filebeat ps p 14457 14457 ? Sl 1001:57 /usr/share/filebeat/bin/filebeat -c /etc/filebeat/filebeat.yml -path.home /usr/share/filebeat -path.config /etc/filebeat -path.data /var/lib/filebeat -path.logs but I am still not able start or stop service. I have already known that the service is working but the problem is not to find service binary in order to start or stop Apr 25, 2018 at 10:24

1 Answer 1

0

If it's a port-based service, you can use netstat.

netstat -tulpn | grep filebeat 

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .