After I updated the OS for some of my agents, some of the agents are not responding in the console. When I run the agent on the node manually, it shows up for about an hour, and goes back to not responding.
Error messages and logs
On the agent, in /var/log/messages
, an error similar to the following:
Oct 1 15:21:36 agentnode puppet-agent[11680]: Unable to fetch my node definition, but the agent run will continue:
Oct 1 15:21:36 agentnode puppet-agent[11680]: (/File[/opt/puppetlabs/puppet/cache/facts.d]) Failed to generate additional resources using 'eval_generate': getaddrinfo: Name or service not known
Oct 1 15:21:40 agentnode puppet-agent[11680]: Could not retrieve catalog from remote server: getaddrinfo: Name or service not known
Version and installation information
PE version: Any
OS: Red Hat 7.5, CentOS 7.5
Solution
You have this issue because during the update to RHEL 7.5, glibc
was updated, but puppet service was not restarted to reload the updated libraries.
Learn more from Red Hat’s release notes.
To fix the issue, restart puppet service on the affected agent nodes. You can either do this manually on the command line or by running a task in the console.
For PE 2017.2 and earlier: You must use the manual solution. (Tasks were introduced in PE 2017.3.)
For PE 2017.3 and later If you are fixing the issue for a small number of nodes, using the manual fix is the easier solution. If you are fixing the issue for a large number of nodes, the task-based solution is easier.
To restart the service manually
Restart puppet service on each affected agent node by running:
puppet resource service puppet ensure=stopped
puppet resource service puppet ensure=running
To restart the service using a task:
Restart puppet service on all Red Hat nodes by running the service::linux
task in the console using the following steps.
-
In the console, in the Run section, click Task.
-
In the Task field, select the
service::linux
task. -
Enter the following parameters:
- action: restart
- name: puppet
-
In the Inventory list, select PQL query.
-
Enter the following query:
query: `inventory[certname] { facts.os.family = "RedHat"and facts.os.release.major = "7" and facts.os.release.minor = "5" }`
-
Click Submit query and click Refresh to update the node results.
-
Click Run job.
How can we improve this article?
0 comments
Please sign in to leave a comment.
Related articles