OK, I seem to have found the root cause of the issue... in case someone needs this.
The module tries to determine which is the best way to gather the list of services (comands: service --status-all or initctl list or chkconfig --list). It seems like the service --status-all fails, since this command tends to output some additional infos for some services. iptables etc.
I'm not python expert, but this block is just my guessing I might be wrong:
for line in stdout.split("\n"):
line_data = line.split()
if len(line_data) < 4:
continue # Skipping because we expected more data
and so, it ends up gathering the list from chkconfig --list output.
Seems like there is no ideal way of handling this situation, and authors already came up with all the possible solutions :(
Now, the only thing I can think of right now, is to simply go through the list of all init scripts in /etc/init.d and do a service [
service.name] status, and then inspect the exit code and deciding upon that what is the state of the service... ==0 or !==0
I guess I'll have to learn more about python in the next few days in order to write something like this.
Hope this will help if someone comes across the same issue...
On Thursday, April 19, 2018 at 2:37:00 PM UTC+2, Stevan Svilokos wrote: