Search code examples
sshchef-infravirtual-machineknife

Knife SSH command to initiate Chef Client run times out


Per the Stackoverflow community's recommendation; I have recently moved my Chef Workstation from a VM to a machine running Ubuntu 16.04 desktop. I have regenerated my .pem file as I'm using the same Hosted Chef user on the new machine.

Knife node list returns the two managed nodes I have setup, and knife search node name:some-name yields a search result for each of the nodes. When I attempt to initiate a Chef Client run on the nodes, I receive an SSH timeout.

The command I am using to initiate the chef client runs is as follows:

knife ssh 'name:managed-node1' 'sudo chef-client' --ssh-user c7-device --identity-file ~/chef/.chef/chucknorris.pem --attribute ipaddress

A bit of information that may be of particular importantance: each one of these managed nodes is a VM with a resolvable hostname. Why after moving my workstation to a new machine, would I now receive an SSH timeout when attempting to initiate a Chef Client run on my managed nodes?

Thanks in advance for any guidance,


Solution

  • As noted above in comments, there is no network connectivity between the hosts in general. This probably means you need to fix your network layout but is outside the scope of knife.