Get traffic usage via PEAR2 API

Using a specialized tool that analyzes SNMP and/or Netflow to generate a graph would be most efficient for the router indeed.

If you’re OK with sacrificing some of that efficiency for the purposes of customizable implementation, the other way would be to detect a new PPPoE interface appearing (see your other topic), and when a new one appears, issue an “/interface monitor-traffic” command, and collect the results into your DB, from where you can later draw graphs.