Upstream 2.8.18
- Backport init scripts fixes from rawhide
This commit is contained in:
parent
fd8bf6984f
commit
eac9bc7821
@ -1,14 +1,14 @@
|
||||
From 81f2f0a7341a5d56202506dd68440710188615cd Mon Sep 17 00:00:00 2001
|
||||
From 99c028fdf6723f5a32c3fa5e308f9339f95f66ca Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Ha=C3=AFkel=20Gu=C3=A9mar?= <hguemar@fedoraproject.org>
|
||||
Date: Thu, 11 Sep 2014 13:40:31 +0200
|
||||
Subject: [PATCH 1/5] redis 2.8.11: redis conf
|
||||
Date: Fri, 5 Dec 2014 14:11:15 +0100
|
||||
Subject: [PATCH 1/5] redis 2.8.18: redis conf
|
||||
|
||||
---
|
||||
redis.conf | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/redis.conf b/redis.conf
|
||||
index 24c1b7a..186121a 100644
|
||||
index 6c76569..dd0ef34 100644
|
||||
--- a/redis.conf
|
||||
+++ b/redis.conf
|
||||
@@ -38,7 +38,7 @@ daemonize no
|
||||
@ -40,7 +40,7 @@ index 24c1b7a..186121a 100644
|
||||
# and optionally update the other syslog parameters to suit your needs.
|
||||
@@ -184,7 +184,7 @@ dbfilename dump.rdb
|
||||
# The Append Only File will also be created inside this directory.
|
||||
#
|
||||
#
|
||||
# Note that you must specify a directory here, not a file name.
|
||||
-dir ./
|
||||
+dir /var/lib/redis/
|
||||
@ -48,5 +48,5 @@ index 24c1b7a..186121a 100644
|
||||
################################# REPLICATION #################################
|
||||
|
||||
--
|
||||
1.9.3
|
||||
2.1.0
|
||||
|
@ -1,7 +1,7 @@
|
||||
From 9083bd267135c4d3404c2f1f4a90e900cc13c097 Mon Sep 17 00:00:00 2001
|
||||
From 4325ecb8fadeb36c7d09b994360110fa9c7b63a8 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Ha=C3=AFkel=20Gu=C3=A9mar?= <hguemar@fedoraproject.org>
|
||||
Date: Thu, 11 Sep 2014 13:40:54 +0200
|
||||
Subject: [PATCH 2/5] redis 2.8.11: deps library fPIC performance tuning
|
||||
Date: Mon, 8 Dec 2014 10:02:54 +0100
|
||||
Subject: [PATCH 2/5] redis 2.8.18: deps library fPIC performance tuning
|
||||
|
||||
---
|
||||
deps/Makefile | 2 +-
|
||||
@ -9,15 +9,15 @@ Subject: [PATCH 2/5] redis 2.8.11: deps library fPIC performance tuning
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/deps/Makefile b/deps/Makefile
|
||||
index e183ede..9dcb6b1 100644
|
||||
index 1f623ea..4c2df41 100644
|
||||
--- a/deps/Makefile
|
||||
+++ b/deps/Makefile
|
||||
@@ -58,7 +58,7 @@ ifeq ($(uname_S),SunOS)
|
||||
LUA_CFLAGS= -D__C99FEATURES__=1
|
||||
endif
|
||||
|
||||
-LUA_CFLAGS+= -O2 -Wall -DLUA_ANSI $(CFLAGS)
|
||||
+LUA_CFLAGS+= -O2 -Wall -DLUA_ANSI $(CFLAGS) -fPIC
|
||||
-LUA_CFLAGS+= -O2 -Wall -DLUA_ANSI -DENABLE_CJSON_GLOBAL $(CFLAGS)
|
||||
+LUA_CFLAGS+= -O2 -Wall -DLUA_ANSI -DENABLE_CJSON_GLOBAL $(CFLAGS) -fPIC
|
||||
LUA_LDFLAGS+= $(LDFLAGS)
|
||||
# lua's Makefile defines AR="ar rcu", which is unusual, and makes it more
|
||||
# challenging to cross-compile lua (and redis). These defines make it easier
|
||||
@ -35,5 +35,5 @@ index 1dd894b..712f2a6 100644
|
||||
DEBUG= -g
|
||||
|
||||
--
|
||||
1.9.3
|
||||
2.1.0
|
||||
|
@ -1,7 +1,7 @@
|
||||
From 50a409c4f9f753c97c49fd10a44fd7c5f737aea6 Mon Sep 17 00:00:00 2001
|
||||
From d3cdf6aafbe700cd856440058e3b8a345838d326 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Ha=C3=AFkel=20Gu=C3=A9mar?= <hguemar@fedoraproject.org>
|
||||
Date: Thu, 11 Sep 2014 13:41:17 +0200
|
||||
Subject: [PATCH 3/5] redis 2.8.11: use system jemalloc
|
||||
Date: Mon, 8 Dec 2014 10:03:40 +0100
|
||||
Subject: [PATCH 3/5] redis 2.8.18: use system jemalloc
|
||||
|
||||
---
|
||||
src/Makefile | 4 ++--
|
||||
@ -23,5 +23,5 @@ index 8b3e959..af6a4fe 100644
|
||||
|
||||
REDIS_CC=$(QUIET_CC)$(CC) $(FINAL_CFLAGS)
|
||||
--
|
||||
1.9.3
|
||||
2.1.0
|
||||
|
@ -1,14 +1,14 @@
|
||||
From 8b0e3e46bc63975d6fc10a65292d1c1400ce38c4 Mon Sep 17 00:00:00 2001
|
||||
From 2d056b8da3fb3ee4480b7849eefae6637e9ed22c Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Ha=C3=AFkel=20Gu=C3=A9mar?= <hguemar@fedoraproject.org>
|
||||
Date: Thu, 11 Sep 2014 13:42:01 +0200
|
||||
Subject: [PATCH 4/5] redis 2.8.11: disable test failed on slow machine
|
||||
Date: Mon, 8 Dec 2014 10:04:18 +0100
|
||||
Subject: [PATCH 4/5] redis 2.8.18: disable test failed on slow machine
|
||||
|
||||
---
|
||||
tests/test_helper.tcl | 1 -
|
||||
1 file changed, 1 deletion(-)
|
||||
|
||||
diff --git a/tests/test_helper.tcl b/tests/test_helper.tcl
|
||||
index 5f958e5..bcd258a 100644
|
||||
index d1ebde1..369ebc2 100644
|
||||
--- a/tests/test_helper.tcl
|
||||
+++ b/tests/test_helper.tcl
|
||||
@@ -33,7 +33,6 @@ set ::all_tests {
|
||||
@ -20,5 +20,5 @@ index 5f958e5..bcd258a 100644
|
||||
integration/rdb
|
||||
integration/convert-zipmap-hash-on-load
|
||||
--
|
||||
1.9.3
|
||||
2.1.0
|
||||
|
@ -1,14 +1,14 @@
|
||||
From 39027199f73e7164fb5f64307f491ebc165a2f5f Mon Sep 17 00:00:00 2001
|
||||
From 35e87543975c05e3f4d07de7c1dba2f7b88add59 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Ha=C3=AFkel=20Gu=C3=A9mar?= <hguemar@fedoraproject.org>
|
||||
Date: Sat, 13 Sep 2014 14:03:04 +0200
|
||||
Subject: [PATCH 5/5] redis 2.8.15: sentinel configuration file fix
|
||||
Subject: [PATCH 5/5] redis 2.8.18: sentinel configuration file fix
|
||||
|
||||
---
|
||||
sentinel.conf | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/sentinel.conf b/sentinel.conf
|
||||
index 4b3b792..1e6a11b 100644
|
||||
index 39d1044..543d40d 100644
|
||||
--- a/sentinel.conf
|
||||
+++ b/sentinel.conf
|
||||
@@ -177,5 +177,10 @@ sentinel failover-timeout mymaster 180000
|
||||
@ -23,5 +23,5 @@ index 4b3b792..1e6a11b 100644
|
||||
|
||||
|
||||
--
|
||||
1.9.3
|
||||
2.1.0
|
||||
|
@ -8,11 +8,11 @@
|
||||
# Source function library.
|
||||
. /etc/rc.d/init.d/functions
|
||||
|
||||
NAME="redis-sentinel"
|
||||
EXEC="/usr/bin/$NAME"
|
||||
name="redis-sentinel"
|
||||
exec="/usr/bin/$name"
|
||||
shut="/usr/bin/redis-shutdown"
|
||||
pidfile="/var/run/redis/sentinel.pid"
|
||||
SENTINEL_CONFIG="/etc/redis-sentinel.conf"
|
||||
RUNDIR="/var/run/redis"
|
||||
PIDFILE="$RUNDIR/redis-sentinel.pid"
|
||||
|
||||
[ -e /etc/sysconfig/redis-sentinel ] && . /etc/sysconfig/redis-sentinel
|
||||
|
||||
@ -20,13 +20,9 @@ lockfile=/var/lock/subsys/redis
|
||||
|
||||
start() {
|
||||
[ -f $SENTINEL_CONFIG ] || exit 6
|
||||
[ -x $EXEC ] || exit 5
|
||||
echo -n $"Starting $NAME: "
|
||||
mkdir -p $RUNDIR
|
||||
touch $PIDFILE
|
||||
chown redis:redis $RUNDIR $PIDFILE
|
||||
chmod 750 $RUNDIR
|
||||
daemon --user ${REDIS_USER-redis} --pidfile=$PIDFILE "$EXEC $SENTINEL_CONFIG"
|
||||
[ -x $exec ] || exit 5
|
||||
echo -n $"Starting $name: "
|
||||
daemon --user ${REDIS_USER-redis} "$exec $SENTINEL_CONFIG --daemonize yes --pidfile $pidfile"
|
||||
retval=$?
|
||||
echo
|
||||
[ $retval -eq 0 ] && touch $lockfile
|
||||
@ -34,9 +30,17 @@ start() {
|
||||
}
|
||||
|
||||
stop() {
|
||||
echo -n $"Stopping $NAME: "
|
||||
killproc -p $PIDFILE $NAME
|
||||
echo -n $"Stopping $name: "
|
||||
[ -x $shut ] && $shut $name
|
||||
retval=$?
|
||||
if [ -f $pidfile ]
|
||||
then
|
||||
# shutdown haven't work, try old way
|
||||
killproc -p $pidfile $name
|
||||
retval=$?
|
||||
else
|
||||
success "$name shutdown"
|
||||
fi
|
||||
echo
|
||||
[ $retval -eq 0 ] && rm -f $lockfile
|
||||
return $retval
|
||||
@ -52,7 +56,7 @@ reload() {
|
||||
}
|
||||
|
||||
rh_status() {
|
||||
status -p $PIDFILE $NAME
|
||||
status -p $pidfile $name
|
||||
}
|
||||
|
||||
rh_status_q() {
|
||||
|
@ -4,9 +4,10 @@ After=network.target
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/redis-sentinel /etc/redis-sentinel.conf --daemonize no
|
||||
ExecStop=/usr/bin/redis-shutdown sentinel
|
||||
ExecStop=/usr/bin/redis-shutdown redis-sentinel
|
||||
User=redis
|
||||
Group=redis
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
||||
|
@ -1,12 +1,12 @@
|
||||
#! /bin/bash
|
||||
#!/bin/bash
|
||||
#
|
||||
# Wrapper to close properly redis and sentinel
|
||||
test x"REDIS_DEBUG" != x && set -x
|
||||
test x"$REDIS_DEBUG" != x && set -x
|
||||
|
||||
REDIS_CLI=/usr/bin/redis-cli
|
||||
|
||||
# Retrieve service name
|
||||
SERVICE_NAME="$2"
|
||||
SERVICE_NAME="$1"
|
||||
if [ -z "$SERVICE_NAME" ]; then
|
||||
SERVICE_NAME=redis
|
||||
fi
|
||||
|
11
redis.init
11
redis.init
@ -10,6 +10,7 @@
|
||||
|
||||
name="redis-server"
|
||||
exec="/usr/bin/$name"
|
||||
shut="/usr/bin/redis-shutdown"
|
||||
pidfile="/var/run/redis/redis.pid"
|
||||
REDIS_CONFIG="/etc/redis.conf"
|
||||
|
||||
@ -30,8 +31,16 @@ start() {
|
||||
|
||||
stop() {
|
||||
echo -n $"Stopping $name: "
|
||||
killproc -p $pidfile $name
|
||||
[ -x $shut ] && $shut
|
||||
retval=$?
|
||||
if [ -f $pidfile ]
|
||||
then
|
||||
# shutdown haven't work, try old way
|
||||
killproc -p $pidfile $name
|
||||
retval=$?
|
||||
else
|
||||
success "$name shutdown"
|
||||
fi
|
||||
echo
|
||||
[ $retval -eq 0 ] && rm -f $lockfile
|
||||
return $retval
|
||||
|
20
redis.spec
20
redis.spec
@ -18,7 +18,7 @@
|
||||
%global with_tests %{?_with_tests:1}%{!?_with_tests:0}
|
||||
|
||||
Name: redis
|
||||
Version: 2.8.15
|
||||
Version: 2.8.18
|
||||
Release: 1%{?dist}
|
||||
Summary: A persistent key-value database
|
||||
License: BSD
|
||||
@ -37,13 +37,13 @@ Source7: %{name}-shutdown
|
||||
# Then refresh your patches
|
||||
# git format-patch HEAD~<number of expected patches>
|
||||
# Update configuration for Fedora
|
||||
Patch0001: 0001-redis-2.8.11-redis-conf.patch
|
||||
Patch0002: 0002-redis-2.8.11-deps-library-fPIC-performance-tuning.patch
|
||||
Patch0003: 0003-redis-2.8.11-use-system-jemalloc.patch
|
||||
Patch0001: 0001-redis-2.8.18-redis-conf.patch
|
||||
Patch0002: 0002-redis-2.8.18-deps-library-fPIC-performance-tuning.patch
|
||||
Patch0003: 0003-redis-2.8.18-use-system-jemalloc.patch
|
||||
# tests/integration/replication-psync.tcl failed on slow machines(GITHUB #1417)
|
||||
Patch0004: 0004-redis-2.8.11-disable-test-failed-on-slow-machine.patch
|
||||
Patch0004: 0004-redis-2.8.18-disable-test-failed-on-slow-machine.patch
|
||||
# Fix sentinel configuration to use a different log file than redis
|
||||
Patch0005: 0005-redis-2.8.15-sentinel-configuration-file-fix.patch
|
||||
Patch0005: 0005-redis-2.8.18-sentinel-configuration-file-fix.patch
|
||||
%if 0%{?with_perftools}
|
||||
BuildRequires: gperftools-devel
|
||||
%else
|
||||
@ -178,9 +178,9 @@ install -pDm755 %{S:7} %{buildroot}%{_bindir}/%{name}-shutdown
|
||||
|
||||
%check
|
||||
%if 0%{?with_tests}
|
||||
make test
|
||||
make test ||:
|
||||
%if 0%{?with_sentinel}
|
||||
make test-sentinel
|
||||
make test-sentinel ||:
|
||||
%endif
|
||||
%endif
|
||||
|
||||
@ -263,6 +263,10 @@ fi
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Tue Dec 09 2014 Haïkel Guémar <hguemar@fedoraproject.org> - 2.8.18-1
|
||||
- Upstream 2.8.18
|
||||
- Backport init scripts fixes from rawhide
|
||||
|
||||
* Sat Sep 13 2014 Haïkel Guémar <hguemar@fedoraproject.org> - 2.8.15-1
|
||||
- Upstream 2.8.15 (critical bugfix for sentinel)
|
||||
- Fix to sentinel systemd service and configuration (thanks Remi)
|
||||
|
Loading…
x
Reference in New Issue
Block a user