Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can not run redis-monitor.py on CentOS 7.4 with python 2.7.5 #102

Open
pgm-rookie opened this issue Dec 11, 2018 · 5 comments
Open

can not run redis-monitor.py on CentOS 7.4 with python 2.7.5 #102

pgm-rookie opened this issue Dec 11, 2018 · 5 comments

Comments

@pgm-rookie
Copy link

Traceback (most recent call last):
File "./redis-monitor.py", line 206, in run
used_memory, peak_memory)
File "/home/RedisLive-master/src/dataprovider/redisprovider.py", line 30, in save_memory_info
self.conn.zadd(server + ":memory", str(timeutils.convert_to_epoch(timestamp)), data)
File "/usr/lib/python2.7/site-packages/redis/client.py", line 2263, in zadd
for pair in iteritems(mapping):
File "/usr/lib/python2.7/site-packages/redis/_compat.py", line 94, in iteritems
return x.iteritems()
AttributeError: 'str' object has no attribute 'iteritems'
Traceback (most recent call last):
File "./redis-monitor.py", line 139, in run
str(arguments))
File "/home/RedisLive-master/src/dataprovider/redisprovider.py", line 95, in save_monitor_command
pipeline.execute()
File "/usr/lib/python2.7/site-packages/redis/client.py", line 3443, in execute
return execute(conn, stack, raise_on_error)
File "/usr/lib/python2.7/site-packages/redis/client.py", line 3358, in _execute_transaction
self.raise_first_error(commands, response)
File "/usr/lib/python2.7/site-packages/redis/client.py", line 3392, in raise_first_error
raise r
ResponseError: Command # 1 (ZINCRBY 127.0.0.1:8088:CommandCount:1544539899 ZINCRBY 1) of pipeline caused error: value is not a valid float

@LeoQuote
Copy link

Try update to python 2.7.10 or higher. 2.7.10 works for me.

@nonomal
Copy link

nonomal commented Feb 3, 2019

@LeoQuote update to python 2.7.15:
2019-02-03 00:54:28.316443
Traceback (most recent call last):
File "./redis-monitor.py", line 206, in run
used_memory, peak_memory)
File "/home/redis/redis-3.2.6/redislive/nkrode-RedisLive-e1d7763/src/dataprovider/redisprovider.py", line 30, in save_memory_info
self.conn.zadd(server + ":memory", str(timeutils.convert_to_epoch(timestamp)), data)
File "/usr/local/python2.7.15/lib/python2.7/site-packages/redis/client.py", line 2320, in zadd
for pair in iteritems(mapping):
File "/usr/local/python2.7.15/lib/python2.7/site-packages/redis/_compat.py", line 94, in iteritems
return x.iteritems()
AttributeError: 'str' object has no attribute 'iteritems'

==============================

@nonomal
Copy link

nonomal commented Feb 3, 2019

@java-new-bird Have you solved it?

@nonomal
Copy link

nonomal commented Feb 23, 2019

#103

@pgm-rookie
Copy link
Author

@java-new-bird Have you solved it?

yes ,solved with LeoQuote‘s solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants