Changing rate-limit with CoA

Shaper related questions
Post Reply
gondim
Posts: 64
Joined: 04 Mar 2016, 14:44

Changing rate-limit with CoA

Post by gondim »

Hi Dmitry,

I'm trying to change a client's rate-limit using CoA but I'm not having success. Would you help me? Below is the command I am using:

(root@radius)[~]# echo Acct-Session-Id="b278b9cb4d727217",Cisco-AVPair="lcp:interface-config#1=rate-limit input 31457280 8000 8000 conform-action transmit exceed-action drop" | /usr/bin/radclient -x 138.xxx.xxx.39:3799 coa secret1324
Sent CoA-Request Id 119 from 0.0.0.0:32308 to 138.xxx.xxx.39:3799 length 66
Acct-Session-Id = "b278b9cb4d727217"
Cisco-AVPair = "lcp:interface-config"
Sent CoA-Request Id 119 from 0.0.0.0:32308 to 138.xxx.xxx.39:3799 length 66
Acct-Session-Id = "b278b9cb4d727217"
Cisco-AVPair = "lcp:interface-config"
Sent CoA-Request Id 119 from 0.0.0.0:32308 to 138.xxx.xxx.39:3799 length 66
Acct-Session-Id = "b278b9cb4d727217"
Cisco-AVPair = "lcp:interface-config"
(0) No reply from server for ID 119 socket 3

I was able to disconnect the user by doing:

(root@radius)[~]# echo Acct-Session-Id="b278b9cb4d727217" | /usr/bin/radclient -x 138.xxx.xxx.39:3799 disconnect secret1324
Sent Disconnect-Request Id 218 from 0.0.0.0:45609 to 138.xxx.xxx.39:3799 length 38
Acct-Session-Id = "b278b9cb4d727217"
Received Disconnect-ACK Id 218 from 138.xxx.xxx.39:3799 to 0.0.0.0:0 length 20
Dmitry
Администратор
Posts: 954
Joined: 09 Oct 2014, 10:06

Re: Changing rate-limit with CoA

Post by Dmitry »

check accel-ppp logs, does it has to log CoA request
gondim
Posts: 64
Joined: 04 Mar 2016, 14:44

Re: Changing rate-limit with CoA

Post by gondim »

Hi Dmitry,

In the log it shows this:

[2017-12-21 02:17:29]: warn: radius:dm_coa: RA validation failed
[2017-12-21 02:17:34]: warn: radius:dm_coa: RA validation failed
[2017-12-21 02:18:01]: warn: radius:dm_coa: RA validation failed
[2017-12-21 02:18:06]: warn: radius:dm_coa: RA validation failed
[2017-12-21 02:18:11]: warn: radius:dm_coa: RA validation failed
[2017-12-21 02:36:24]: warn: radius:dm_coa: RA validation failed
[2017-12-21 02:36:29]: warn: radius:dm_coa: RA validation failed
[2017-12-21 02:36:34]: warn: radius:dm_coa: RA validation failed
gondim
Posts: 64
Joined: 04 Mar 2016, 14:44

Re: Changing rate-limit with CoA

Post by gondim »

If I run only with the Acct-Session-Id, it works:

(root@radius)[~]# echo Acct-Session-Id="b278b9cb4d727215" | /usr/bin/radclient -x 138.xxx.xxx.39:3799 coa secret1324
Sent CoA-Request Id 227 from 0.0.0.0:4175 to 138.xxx.xxx.39:3799 length 38
Acct-Session-Id = "b278b9cb4d727215"
Received CoA-ACK Id 227 from 138.xxx.xxx.39:3799 to 0.0.0.0:0 length 20

But when I add Cisco-AVPair to change the speed it stops responding:

(root@radius)[~]# echo Acct-Session-Id="b278b9cb4d727215",Cisco-Avpair=\"lcp:interface-config#1=rate-limit input 31457280 8000 8000 conform-action transmit exceed-action drop\" | /usr/bin/radclient -x 138.xxx.xxx.39:3799 coa secret1324
Sent CoA-Request Id 89 from 0.0.0.0:50760 to 138.xxx.xxx.39:3799 length 147
Acct-Session-Id = "b278b9cb4d727215"
Cisco-AVPair = "lcp:interface-config#1=rate-limit input 31457280 8000 8000 conform-action transmit exceed-action drop"
Sent CoA-Request Id 89 from 0.0.0.0:50760 to 138.xxx.xxx.39:3799 length 147
Acct-Session-Id = "b278b9cb4d727215"
Cisco-AVPair = "lcp:interface-config#1=rate-limit input 31457280 8000 8000 conform-action transmit exceed-action drop"
Sent CoA-Request Id 89 from 0.0.0.0:50760 to 138.xxx.xxx.39:3799 length 147
Acct-Session-Id = "b278b9cb4d727215"
Cisco-AVPair = "lcp:interface-config#1=rate-limit input 31457280 8000 8000 conform-action transmit exceed-action drop"
(0) No reply from server for ID 89 socket 3
Dmitry
Администратор
Posts: 954
Joined: 09 Oct 2014, 10:06

Re: Changing rate-limit with CoA

Post by Dmitry »

commit 2e06c8c9278ab283907f3bb9d1fa28c5edb5f1e4
gondim
Posts: 64
Joined: 04 Mar 2016, 14:44

Re: Changing rate-limit with CoA

Post by gondim »

Thanx!!!!! Perfect!!!! :D

Sent CoA-Request Id 218 from 0.0.0.0:15394 to 138.xxx.xxx.39:3799 length 257
Acct-Session-Id = "b278b9cb4d727609"
Cisco-AVPair = "lcp:interface-config#1=rate-limit output 20000000 8000 8000 conform-action transmit exceed-action drop"
Cisco-AVPair = "lcp:interface-config#1=rate-limit input 20000000 8000 8000 conform-action transmit exceed-action drop"
Received CoA-ACK Id 218 from 138.xxx.xxx.39:3799 to 0.0.0.0:0 length 20

Best regards,
gondim
Posts: 64
Joined: 04 Mar 2016, 14:44

Re: Changing rate-limit with CoA

Post by gondim »

Hi Dmitry,

We made a donation to you of $ 200. It is not much but we believe that I can help you and it is a way to thank the excellent work that you have done for the community.

Who did was Matheus Almeida, our COO (Chief Operating Officer). :D

Thanks and best regards.
Dmitry
Администратор
Posts: 954
Joined: 09 Oct 2014, 10:06

Re: Changing rate-limit with CoA

Post by Dmitry »

thank you
Post Reply