upgrade redis 2.4.14 to redis 2.6.14, command "service redis start" always hangs -


i installed redis2.4.14 before. yestoday, got redis2.6.14, , directly "cd redis-2.6.14/src ; make && make install". , removed dump.rdb , redis.log of redis-2.4.14. upgraded configuration file 2.6.14. added redis service when installed redis-2.4.14. execute command "service redis start", hangs no "ok" information.

[tys@localhost bin]# service redis start starting redis-server:  

i can use redis nomally

[tys@localhost redis]# redis-cli redis 127.0.0.1:6379> set name tys ok redis 127.0.0.1:6379> name "tys" 

but if type "ctrl + c" or "ctrl + z", "redis-cli" hang on.

when reboot system, linux boot process hangs on "starting redis-server" (sorry, "young" post image. https://groups.google.com/forum/#!topic/redis-db/iqnlyaawe9y)

but can ssh it.it's virtual machine. there no error in redis.log.

[1420] 11 aug 04:27:05.879 # server started, redis version 2.6.14 [1420] 11 aug 04:27:05.880 # warning overcommit_memory set 0! background save may fail under low memory condition. fix issue add 'vm.overcommit_memory = 1' /etc/sysctl.conf , reboot or run command 'sysctl vm.overcommit_memory=1' take effect. [1420] 11 aug 04:27:05.903 * db loaded disk: 0.023 seconds [1420] 11 aug 04:27:05.903 * server ready accept connections on port 6379 

here redis init.d script :

#!/bin/bash # #redis - script starts , stops redis-server daemon # # chkconfig:   235 90 10  # description:  redis persistent key-value database # processname: redis-server # config:      /etc/redis.conf # config:      /etc/sysconfig/redis # pidfile:     /var/run/redis.pid  # source function library. . /etc/rc.d/init.d/functions  # source networking configuration. . /etc/sysconfig/network  # check networking up. [ "$networking" = "no" ] && exit 0  redis="/usr/local/bin/redis-server" prog=$(basename $redis)  redis_conf_file="/etc/redis.conf"  [ -f /etc/sysconfig/redis ] && . /etc/sysconfig/redis  lockfile=/var/lock/subsys/redis  start() {     [ -x $redis ] || exit 5     [ -f $redis_conf_file ] || exit 6     echo -n $"starting $prog: "     daemon $redis $redis_conf_file     retval=$?     echo     [ $retval -eq 0 ] && touch $lockfile     return $retval }  stop() {     echo -n $"stopping $prog: "     killproc $prog -quit     retval=$?     echo     [ $retval -eq 0 ] && rm -f $lockfile     return $retval }  restart() {     stop     start }  reload() {     echo -n $"reloading $prog: "     killproc $redis -hup     retval=$?     echo }  force_reload() {     restart }  rh_status() {     status $prog }  rh_status_q() {     rh_status >/dev/null 2>&1 }   case "$1" in     start)         rh_status_q && exit 0         $1         ;;     stop)         rh_status_q || exit 0         $1         ;;     restart|configtest)         $1         ;;     reload)         rh_status_q || exit 7         $1         ;;     force-reload)         force_reload         ;;     status)         rh_status         ;;     condrestart|try-restart)         rh_status_q || exit 0         ;;     *)         echo $"usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}"         exit 2 esac 

i resovled josiah' in https://groups.google.com/forum/#!forum/redis-db.

it's "daemonize no" in redis.conf. redis started nomally, after switched "daemonize yes".


Comments

Popular posts from this blog

css - Which browser returns the correct result for getBoundingClientRect of an SVG element? -

gcc - Calling fftR4() in c from assembly -

Function that returns a formatted array in VBA -