python开发遇到的坑(2)mongodb安装路径权限问题

个人比较懒,Mac 电脑直接使用命令行安装,brew install mongodb,但是遇到两个问题,其一:

1 Error: The following directories are not writable by your user:
2 /usr/local/share/man/man5
3 
4 You should change the ownership of these directories to your user.
5   sudo chown -R $(whoami) /usr/local/share/man/man5

好在这个有提示,直接命令行输入

sudo chown -R $(whoami) /usr/local/share/man/man5

接着输入电脑密码就行了

问题二:

1 ==> Pouring python@2-2.7.15_1.mojave.bottle.7.tar.gz
2 Error: An unexpected error occurred during the `brew link` step
3 The formula built, but is not symlinked into /usr/local
4 Permission denied @ dir_s_mkdir - /usr/local/Frameworks
5 Error: Permission denied @ dir_s_mkdir - /usr/local/Frameworks

这个只知道/usr/local/Frameworks路径权限的问题,试了下第一个问题的解决方式,提示没有路径,于是就先创建了权限

sudo mkdir /usr/local/Frameworks
sudo chown $(whoami):admin /usr/local/Frameworks

好了,问题都解决了,安装成功!

posted @ 2018-12-18 21:40  夏落若的博客  阅读(617)  评论(0编辑  收藏  举报