Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1231034

Summary: redis fails to start when db is 0 bytes
Product: Red Hat OpenStack Reporter: Fabio Massimo Di Nitto <fdinitto>
Component: redisAssignee: RHOS Maint <rhos-maint>
Status: CLOSED NOTABUG QA Contact: Shai Revivo <srevivo>
Severity: high Docs Contact:
Priority: high    
Version: 7.0 (Kilo)CC: agk, apevec, cfeist, cluster-maint, cluster-qe, djansa, fdinitto, jherrman, lhh, mburns, mmagr, pkilambi
Target Milestone: ---Keywords: ZStream
Target Release: 7.0 (Kilo)   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
When a cluster node fails and a fencing operation is performed, the /var/lib/redis/dump.rdb database file in some cases changes its size to 0 bytes. Previously, when this happened, the Redis Open Clustering Framework (OCF) resource agent did not start correctly. This update ensures that in the described situation, Redis automatically clears the corrupted database file and resynchronizes the remaining Redis instances in the cluster. As a result, Redis starts as expected.
Story Points: ---
Clone Of: 1231032 Environment:
Last Closed: 2017-01-13 21:44:16 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1231032    
Bug Blocks:    

Description Fabio Massimo Di Nitto 2015-06-12 04:52:46 UTC
+++ This bug was initially created as a clone of Bug #1231032 +++

Description of problem:

I am filing this against resource-agents and redis (starting from ras)

In case of a node failure and fencing operation, there is a chance that /var/lib/redis/dump.rdb is 0 bytes (fence during an update for example).

In that case redis will fail to start with a "short read".

redis server should ignore a 0 bytes file and resume operations IMHO.

the resource-agents should check for that condition and wipe the file since the db will be resync from the other nodes in the cluster.