Just read your last reply which wasnt there when Id started to make mine.
Is the confusion occuring here?
The power down step causes the (Openreach supplied) modems to send a 'dying gasp' (as specified in the relevant BT SIN) to the MSAN which, in turn, recognises that modem signal as an indicator of a power loss event.
Having received a power loss signal, the MSAN sets an internal flag and stops counting the ES (and, thus, SES).
Should that actually read
to the MSAN which, in turn, recognises that modem signal as an indicator of a power loss event loss of electrical power to the router.
Having received a power loss signal, the MSAN sets an internal flag and stops counting the ES (and, thus, SES).
AND/OR
Having received notification of [ 0 ] power state at the remote end through lack of a heartbeat signal and no sync, then no ES/SES error messages will be received.
If the modem is just disconnected from the line, the MSAN continues to count ES (and SES). The values stored in those counters are used by the DLM to determine what (wicked or evil) actions it may apply to the line.
ES/SES dont continue accumulating whilst the modem is out of use. When its out of use there wont be any CRCs/HECs and without those then there is no ES/SES states. You need coding violations (CRCs etc) to enter the router into an ES/SES state. Thus power off = 0 data = 0 coding violations = 0 ES. Not sure how the MSAN could possibly continue counting error states when for a line isnt in sync. regardless or not if the router has send a dying gasp.
They are bit errors (data) Get enough bit errors and then the router enters into an alarm state for a few seconds and comes back out again when there are no more bit errors. Eventually its these alarm states that will cause the router to lose sync, but its the routers job to now try a resync and see if it can sync at a lower speed. The DSLAM doesnt do anything other than continue to record any errors. Its up to the router to try and get itself out of this situation.
Even from the port side.. if the router is off.. then no throughput data can be received therefore no coding violations & no E/S.
Look at it from the other way round. If the DSLAM goes down, the router doesnt continue to rack up Err/Secs. It senses 'no sync' and error counters dont accumulate just because the other end doesnt respond.
Theres old routers possibly still in use that arent capable of sending the dying gasp signal, if their owner unplugs the router, the MSAN doesnt count every second as a E/S.. the heatbeat sorts that. Otherwise can you imagine how many ErrSecs would be racked up if theyd been away on holiday.
Same applies if someone on VDSL pulls the modem cable and leaves the router off for the next week. The heartbeat detects the power off state and stops any counters.
On Be some of their MSANs never reset the counters, so you'd get a constant accumulation of the number of errors for the upstream. It certainly would NOT continue counting and racking up errors when the router wasnt plugged in.
The idea of the dying gasp is purely to say.. hey I went down due to something at this end. Dont worry if Im not up again for x weeks, its not a line fault.
Its intention is simply to give an indication of whether the line is down due to a line fault or power failure.
Dying gasp isnt there to stop the ES count accumulating, it may do it more elegantly, but ES wont accumulate once the DSLAM knows the line isnt in use... regardless of how it went down.