Tom White updated ZOOKEEPER-303:

    Attachment: zookeeper-303.patch

The {{readlink}} command is used to canonicalize the start script, following 
symlinks recursively. This is a useful feature to have as it allows the scripts 
to be symlinked. I've attached a patch that detects if readlink is available. 
If it's not then you have to call the scripts directly (without symlinks) - 
which is a good compromise as it means the scripts can be used on Macs, while 
still supporting symlinks on Linux. 

Note also, as a workaround you can install GNU readlink (MacPorts: {{port 
install coreutils}}) and change {{readlink}} to {{greadlink}} in the scripts.

> Bin scripts don't work on Mac
> -----------------------------
>                 Key: ZOOKEEPER-303
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-303
>             Project: Zookeeper
>          Issue Type: Bug
>          Components: scripts
>         Environment: Mac OS X
>            Reporter: Tom White
>         Attachments: zookeeper-303.patch
> Macs don't support the -f option in readlink
> {noformat}
> $ bin/zkServer.sh start
> JMX enabled by default
> readlink: illegal option -- f
> usage: readlink [-n] [file ...]
> {noformat}

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

Reply via email to