Reading long output on device without datadump #306
-
Greetings! |
Beta Was this translation helpful? Give feedback.
Replies: 6 comments 21 replies
-
Hey @Sciti are you sure this doesn’t work? I know folks are using scrapli and edgecore with the community driver. To answer your question, “yes” and “no”. “No” this is not the generic drivers problem, it gives you the base setup and then it’s your responsibility to do whatever you need from there. The “yes” part: sure, you have all the tools you need because can read directly from the transport until you see whatever pattern, then write a space/enter/whatever. But I would bet money you don’t need to do this, you just need to disable paging on the device like the community platform does. |
Beta Was this translation helpful? Give feedback.
-
Yup. edgecore driver works, but as i see in device docs, it doesn't have anything related to terminal length. And thats the problem, because with edgecore community driver, it stuck on '--more--' Tried to use something like this, but i don't fully understand right now how it's actually works..
It's still stuck |
Beta Was this translation helpful? Give feedback.
-
Hi! My idea of working with such equipment is as follows. How can this be implemented? |
Beta Was this translation helpful? Give feedback.
-
@Sciti I have a Edge-Core ES3528M switch. It has the ability to set the terminal length. The following may be of some help to you:
|
Beta Was this translation helpful? Give feedback.
-
I can't seem to find a way to disable pagination on TP-Link switches with the first firmware version either. These are JetStream switches (TL-SG) as well as TL-SL series switches. There is a way to disable pagination on TP-Link switches with the second firmware version and I know it. |
Beta Was this translation helpful? Give feedback.
-
@denisbondar Greetings, I got something working, thanks to Carl advice for read_callback! Look into read_callback, there's great example, but now another problem appeared 😓 |
Beta Was this translation helpful? Give feedback.
Hello, friends!
Thanks to @carlmontanari for providing a great example!
Unfortunately, the documentation, which is always very hard to write, is not completely clear for read_callback (and also a bit behind the code).
To make your example work more properly, inside the paginate_callback callback you need to add a new line to the buffer:
Otherwise, the next line is added to the end of the "pagination hint".
My example of using pagination looks like this (I use my extra layer of drivers for ease of instanti…