My question is: what's the best algorithm for constrcting broadband access record from radius accouting packets?
Read the RFC. No, I am being serious.
Record Accouting-on packet arriving time -> record Accouting-Off packet's Acct-Session-Time and Acct-Delay-Time ->
The Log-off time is calculated as:
Accouting-on time + ( Acct-Session-Time - Acct_delay-Time)
Or, take the acct record from logoff, and: (time stop acct record rec'd) - (acct-delay-time) Either will work. However, it's somewhat more common to do what I suggest.
Log-on time is calculated as:
Accouting-off arriving time - ( Acct-Session-Time - Acct_delay-Time)
Yes.
Are the two methods have the same effect on calculating result? If radius packets were sent to two accouting systems simulataneusly, while the two system takes the different algorithm, will there be any difference between the result of accouting ?
They should yield (approximately) the same result. But, to be pedantic, you haven't accounted for latency within the network.