Linux -bash: redis-server: command not found

Linux

安装完redis单独用命令:

redis-server
报错:

-bash: redis-server: command not found
说明redis-server不是全局命令,那么假如到全局即可:

假如我的redis安装路径是:/home/prod/redis/redis-4.0.8

ln -s /home/prod/redis/redis-4.0.8/src/redis-server /usr/bin/redis-server

redis-server
放到/usr/bin下即可(相当于创建一个全局快捷方式)

 

posted @ 2022-05-01 22:47  夏冬青  阅读(1031)  评论(0编辑  收藏  举报