You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Traceroute tool on Mikrotik ROS operates like an MTR and continually updates the console with metrics. This can be avoided with count=1 but if the traceroute encounters a blank hop for any reason, the router rewrites the console anyway. If running the traceroute with no controlling terminal, as in the case of an LG, the result gets output in chunks and only the final chunk is actually useful.
A solution is to explode the resultant string data into an array using the blank line between each chunk as a deliminator and then takes the final index as the resultant string.
Adding $filtered = end(explode("\n\n",trim($filtered))); Somewhere before the filtered output is returned has fixed this issue on our install of LG. We have added it just before return preg_replace('/(?:\n|\r\n|\r)$/D', '', $filtered);
The text was updated successfully, but these errors were encountered:
The Traceroute tool on Mikrotik ROS operates like an MTR and continually updates the console with metrics. This can be avoided with count=1 but if the traceroute encounters a blank hop for any reason, the router rewrites the console anyway. If running the traceroute with no controlling terminal, as in the case of an LG, the result gets output in chunks and only the final chunk is actually useful.
A solution is to explode the resultant string data into an array using the blank line between each chunk as a deliminator and then takes the final index as the resultant string.
Adding
$filtered = end(explode("\n\n",trim($filtered)));
Somewhere before the filtered output is returned has fixed this issue on our install of LG. We have added it just beforereturn preg_replace('/(?:\n|\r\n|\r)$/D', '', $filtered);
The text was updated successfully, but these errors were encountered: