I am new to Zookeeper and it has being a real issue to install it and run. I am not sure what is wrong in here but I will explain what I\'ve being doing to make it more clear:>
Seems there's all kinds of reasons this can happen. So many helpful answers here!
For me, I had improper line endings in my zoo.cfg file, and possibly invisible characters, so zookeeper was trying to create directories like /var/zookeeper?
and /var/zookeeper\r
. Reworking my zoo.cfg a bit fixed it for me, along with deleting zoo_sample.conf.