Issues w/ ppp compression (renamed)

Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking
Author Message
flyingfishfinger
DD-WRT Novice


Joined: 26 Feb 2023
Posts: 31

PostPosted: Fri Jun 02, 2023 22:12    Post subject: Issues w/ ppp compression (renamed) Reply with quote
Hi,
I've set up a very slow ppp link to receive connectivity from a wireless serial modem. That part works, but it is EXTREMELY slow. The actual baud rate is 38.4k - but the throughput I'm getting is far less, around 8 kbps.

Currently ppp is running with the -noccp flag and an MTU of 296 for reliability (!), since omitting it (and hoping for a small improvement via compression) causes dd-wrt's logs to say
Code:
"ppp0: ppp: compressor dropped pkt"
endlessly and no working connection.

Does ppp on dd-wrt support any kind of compression scheme? I'm not looking for header compression, but data compression. If yes, does it require a certain MTU to work?

Thanks,
R


Last edited by flyingfishfinger on Sun Jun 11, 2023 17:36; edited 1 time in total
Sponsor
kernel-panic69
DD-WRT Guru


Joined: 08 May 2018
Posts: 14125
Location: Texas, USA

PostPosted: Fri Jun 02, 2023 23:08    Post subject: Reply with quote
BSD PPP compression should be available.... but no detailed information, just a blind question without doing research for yourself. Be happy I obliged the 5 minutes to find these.

https://forum.dd-wrt.com/forum/viewtopic.php?t=15100

https://svn.dd-wrt.com/browser/src/router/pppd/FAQ

https://svn.dd-wrt.com/browser/src/router/rp-pppoe/doc/CHANGES#L22

https://svn.dd-wrt.com/browser/src/router/rp-pppoe/doc/KERNEL-MODE-PPPOE

https://github.com/mirror/dd-wrt/search?q=CONFIG_PPP_BSDCOMP

https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=334612&start=3&highlight=compression

_________________
"Life is but a fleeting moment, a vapor that vanishes quickly; All is vanity"
Contribute To DD-WRT
Pogo - A minimal level of ability is expected and needed...
DD-WRT Releases 2023 (PolitePol)
DD-WRT Releases 2023 (RSS Everything)

----------------------
Linux User #377467 counter.li.org / linuxcounter.net
flyingfishfinger
DD-WRT Novice


Joined: 26 Feb 2023
Posts: 31

PostPosted: Fri Jun 02, 2023 23:24    Post subject: Reply with quote
Fair enough, thank you & apologies for lack of info. FWIW, I've spent a couple hrs trying various things that always resulted in errors, only then did I post. For more information, this is:

Firmware Version: DD-WRT v3.0-r52004 std (03/13/23)
Kernel Version: Linux 4.14.306 #3600 SMP Mon Mar 13 07:15:19 +06 2023 mips

And syslog DOES show:

Jan 1 01:00:16 DD-WRT kern.info kernel: [ 4.938130] PPP BSD Compression module registered
Jan 1 01:00:16 DD-WRT kern.info kernel: [ 4.947513] PPP Deflate Compression module registered
Jan 1 01:00:16 DD-WRT kern.info kernel: [ 4.957581] PPP MPPE Compression module registered

...so yes, it should work. And if I'm understanding this correctly, if no arguments are given, ccp should negotiate one of the available schemes but it does not.

Come to think of it, I haven't yet tried "noccp" along with "deflate x,y" yet. Maybe that will help.

EDIT: Tried the above, no errors on either end of the link. However:

Code:
pppstats -z
IN:  COMPRESSED  INCOMPRESSIBLE   COMP | OUT: COMPRESSED  INCOMPRESSIBLE   COMP
    BYTE   PACK     BYTE   PACK  RATIO |     BYTE   PACK     BYTE   PACK  RATIO
       0      0        0      0   0.00 |        0      0        0      0   0.00


So, compression is not being used after all it seems.

Thanks,
R
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1855
Location: Hung Hom, Hong Kong

PostPosted: Sun Jun 04, 2023 7:41    Post subject: Reply with quote
Related???

debian - How can I tell if PPP compression is enabled for modem? - Unix & Linux Stack Exchange
https://unix.stackexchange.com/questions/117172/how-can-i-tell-if-ppp-compression-is-enabled-for-modem

Common PPP Configuration Problems
https://docs.oracle.com/cd/E19253-01/816-4555/ppp.trouble-110/index.html

_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
flyingfishfinger
DD-WRT Novice


Joined: 26 Feb 2023
Posts: 31

PostPosted: Sun Jun 11, 2023 17:54    Post subject: Reply with quote
Well, I did some experiments and so far I've found the problem seems to be specific to ppp on dd-wrt.

First, I thought the issue was my weird radio link so I removed that and replaced it with a straight-through physical cable - same result. Then I thought it was because I'm using a very small MTU of 296, so I made that 1500 - same result ("ppp: compressor dropped pkt")

Then I replaced the entire router end (client) with a Linux computer but kept the same host hardware (Raspberry Pi, which provides the connection). I ran the exact same command that I had on dd-wrt (except that I started with an MTU of 1500) - WORKS!
Then I reduced the MTU to 296 - which breaks IPV6, but otherwise this also works.

The key line in the debug output of ppp is thus:
Code:
rcvd [CCP ConfAck id=02 <deflate 15> <deflate(old#) 15> <bsd v1 15>]
Deflate (15) compression enabled


The result when using dd-wrt however is different, an endless loop of ConfReq, ConfRej and ConfAck packets:

Code:
sent [CCP ConfReq id=0x1 <deflate 15> <deflate(old#) 15> <bsd v1 15>]
rcvd [CCP ConfReq id=0x3 <mppe -H -M -S -L -D -C> <deflate 15> <deflate(old#) 15> <bsd v1 15>]
sent [CCP ConfRej id=0x3 <mppe -H -M -S -L -D -C>]
rcvd [CCP ConfAck id=0x1 <deflate 15> <deflate(old#) 15> <bsd v1 15>]
sent [CCP ConfReq id=0x1 <deflate 15> <deflate(old#) 15> <bsd v1 15>]
rcvd [CCP ConfReq id=0x3 <mppe -H -M -S -L -D -C> <deflate 15> <deflate(old#) 15> <bsd v1 15>]
sent [CCP ConfRej id=0x3 <mppe -H -M -S -L -D -C>]
rcvd [CCP ConfAck id=0x1 <deflate 15> <deflate(old#) 15> <bsd v1 15>]
sent [CCP ConfReq id=0x1 <deflate 15> <deflate(old#) 15> <bsd v1 15>]
rcvd [CCP ConfAck id=0x1 <deflate 15> <deflate(old#) 15> <bsd v1 15>]
rcvd [CCP ConfReq id=0x3 <mppe -H -M -S -L -D -C> <deflate 15> <deflate(old#) 15> <bsd v1 15>]
sent [CCP ConfRej id=0x3 <mppe -H -M -S -L -D -C>]
......


The way I understand it is that the client (dd-wrt) offers mppe, deflate and bsd compression, but host (Raspberry Pi) can't do MPPE, so they agree to remove mppe from the choices. After that, at least one side should say "Enabled", as above.

However, they never do. The only difference I can see is the "id=02" in the working case and "id=01" in the failing case, but I can't find any docs about that.

TLDR: I think this problem is specific to dd-wrt - how could I go about debugging this?

Thanks,
R
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum