cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1456
Views
0
Helpful
21
Replies

How do I do this?

ryanlin2002
Level 1
Level 1

Hi all

My home network consists of two SSIDS, a Home SSID and a Guest SSID.

I have service policy maps applied to both SSIDs to restrict the bandwidth usage.

The Guest SSID is not being used that often in the house, which results in bandwidth being wasted.

What I would like to accomplish is the following:

1. The ability to give Home SSID full bandwidth when there are no guests connected to the Guest SSID.

2. When Guest SSID detects a host or multiple hosts, the Home SSID should give the bandwidth back to the Guest SSID.

For example...

On a 64kbps link, the home ssid is assigned 32kbps and the guest ssid is assigned 32kbps respectively.

When there are no guest machines connected to the guest ssid, the Home ssid network should get the full 64kbps.

If one guest or multiple guests are connected to the guest ssid, then the home ssid should revert back to 32kbps automatically.

I know how to do this if there is only one guest host on the network. I can match the connection patterns in the syslog by looking at the association and deassociation messages. However, this solution would no longer be feasible if there are multiple guest hosts on the guest ssid.

Any suggestions on how to accomplish this?

Thanks

21 Replies 21

almost there..it's working "halfy"

now it sets the bandwidth to full in both upstream and downstream (5050000 and 612000) when these two conditions are met:

1. guest joining the guest ssid

2. guest leaving the guest ssid

here is what i have:

event manager applet guest-bandwidth

event tag assoc syslog pattern "DOT11-6-ASSOC"

event tag disassoc syslog pattern "DOT11-6-DISASSOC"

trigger

correlate event assoc or event disassoc

action 001 cli command "enable"

action 002 cli command "more flash:/dot11_as.txt"

action 003 set reading_guest "0"

action 004 set found_guest "0"

action 005 foreach line "$_cli_result" "\n"

action 005.1 string trim "$line"

action 005.2 set line "$_string_result"

action 006 regexp "SSID .Guest.*:" "$line"

action 007 if $_regexp_result eq 1

action 008 set reading_guest "1"

action 009 continue

action 010 end

action 011 if $reading_guest eq 1

action 012 regexp "SSID.*:" "$line"

action 013 if $_regexp_result eq 1 goto 023

action 016 regexp "MAC Address" "$line"

action 017 if $_regexp_result eq 1

action 018 set found_guest "1"

action 020 end

action 021 end

action 022 end

action 023 if $found_guest eq 1

action 024 cli command "config t"

action 025 cli command "policy-map QoS_In_BVI1"

action 026 cli command "class class-default"

action 027 cli command "police 462000"

action 028 cli command "exit"

action 029 cli command "policy-map QoS_Out_BVI1"

action 030 cli command "class class-default"

action 031 cli command "police 4550000"

action 032 cli command "end"

action 033 syslog msg "Found guest(s) associated; adding bandwidth"

action 034 else

action 035 cli command "config t"

action 036 cli command "policy-map QoS_In_BVI1"

action 037 cli command "class class-default"

action 038 cli command "police 612000"

action 039 cli command "exit"

action 040 cli command "policy-map QoS_Out_BVI1"

action 041 cli command "class class-default"

action 042 cli command "police 5050000"

action 043 cli command "end"

action 044 syslog msg "No guests associated; removing bandwidth"

action 045 end

!

thanks a lot :)

Grr, I pasted my test version. You need to change action 002 to:

action 002 cli command "show dot11 as"

Just to be clear, try:

event manager applet guest-bandwidth

event tag assoc syslog pattern "DOT11-6-ASSOC"

event tag disassoc syslog pattern "DOT11-6-DISASSOC"

trigger

correlate event assoc or event disassoc

action 001 cli command "enable"

action 002 cli command "show dot11 as"

action 003 set reading_guest "0"

action 004 set found_guest "0"

action 005 foreach line "$_cli_result" "\n"

action 005.1 string trim "$line"

action 005.2 set line "$_string_result"

action 006 regexp "SSID .Guest.*:" "$line"

action 007 if $_regexp_result eq 1

action 008 set reading_guest "1"

action 009 continue

action 010 end

action 011 if $reading_guest eq 1

action 012 regexp "SSID.*:" "$line"

action 013 if $_regexp_result eq 1 goto 023

action 016 regexp "MAC Address" "$line"

action 017 if $_regexp_result eq 1

action 018 set found_guest "1"

action 020 end

action 021 end

action 022 end

action 023 if $found_guest eq 1

action 024 cli command "config t"

action 025 cli command "policy-map QoS_In_BVI1"

action 026 cli command "class class-default"

action 027 cli command "police 462000"

action 028 cli command "exit"

action 029 cli command "policy-map QoS_Out_BVI1"

action 030 cli command "class class-default"

action 031 cli command "police 4550000"

action 032 cli command "end"

action 033 syslog msg "Found guest(s) associated; adding bandwidth"

action 034 else

action 035 cli command "config t"

action 036 cli command "policy-map QoS_In_BVI1"

action 037 cli command "class class-default"

action 038 cli command "police 612000"

action 039 cli command "exit"

action 040 cli command "policy-map QoS_Out_BVI1"

action 041 cli command "class class-default"

action 042 cli command "police 5050000"

action 043 cli command "end"

action 044 syslog msg "No guests associated; removing bandwidth"

action 045 end

YES!!! It's working!! Thank you thank you!!!!

I assume the 60 seconds statement still applies to this new config, correct?

Thank you so much! i am very grateful for your assistance :)

Yes, you will want to add the 60 second countdown timer to prevent problems if the router reboots while a guest is still logged in.

okay, will do.

Thanks again :)

duplicate

Review Cisco Networking for a $25 gift card