I got the following error when try to run chef-client cookbook on the chef workstation.
[root@jasontest chef-client-wrapper]# knife node run_list add jason.test.com ‘recipe[chef-client-wrapper]’
jason.test.com:
run_list: recipe[chef-client-wrapper]
[root@jasontest chef-client-wrapper]# chef-client
Starting Chef Client, version 13.8.5
================================================================================
Chef encountered an error attempting to load the node data for “jasontest.ec2.avery.com”
Authentication Error:
Failed to authenticate to the chef server (http 401).
Server Response:
Invalid signature for user or client ‘jason.test.com’
Relevant Config Settings:
chef_server_url “https://chefserver-0xxxxxx.opsworks-cm.io/organizations/default”
node_name “jason.test.com”
client_key “/etc/chef/client.pem”
If these settings are correct, your client_key may be invalid, or
you may have a chef user with the same client name as this node.
System Info:
chef_version=13.8.5
ruby=ruby 2.4.3p205 (2017-12-14 revision 61247) [x86_64-linux]
program_name=chef-client worker: ppid=25684;start=17:53:56;
executable=/opt/chefdk/bin/chef-client
Running handlers:
[2018-03-20T17:53:57+00:00] ERROR: Running exception handlers
Running handlers complete
[2018-03-20T17:53:57+00:00] ERROR: Exception handlers complete
Chef Client failed. 0 resources updated in 01 seconds
[2018-03-20T17:53:57+00:00] FATAL: Stacktrace dumped to /var/chef/cache/chef-stacktrace.out
[2018-03-20T17:53:57+00:00] FATAL: Please provide the contents of the stacktrace.out file if you file a bug report
[2018-03-20T17:53:57+00:00] ERROR: 401 “Unauthorized”
[2018-03-20T17:53:58+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
[root@jasontest chef-client-wrapper]#