summaryrefslogtreecommitdiffstats
path: root/xlators/features/marker/utils/syncdaemon/repce.py
diff options
context:
space:
mode:
authorVenky Shankar <venky@gluster.com>2011-09-28 16:38:00 +0530
committerVijay Bellur <vijay@gluster.com>2011-10-20 23:26:23 -0700
commitbdf20a205a4d67d5f6d3ac6010a34291c2822a80 (patch)
tree412c56b2d2f765011a7b158f4b31b75a7bffce2b /xlators/features/marker/utils/syncdaemon/repce.py
parent84ebee8c20ce667a5ec5fddc0aa47f8b5bef39f8 (diff)
cli: add geo-replication log-rotate command
Rotating geo-replication master/monitor log files from cli. On invocation, the log file for a given master-slave session is backed up with the current timestamp suffixed to the file name and signal is sent to gsyncd to start logging to a new log file. Sample commands: * Rotate log file for this <master>:<slave> session: gluster volume geo-replication <master> <slave> log-rotate * Rotate log files for all session for master volume <master> gluster volume geo-replication <master> log-rotate * Rotate log files for all sessions: gluster volume geo-replication log-rotate Change-Id: I75f641b4e082a04d5373c18583ca4a1d9651d27a BUG: 3519 Reviewed-on: http://review.gluster.com/529 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Csaba Henk <csaba@gluster.com>
Diffstat (limited to 'xlators/features/marker/utils/syncdaemon/repce.py')
-rw-r--r--xlators/features/marker/utils/syncdaemon/repce.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/xlators/features/marker/utils/syncdaemon/repce.py b/xlators/features/marker/utils/syncdaemon/repce.py
index 947352490..755fb61df 100644
--- a/xlators/features/marker/utils/syncdaemon/repce.py
+++ b/xlators/features/marker/utils/syncdaemon/repce.py
@@ -1,6 +1,5 @@
import os
import sys
-import select
import time
import logging
from threading import Condition
@@ -20,7 +19,7 @@ except ImportError:
# py 3
import pickle
-from syncdutils import Thread
+from syncdutils import Thread, select
pickle_proto = -1
repce_version = 1.0
@@ -154,7 +153,7 @@ class RepceClient(object):
def listen(self):
while True:
- select.select((self.inf,), (), ())
+ select((self.inf,), (), ())
rid, exc, res = recv(self.inf)
rjob = self.jtab.pop(rid)
if rjob.cbk: