Installing and Administering PPP

72 Chapter 4
Common pppd Options
Link Quality Monitoring
Link Quality Monitoring
The Link Quality Monitoring (LQM) option is defined in the PPP protocol
specification. When the PPP implementation supports LQM, PPP can
make policy decisions based on the quality of the link between peers.
When LQM is invoked, pppd requests that the other end of the
connection send Link Quality Report (LQR) packets back to pppd. If the
link goes down or is degraded, many or all of the LQR packets will be
lost. This also indicates that data packets have been lost and the
connection is too bad to warrant continued traffic. pppd counts the
arriving LQRs, and if too many have been lost, pppd closes the
connection. LQM packets do not count against the idle line
disconnection timer, since they are part of the protocol rather than user
data.
Guides for Evaluation of Link Quality
pppd bases its evaluation of the link status on the arguments of two
associated options, lqrinterval and lqthreshold. The value of the
lqrinterval option tells pppd how often to request LQR packets from the
peer machine. The default value is every ten seconds, or five per minute,
allowing for timing slop. lqthreshold's argument is the minimum
acceptable link quality. The default lqthreshold is one out of five packets.
With the default values in place, the link will shut down if no LQR
packets arrived during the previous minute.
Adjusting LQM Behavior
The default LQM behavior, one successful packet out of five sent every
minute, is fairly permissive. pppd is more demanding about line quality
if you change the defaults. Either evaluation setting can be changed to
make LQM more stringent. For example, you can demand that at least
one LQR arrive per minute by specifying
lqrinterval 5 lqthreshold 1/12
Or you can demand that no more than one LQR be lost each minute by
specifying
lqrinterval 5 lqthreshold 11/12