Skip to content

Instantly share code, notes, and snippets.

@cndaniel
Created March 5, 2017 03:27
Show Gist options
  • Save cndaniel/466bdc2656e663347f704ea5e274dfef to your computer and use it in GitHub Desktop.
Save cndaniel/466bdc2656e663347f704ea5e274dfef to your computer and use it in GitHub Desktop.
brew services start postgresql 无法开机启动资料库

出现 permission denied

往往因为电脑上有多个用户导致的

  1. 先去 system preferences 确定用户的权限是管理员

  2. 再进终端: echo ~ user/whoami , 确定用户名是whoami

  3. 终端输入 sudo chown $(whoami):admin /usr/local && sudo chown -R $(whoami):admin /usr/local赋予权限

  4. 重新执行brew services start postgresql

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment