I'm trying to influence our routing so that traffic that is coming into our network via a certain AS number will hopefully avoid that AS number and take a different path. I'm thinking of doing this using AS prepends to the specific AS number, is the following example correct please?
The AS i want to avoid is listed below as 22222, the "match community 2" statement is a community ACL we use to match ours and our customers prefixes that we advertise to the net.
ip as-path access-list 1 permit _22222$
route-map test-out permit 5
match as-path 1
set as-path prepend 11111 11111 11111 11111
route-map test-out permit 10
match community 2
The reason behind this is we are trying to get a reliable connection back from a host. This hosts AS has two paths out, one is very unreliable and the other is fine. So hopefully by sending our prefixes to the unreliable AS with prepends, the target AS will see this information and take the better path back to our network.
If this is correct, Is this the best way to achieve these results?
Thanks in advance