When I am bootstrapping a node, I'm getting this error: /opt/chef/embedded/bin/ruby; error while loading shared libraries: libcrypt.so.1: cannot open shared object file: No such file or directory
I executed below command knife bootstrap 172.31.6.156 --ssh-user ec2-user --sudo -i key-node1.pem -N node1
It's telling you that you need to install libcrypt.so.
You can check with
ldd $(type -p chef)
which lists the shared libraries needed by chef. Since chef makes use of functions in libcrypt.so, and you don't have it installed, Chef can't work.On Ubuntu, one would find the package to install (to obtain libcrypt.so) with:
but you didn't let us know which distribution you're using.
If using Linux/AWS/Redhat, try this instead:
Now search for library
If the find command shows nothing, this means "libcrypt.so.1" is still missing. Download and install it manually by,
Reference: https://unix.stackexchange.com/questions/746042/error-while-generating-cookbook-missing-shared-library-libcrypt-so-1