# Why is there a negative number in the replication lag in Percona MySQL Shell? (Innodb Cluster)

**URL:** <https://forums.percona.com/t/why-is-there-a-negative-number-in-the-replication-lag-in-percona-mysql-shell-innodb-cluster/26421>\
**Category:** Percona Toolkit\
**Created:** [November 8, 2023, 7:14am UTC](https://forums.percona.com/t/why-is-there-a-negative-number-in-the-replication-lag-in-percona-mysql-shell-innodb-cluster/26421 "2023-11-08T07:14:07Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![DongyeongKim](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/dongyeongkim/32/13577_2.png) [@DongyeongKim](https://forums.percona.com/u/DongyeongKim)\
**Post date:** [November 8, 2023, 7:14am UTC](https://forums.percona.com/t/why-is-there-a-negative-number-in-the-replication-lag-in-percona-mysql-shell-innodb-cluster/26421/1 "2023-11-08T07:14:07Z")

</div>

```js
 MySQL localhost JS > a.status()
{
    "clusterName": "rockCluster",
    "defaultReplicaSet": {
        "name": "default",
        "primary": "node2:3306",
        "ssl": "REQUIRED",
        "status": "OK",
        "statusText": "Cluster is ONLINE and can tolerate up to ONE failure.",
        "topology": {
            "node1:3306": {
                "address": "node1:3306",
                "memberRole": "SECONDARY",
                "mode": "R/O",
                "readReplicas": {},
                "replicationLag": "00:00:00.612635",
                "role": "HA",
                "status": "ONLINE",
                "version": "8.0.33"
            },
            "node2:3306": {
                "address": "node2:3306",
                "memberRole": "PRIMARY",
                "mode": "R/W",
                "readReplicas": {},
                "replicationLag": "applier_queue_applied",
                "role": "HA",
                "status": "ONLINE",
                "version": "8.0.33"
            },
            "node3:3306": {
                "address": "node3:3306",
                "memberRole": "SECONDARY",
                "mode": "R/O",
                "readReplicas": {},
                "replicationLag": "-00:00:07.330298",
                "role": "HA",
                "status": "ONLINE",
                "version": "8.0.33"
            }
        },
        "topologyMode": "Single-Primary"
    },
    "groupInformationSourceMember": "node2:3306"
}

```

Load testing using sysbench. Why does the negative value appear? (node3)  
Tested with default setting of oltp\_read\_write.lua.

The shell version is percona 8.0.34.

---

<div class="post-metadata">

**Author:** ![Abhinav\_Gupta](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/abhinav_gupta/32/6262_2.png) [@Abhinav\_Gupta](https://forums.percona.com/u/Abhinav_Gupta)\
**Post date:** [November 8, 2023, 10:51am UTC](https://forums.percona.com/t/why-is-there-a-negative-number-in-the-replication-lag-in-percona-mysql-shell-innodb-cluster/26421/2 "2023-11-08T10:51:43Z")

</div>

As DB version is 8.0.33, please try the same [cluster.status()] with shell version 8.0.33? Is it repeatable with shell 8.0.33 as well?

---

<div class="post-metadata">

**Author:** ![DongyeongKim](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/dongyeongkim/32/13577_2.png) [@DongyeongKim](https://forums.percona.com/u/DongyeongKim)\
**Post date:** [November 9, 2023, 1:57am UTC](https://forums.percona.com/t/why-is-there-a-negative-number-in-the-replication-lag-in-percona-mysql-shell-innodb-cluster/26421/3 "2023-11-09T01:57:45Z")

</div>

In various DB versions (8.0.32, 8.0.33, 8.0.21…), we want to manage it in an integrated way using Shell. I’m currently using only one shell version, so would it be better to match the shell version compatibly?

---

<div class="post-metadata">

**Author:** ![Abhinav\_Gupta](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/abhinav_gupta/32/6262_2.png) [@Abhinav\_Gupta](https://forums.percona.com/u/Abhinav_Gupta)\
**Post date:** [November 9, 2023, 6:13am UTC](https://forums.percona.com/t/why-is-there-a-negative-number-in-the-replication-lag-in-percona-mysql-shell-innodb-cluster/26421/4 "2023-11-09T06:13:53Z")

</div>

Yes, It is recommended to keep your MySQL shell client version similar to your DB version.
