I have connected two Juniper routers with a QSFP28 optics and I need to find out the length of the optical cable I have used. Is there a command to check that in the router?

2 Answers 2


No, you can find out with optical test equipment such as an OTDR, but not with the less-sophisticated telemetry available in a router/switch.

You can know the path loss (limited by the accuracy of the optics' Tx/Rx power meters) but that loss includes things like bends, dirt, connectors, etc. so it's not usable as a good estimate of distance.


You can use the below command to check the cable details.

show chassis hardware.
Sample output. The description has the cable length detail.

enter image description here

  • 1
    ... only for DACs. The OP was asking about 'optics'.
    – Zac67
    Nov 1, 2020 at 8:59
  • 1
    Please, never use an image for text. Simply copy the text and paste it into your post using the Preformatted-text option ({}).
    – Ron Maupin
    Nov 1, 2020 at 15:01
  • 1
    This answer is incorrect. The poster is asking about optical cables of unknown length, not DACs with their lengths supplied in the part numbers. Nov 2, 2020 at 13:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.