mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-11-30 10:10:21 +00:00
rbd: log mirror daemon state for replication
log the mirror deamon state in the local and
remote cluster for better debugging.
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
(cherry picked from commit 2017b8c621
)
This commit is contained in:
parent
ca4bf66035
commit
dade373fc0
@ -513,9 +513,10 @@ func checkRemoteSiteStatus(ctx context.Context, mirrorStatus *librbd.GlobalMirro
|
|||||||
for _, s := range mirrorStatus.SiteStatuses {
|
for _, s := range mirrorStatus.SiteStatuses {
|
||||||
util.UsefulLog(
|
util.UsefulLog(
|
||||||
ctx,
|
ctx,
|
||||||
"peer site mirrorUUID=%s, mirroring state=%s, description=%s and lastUpdate=%s",
|
"peer site mirrorUUID=%q, daemon up=%t, mirroring state=%q, description=%q and lastUpdate=%d",
|
||||||
s.MirrorUUID,
|
s.MirrorUUID,
|
||||||
s.State.String(),
|
s.Up,
|
||||||
|
s.State,
|
||||||
s.Description,
|
s.Description,
|
||||||
s.LastUpdate)
|
s.LastUpdate)
|
||||||
if s.MirrorUUID != "" {
|
if s.MirrorUUID != "" {
|
||||||
@ -611,8 +612,9 @@ func (rs *ReplicationServer) ResyncVolume(ctx context.Context,
|
|||||||
lastUpdateTime := time.Unix(localStatus.LastUpdate, 0).UTC()
|
lastUpdateTime := time.Unix(localStatus.LastUpdate, 0).UTC()
|
||||||
util.UsefulLog(
|
util.UsefulLog(
|
||||||
ctx,
|
ctx,
|
||||||
"local image mirroring state=%s, description=%s and lastUpdate=%s",
|
"local status: daemon up=%t, image mirroring state=%q, description=%q and lastUpdate=%s",
|
||||||
localStatus.State.String(),
|
localStatus.Up,
|
||||||
|
localStatus.State,
|
||||||
localStatus.Description,
|
localStatus.Description,
|
||||||
lastUpdateTime)
|
lastUpdateTime)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user