Bug 1251484 - the redis resource agent should allow for use of a password to connect to redis
the redis resource agent should allow for use of a password to connect to redis
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: resource-agents (Show other bugs)
Unspecified Unspecified
high Severity high
: rc
: ---
Assigned To: Fabio Massimo Di Nitto
Udi Shkalim
: EasyFix, Patch, ZStream
Depends On:
Blocks: 1252081 1259595
  Show dependency treegraph
Reported: 2015-08-07 08:38 EDT by Giulio Fidente
Modified: 2015-11-18 23:48 EST (History)
11 users (show)

See Also:
Fixed In Version: resource-agents-3.9.5-54.el7
Doc Type: Enhancement
Doc Text:
In order to support authenticated communication between Redis and its clients, the Redis resource agent now supports client password communication by auto-detecting the settings from Redis configuration file.
Story Points: ---
Clone Of:
: 1259595 (view as bug list)
Last Closed: 2015-11-18 23:48:46 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
proposed patch (960 bytes, text/plain)
2015-08-13 09:42 EDT, Fabio Massimo Di Nitto
no flags Details
new patch with David´s magic (993 bytes, patch)
2015-08-13 10:16 EDT, Fabio Massimo Di Nitto
no flags Details | Diff

External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:2190 normal SHIPPED_LIVE resource-agents bug fix and enhancement update 2015-11-19 03:06:48 EST

  None (edit)
Description Giulio Fidente 2015-08-07 08:38:24 EDT
Description of problem:
the redis resource agent uses redis-cli to perform live config changes on the running instances but it doesn't allow to specify a password to connect to redis; the redis-cli binary expects that with -a password

Version-Release number of selected component (if applicable):
Comment 2 Giulio Fidente 2015-08-07 09:08:50 EDT
This is needed by https://review.openstack.org/#/c/210405 , where we try to enforce use of a password to connect to Redis
Comment 3 Fabio Massimo Di Nitto 2015-08-13 09:42:00 EDT
Created attachment 1062588 [details]
proposed patch

Tested by setting:

masterauth foobared


requirepass foobared

in redis.conf on all nodes.

Start/configure redis as we do in OSP:

pcs resource create redis redis wait_last_known_master=true --master meta notify=true ordered=true interleave=true

verify that the client requires passwd:

[root@rhel7-ha-node1 ~]# redis-cli info 
NOAUTH Authentication required.

[root@rhel7-ha-node1 ~]# redis-cli -a foobared info 
Comment 4 Fabio Massimo Di Nitto 2015-08-13 10:16:13 EDT
Created attachment 1062612 [details]
new patch with David´s magic
Comment 5 David Vossel 2015-08-13 16:57:49 EDT
pull request with my magic upstream.

Comment 12 Leonid Natapov 2015-10-20 06:53:14 EDT
Tested on RHEL 7.2 per Dean Jansa's request
Manually upgraded resoure-agents to resource-agents-3.9.5-54.el7.x86_64.

masterauth and requirepass were set in redis.conf on all nodes
restart redis. (deleted and created resource again)

[root@overcloud-controller-2 heat-admin]# redis-cli -h overcloud-controller-2  -p 6379 info
NOAUTH Authentication required.

[root@overcloud-controller-2 heat-admin]# redis-cli -h overcloud-controller-2  -p 6379 -a lesik info
# Server
os:Linux 3.10.0-229.14.1.el7.x86_64 x86_64
Comment 14 errata-xmlrpc 2015-11-18 23:48:46 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.