Problem:
Under “Hosts” - “All Hosts”, the column “Boot time” displays incorrect values.
It never gets updated.
Running uptime on the host reveals a discrepancy. It is incorrect for all hosts.
Boot time comes out of facts delivered by the client. REX runs jobs. It doesn’t handle facts. You’ll have to run puppet or ansible for information/facts about the clients.
Admittedly, this server is quite new, and Foreman is new to me.
I must have missed something in the installation documentation, as the Foreman host doesn’t seem to have any facts-gathering mechanisms in place.
1:
/var/tmp/foreman-ssh-cmd-e7f7d154-44c9-49a3-9e92-5e013f9472a7/script: line 1: puppet: command not found
2:
Exit status: 127
Is there a way to gather facts without installing anything on remote machines?
Is there good documentation that will compare Foreman’s Puppet vs. Ansible integration, so that I can decide what’s best for me?
The whole “gathering of hosts facts” process seems to be somewhat hidden feature of Foreman since the “facts” do seem to be updated by some service/command that runs on the hosts when you issue an update of packages for example. I assume this can also be triggered manually?
I sill didn’t find a solution.
The document isn’t clear how facts gathering is scheduled, when Ansible is used.
Is it Foreman who’s supposed to gather facts from hosts on schedule?
Or is it the Ansible Manager (which in my case is on the Foreman host) which is supposed to gather facts on schedule?
Or is it the managed hosts, which should connect to Foreman’s Ansible Component using ssh to push their facts to the Foreman server?
In the latter case, I don’t want it work, because the “inbound” SSH port from remote hosts to Foreman is blocked for security reasons.
If I select all hosts and “Run all Ansible roles” manually, facts are gathered and updated. Ideally, I’d like to have a scheduler on Foreman which does scheduled facts gathering.
If that’s impossible, I will be forced to use Puppet, which at this time is not yet installed on remote hosts.
It seems to be possible to schedule a facts gathering job on Foreman, which will rely on Ansible.
Although, maybe, this may not be the best way of doing it?
Question to Foreman specialists: is there a better way of doing it?