[
https://issues.apache.org/jira/browse/NIFI-1069?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15604506#comment-15604506
]
ASF GitHub Bot commented on NIFI-1069:
--------------------------------------
Github user michalklempa commented on the issue:
https://github.com/apache/nifi/pull/1093
@JPercivall Oh my god. Thank you Joe for figuring this out. The problem is
apparently on line
https://github.com/apache/nifi/commit/99d3c397481a98a5b3d2d4e44b84516fc0e3675e#diff-0242d48c1b4267348183977fd0cf8966R305
where I immediately exit the script with proper exit status. This works for
stop and start, but since restart action calls the 'run' function twice, the
exit directive only does 'stopping' and immediately exits.
I will fix this later today and push to a new Pull Request as this change
had already been merged.
> Nifi Service Status return 0 when service not running
> -----------------------------------------------------
>
> Key: NIFI-1069
> URL: https://issues.apache.org/jira/browse/NIFI-1069
> Project: Apache NiFi
> Issue Type: Bug
> Components: Core Framework
> Affects Versions: 0.3.0
> Environment: CentOS 6.7
> Reporter: Andy Kruth
> Assignee: Andre
> Priority: Minor
> Fix For: 1.1.0
>
>
> After successfully installing Nifi as a service with the following command:
> sudo /opt/nifi-0.3.0/bin/nifi.sh install
> running service nifi status has a return code of 0.
> According to
> http://refspecs.linuxbase.org/LSB_3.1.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html
> if the service is not running then status should return 3.
> This is not a major issue, you can still start and stop the service just
> fine, but when using an idempotent tool like Ansible you cannot start the
> service because the return code of status says the service is already started.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)