1

This is the list of user permissions after logging them to the terminal:

➜  ~  ls -ld / /usr /usr/bin /usr/bin/manpath
drwxr-xr-x    33 root  wheel   1190 Nov 14 08:49 /
drwxr-xr-x@   11 root  wheel    374 Nov  7 09:12 /usr
drwxr-xr-x  1055 root  wheel  35870 Nov 12 11:34 /usr/bin
lrwxr-xr-x     1 root  wheel      3 Nov  5 18:13 /usr/bin/manpath -> man

And this is the error I receive when trying to update the permissions:

➜  ~  chmod 755 / /usr /usr/bin /usr/bin/*
chmod: Unable to change file mode on /usr/bin/apropos: Operation not permitted
chmod: Unable to change file mode on /usr/bin/at: Operation not permitted

This all began as an effort to debug the following zsh error:

zsh: command not found

I have tried resetting my $PATH variable to no avail. I've uninstalled and reinstalled zsh, run brew doctor, reinstalled node, etc. and am unsure where to proceed from here. The problems I am trying to fix are two-fold:

  1. fix the PATH so that I can use commands (e.g.: ionic) from the terminal
  2. fix the permissions so I don't encounter any further errors as I troubleshoot going forward

Can anyone offer guidance? Been trying to debug this for hours.

This my current PATH:

➜  ~  echo $PATH                               
echo $PATH
/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
2
  • (1) Why are you trying to change the mode of these directories to what they already are?  (2) How do you get that zsh: command not found error message?  As a result of logging in, getting a login shell (that isn't zsh), and typing zsh(Enter)?  If so, that isn't a "zsh error"; it's an error from your shell.  (3) To solve your problem, figure out where zsh is.  Try find / -type f -name zsh -print.  (4) Just for fun, do ls -ld /usr/bin/apropos /usr/bin/at. Nov 23, 2015 at 21:47
  • 1) I'm pretty new to mac coming from 25+ years on Windows, and just trying to troubleshoot based off of a Stack Overflow post that recommended my zsh error might be related to permissions 2) the zsh: command not found error happens whenever I try to run something with its terminal shortcut e.g.: ionic, etc. I just ran the find / command you posted and got : find / -type f -name zsh -print find: /.DocumentRevisions-V100: Permission denied, among many others. Zsh is located in my /usr/local/Cellar/zsh/5.1.1/bin/zsh from what I can tell, since I installed it with Homebrew. Nov 24, 2015 at 0:16

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Browse other questions tagged or ask your own question.