Inconsistent system time causes memcached session to not share

Source: Internet
Author: User
Tags memcached

The test server needs to be load balanced, using Nginx+tomcat.

After the load balancer configuration is successful, the session synchronization is configured with memcached. A total of 4 servers, three servers successfully configured successful, the last server can not be shared.

The process of solving this problem is tortuous and is not limited to the following operations.

Rebooting the system

Check the rational configuration countless times

Redeploy an app

Replicate normal host application to native

Copy normal host Tomcat to native

。。

Intermittent, add up to engage at least for a day of time, still no effect.

Application and application server are consistent, the basic can be queued is the problem of the program, it can only be host problems, I almost want to restart the host. However, a remote host restart can be very cumbersome and give up.

Looking for ah, in the Internet search a lot of information, in the end, in the process of finding, found a word in an article, the point woke me.

A consistent timestamp between servers is also important, because time inconsistency will directly cause the session to expire.

Check it out, sure enough. Three servers are the right time, and a machine's time is 9 hours late.

Workaround:

:xx 

Try again, it's normal.

Inconsistent system time causes memcached session to not share

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.