Hi all, how can I get only the total downloaded bytes? Not total bytes like in the example below.
:global Gb
/queue simple
:set Gb [get [find name="LAN"] total-bytes]
Thanks ![]()
Hi all, how can I get only the total downloaded bytes? Not total bytes like in the example below.
:global Gb
/queue simple
:set Gb [get [find name="LAN"] total-bytes]
Thanks ![]()
The “bytes” property contains both total upload and total download in the form “upload/download”, so just get everything after “/”, like so:
:global Gb
/queue simple
:local bytes [get [find name="LAN"] bytes]
:set Gb [:pick $bytes ([:find $bytes "/"]+1)]
Hi, I tested this code but it didnt work… Im getting a blank value. Anyways, could you tell me how can I get this downloaded bytes from interface not simple queue? Like ether1? Thanks.
Total downloaded bytes from one interface you can get with command, for example:
{:local totalRX [/interface ethernet get ether1 rx-bytes];:put “$totalRX”}