cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1828
Views
5
Helpful
6
Replies

ACE redirect to maintenance url when real server is not avaliable

waltermavely
Level 1
Level 1

Dear all i have ace behind there is 2 real server,i have already done a redirection http to https its working fine,now i want redirect to new you url (diffrent server) when my real servers is outofservice, how can acheive this task please help, i have attached my configuration thank you very much

6 Replies 6

Gilles Dufour
Cisco Employee
Cisco Employee

The idea is to create a redirect serverfarm that you configure as backup for your main serverfarm with your 2 rservers.

Gilles.

Hi,

Modify the policy-map as below and check whether redirect is working when the real servers are down.

policy-map type loadbalance first-match HTTP2HTTPS-POLICY

class class-default

serverfarm HTTP2HTTPS-SF primary SHUTDOWN backup

Hi,

Thank you for your reply. In configuration I did not find command "serverfarm HTTP2HTTPS-SF primary SHUTDOWN backup". I am running below version

---------------------------------------------------------------------------------------------------------

Cisco Application Control Software (ACSW)

TAC support: http://www.cisco.com/tac

Copyright (c) 2002-2008, Cisco Systems, Inc. All rights reserved.

The copyrights to certain works contained herein are owned by

other third parties and are used and distributed under license.

Some parts of this software are covered under the GNU Public

License. A copy of the license is available at

http://www.gnu.org/licenses/gpl.html.

Software

loader: Version 12.2[120]

system: Version A2(1.0a) [build 3.0(0)A2(1.0a) adbuild_04:14:49-2008/04/18_/auto/adbu-rel3/rel_a2_1_throttle/REL_3_0_0_A2_1_0A]

system image file: [LCP] disk0:c6ace-t1k9-mz.A2_1_0a.bin

installed license: ACE-SEC-LIC-K9

Hardware

Cisco ACE (slot: 4)

cpu info:

number of cpu(s): 2

cpu type: SiByte

cpu: 0, model: SiByte SB1 V0.2, speed: 700 MHz

cpu: 1, model: SiByte SB1 V0.2, speed: 700 MHz

memory info:

total: 956180 kB, free: 253656 kB

shared: 0 kB, buffers: 4680 kB, cached 0 kB

cf info:

filesystem: /dev/cf

total: 1000512 kB, used: 390320 kB, available: 610192 kB

last boot reason: reload command by admin

configuration register: 0x1

NR-1-ACE kernel uptime is 104 days 17 hours 35 minute(s) 0 second(s)

---------------------------------------------------------------------------------------------------------

Here are configuration option I see in my ACE;

---------------------------------------------------------------------------------------------------------

NR-1-ACE/ADMIN-CLIENT(config)# policy-map type loadbalance first-match HTTP2HTTPS-POLICY

NR-1-ACE/ADMIN-CLIENT(config-pmap-lb)#

NR-1-ACE/ADMIN-CLIENT(config-pmap-lb)# class class-default

NR-1-ACE/ADMIN-CLIENT(config-pmap-lb-c)# serverfarm ?

Enter serverfarm name (Max Size - 64)

HTTP2HTTPS-SF

SERVERFARM-1

SHUTDOWN

NR-1-ACE/ADMIN-CLIENT(config-pmap-lb-c)# serverfarm HTTP2HTTPS-SF ?

backup Specify backup serverfarm

Carriage return.

NR-1-ACE/ADMIN-CLIENT(config-pmap-lb-c)#

---------------------------------------------------------------------------------------------------------

I did try to configure with backup command but did not help either.

sh rserver SHUTDOWN-Redirect shows it is operational but does not detect and redirect when real servers are down for maintenance.

---------------------------------------------------------------------------------------------------------

NR-1-ACE/ADMIN-CLIENT# sh serverfarm SHUTDOWN

serverfarm : SHUTDOWN, type: REDIRECT

total rservers : 1

---------------------------------

----------connections-----------

real weight state current total failures

---+---------------------+------+------------+----------+----------+---------

rserver: SHUTDOWN-Redirect

0.0.0.0:0 8 OUTOFSERVICE 0 0 0

NR-1-ACE/ADMIN-CLIENT#

NR-1-ACE/ADMIN-CLIENT#

NR-1-ACE/ADMIN-CLIENT# sh rserver SHUTDOWN-Redirect

rserver : SHUTDOWN-Redirect, type: REDIRECT

state : OPERATIONAL (by default, unverified)

---------------------------------

----------connections-----------

real weight state current total

---+---------------------+------+------------+----------+--------------------

serverfarm: SHUTDOWN

0.0.0.0:0 8 OUTOFSERVICE 0 0

---------------------------------------------------------------------------------------------------------

Appreciate your input. Thank you in advance.

Regards,

Bhupesh

Bhupesh,

Define the backup serverfarm configuration as below

sticky ip-netmask 255.255.255.0 address source STICKY_IP

timeout 15

replicate sticky

serverfarm SERVERFARM-1 backup SHUTDOWN

Hey Rajesh,

Its working... Sorry for late reply but I could not do it earlier.

Thank you very much for your suggestions.

Regards,

Bhupesh

Hi Rajesh,

but accoding to Cisco documentation if you configure backup serverfarm within sticky-group configuration mode, then also backup serverfarm will become sticky. And i would say that this is undesired in this case. Because with sticky backup serverfarm only new connections will be directed to primary serverfarm (when servers are operational again) and all sticky connections will be still directed to backup serverfarm. Or do you think that this doesnt apply if backup serverfarm is redirect type?

"Backup Server Farm Behavior with Stickiness

When you associate a server farm with a sticky group using the serverfarm command in sticky configuration mode, the primary server farm inherits the stickiness of the sticky group. The ACE sends requests from the same client to the same server in the primary server farm based on the type of stickiness that you configure in the sticky group. If you also configure a backup server farm using the optional backup keyword of the same command, the backup server farm automatically becomes sticky, too, regardless of whether you configure the sticky option or not.
If all the servers in the primary server farm go down, the ACE sends all connections to the backup server farm. When the primary server farm comes back up (that is, at least one server becomes active), existing connections to the backup server farm continue to be serviced by the backup server farm. The ACE also sends new requests for existing sticky connections to the backup server farm.
The ACE sends all new connection requests to the primary server farm. Such requests include those for which there is no entry in the sticky table, the sticky entry aged out, or the ACE overwrote the sticky entry because the sticky table was full.
If you want to configure a sorry server farm and you want existing connections to revert to the primary server farm after it comes back up, do not use stickiness"

Thank you.

Regards

Michal