Forum Discussion

Aaron_33366's avatar
Aaron_33366
Icon for Nimbostratus rankNimbostratus
Mar 14, 2011

Wildcard cookie

Hello. I have migrated my config from a Cisco CSS to an F5 LTM and have run into a problem. One the CSS I was able to have a cookie that was use for all parts of the domain. I was able to set the option called "cookie-domain" on the Cisco CSS and that could would work for all subdomains. Below is a link to that info on Cisco's site.

http://www.cisco.com/en/US/docs/app...wp1178181

 

 

I have been looking for this option on the F5 but have not been able to find it. I have look under the persistence profile and creating a new one however I dont see that option for a cookie-domain or anything like a wild card cookie. I am assuming that I might have to do this in an iRule or that the option I need to set is not in the persistence profile are of the GUI and that I might have to make this modification via the CLI with the bigpip command. I currently have a F5 ticket open for this but havent gotten far with it so I thought I would post this question out in the wild and see what I could find.

 

 

The key is that if a user goes to site1.domain.com or site2.domain.com or site3.domain.com I need that user to stay stuck/persisted to the same server they were load balanced to. These sites all need to have their own virtual servers because they have SSL so they all need their own IP address.

 

 

Below is a link that I found that that shows how to do this in PHP and a snippet from the page. However I need to do this on the F5 and I need to be able to set the value of the cookie to the pool member the user was load balanced to.

 

 

 

http://www.webdeveloper.com/forum/showthread.php?t=198526

 

 

PHP Code:

 

setcookie('name', $value, time()+$duration, '/', '.example.com')

 

 

Note the leading dot at the start of the ".example.com".

 

 

 

Thanks in advanced for any help that you can provide on this.

 

-Aaron

 

 

17 Replies

  • Hoolio our posts crossed each other :) We must have bee posting at the same time. You answered my question about how to go about getting the feature request. I certainly will post the info once I have it.

     

     

    Thanks again,

     

    Aaron

     

     

  • Yeah, Support will ask you to fill out a template describing the new feature and how it would help. They'll give you a request number and add it to the list of RFE's which PM/PD consider.

     

     

    Thanks for doing this. It will have more weight if it comes directly from a customer than from me :)

     

     

    Aaron
  • Over the past week we tested the iRule setting the cookie-domain and it worked in all our testing. Last night we implemented this in production and it worked for all the sites we applied this iRule to. Today we have not heard any complaints or problems. I have updated my F5 ticket with this information. I also requested the RFE today. I was waiting for a successful testing of the iRule before doing the RFE. Once I get the RFE I will post that number here.

     

     

    Thanks again for all the help!

     

    Aaron

     

  • edit- sorry re-read this and didn't want to include any wrong info in a usefull post..

     

     

     

  • Colin_Walker_12's avatar
    Colin_Walker_12
    Historic F5 Account
    Aaron - Great news, I'm very glad to hear this worked. Definitely update once you get the RFE so we can all pile on. ;)

     

     

    Thanks,

     

    Colin
  • Hello all. I have gotten a reply back from the F5 tech assigned to my ticket. Below is what I was emailed back.

     

     

    ===============

     

    Aaron, an Enterprise Network Engineer has reviewed the subcase and has determined that an existing RFE ID 273573 already exists. I have requested that the subcase be attached to that RFE. There is no ETA at this time.

     

     

    In the future, to follow up on the request, please open a new case and refer to RFE ID 273573.

     

    ===============

     

     

    Thanks,

     

    Aaron

     

  • Colin_Walker_12's avatar
    Colin_Walker_12
    Historic F5 Account
    Good to know. Now, to anyone that thinks this is interesting / valuable, get ahold of your sales and or support rep and let them know. ;)

     

     

    Thanks Aaron.

     

     

    Colin