Cookies in Staging and Production

    • 6 posts
    September 29, 2017 5:49 AM EDT

    Hi!

     

    I have my socialengine installed in a staging server, like: https://www.domainstaging.com/test/mysocialengine

     

    and through a reverse proxy, it is mirrored in 

    https://www.domainproduction.com/test/mysocialengine

     

    and I can't get the cookies, they always appear attached to the staging domain which I don't want....

     

    I have two SE licenses for both domains, so I don't understand why cookies aren't loaded in the production one....

     

    Has anyone here faced anything like this?

     

    Thank you in advance!

    • 6 posts
    September 29, 2017 6:11 AM EDT

    well, when we log in production server, it redirects us to staging server...

    • Moderator
    • 6923 posts
    September 29, 2017 9:56 AM EDT

    This is beyond me. You would want to contact our support for one of our technicians to answer if you have support access.

    • 6 posts
    September 29, 2017 10:01 AM EDT

    thank you Donna, so I will!

    • 154 posts
    September 29, 2017 8:48 PM EDT

    Hi Kuni 

    I raised this some time ago, no one could figure it really.

    Best advice I can give, and what I have to do Is have two browsers or incognito mode the other.
    Or clear your cookies.

    • 6 posts
    September 30, 2017 5:07 AM EDT

    Hi Daniel,

     

    thank you for your answer! the problem is that when login intro prod. mode, redirects you to the dev. mode.

     

    I guess the best option is to set the Base Uri pointing not only the links but also the cookies to production mode, otherwise neither me nor my users will be able to login and use the platform in production.

     

    • 154 posts
    September 30, 2017 11:47 AM EDT

    Thats kinda what happened to but with an additional thing too

    If you put both sites into maintenence mode.

    You can put in maintenence code on one.
    but if goto the staging servers maintenence page and enter code also, It wont accept it.

    • 6 posts
    September 30, 2017 2:38 PM EDT

    well in our case, once the development site is set to maintenance, the prod. site (whose dashboard is not accesible due to the login issue) gets offline.

     

    I will keep you posted once it is solved!

    • 66 posts
    October 23, 2017 11:23 PM EDT

    I encountered the cookie issue when setting up ELB on AWS years ago with SE but I ***THINK*** I recall what the solution was. The ELB would preform the load distribution with each page load to the best server at the moment so each time a user could hit a different server. Are you using file caching? I seem to recall that we setup a memcache cluster (you could do one server) that each server used for its cache. So they will all pull from that one server for the cache and not to each separate server the user might be on..... but do not quote me on this.... It was years ago.... and since then the separate cache server has always been used.

    • 66 posts
    October 23, 2017 11:23 PM EDT

    I encountered the cookie issue when setting up ELB on AWS years ago with SE but I ***THINK*** I recall what the solution was. The ELB would preform the load distribution with each page load to the best server at the moment so each time a user could hit a different server. Are you using file caching? I seem to recall that we setup a memcache cluster (you could do one server) that each server used for its cache. So they will all pull from that one server for the cache and not to each separate server the user might be on..... but do not quote me on this.... It was years ago.... and since then the separate cache server has always been used.

    • 6 posts
    October 24, 2017 2:27 PM EDT

    wow thank you for the answer Casey!

     

    I have been checking with the SE issue but I only have access to the development server, so I guess there was not much to do. I will copypaste your message to the person in charge of this and see what we can do and if we can solve the problem I will let you know.

     

    Thank you for your post, really appreciate it!

    • 66 posts
    October 24, 2017 4:15 PM EDT

    Please let me know if that worked!

    • 66 posts
    November 8, 2017 12:42 PM EST

    @Kuni, did adding a separate server to handle SE cache solve the cookie issue for you between servers?