mac 安装redis, mongodb, mysql

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/qq_38689232/article/details/85252328
brew install redis
brew install mongodb
brew install mysql

redis

redis-server # 开启服务
redis-cli   #连接

mongodb

brew services start mongodb  # 开启服务
mongo  #连接
再次启动mongod无法启动
如果mongodb异常关闭,需要删掉mongod.lock文件。mongod.lock文件是mongo服务端启动后在硬盘中创建的一个锁文件

mysql

mysql.server start # 启动服务
mysql_secure_installation  # 配置密码
Press y|Y for Yes, any other key for No: N   // 这个选yes的话密码长度就必须要设置为8位以上,但我只想要6位的

New password:             // 设置密码
Re-enter new password:     // 再一次确认密码
Remove anonymous users? (Press y|Y for Yes, any other key for No) : Y    // 移除不用密码的那个账户

Disallow root login remotely? (Press y|Y for Yes, any other key for No) : n  //不接受root远程登录账号

猜你喜欢

转载自blog.csdn.net/qq_38689232/article/details/85252328
今日推荐