Chef – ERROR: EOFError: end of file reached

Recently when using opscode’s chef server and knife I was getting the error message:

> ERROR: EOFError: end of file reached

When trying to execute commands like `knife client list`

I ended up finding out that the problem has to do with how the configuration for chef 11 has changed from chef 10.

In your `knife.rb` file there is a line that gives you the default address / address of your cloud server – you will even see the default if you are running the interactive knife configuration tool (`knife configure -i`):

> Please enter the chef server URL: [http://chef.example.com:4000]

The big changes for chef 11 are two hard to spot things for the new chef server / knife access url: `https://chef.example.com`

1. Port 4000 goes away
2. The server now runs on HTTPS / SSL (which implies port 443)

Change this to use SSL / HTTPS and your `ERROR: EOFError: end of file reached` message will go away. I was getting that error when trying to access chef on port `5672` which is the port that RabbitMQ runs on.

Related Posts:

This entry was posted in Linux, Tech Tips and tagged , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *