memcached for Windows modify port and maximum memory

Source: Internet
Author: User

To use memcached in Windows, you must first download the memcached for Win32 installation.

Download Address: http://jehiah.cz/projects/memcached-win32/

After decompression, just enter the following command in the Command Window c:\memcached\memcached.exe-d install can install memcached as a Windows service.

When the service is started, the Memcached service uses the default port of 11211, and the maximum memory consumed by default is 64M.

In the modification of these 2 configuration options encountered a number of problems, the Internet search a lot of information, said to use the following command to start the service can be:

C:\memcached\memcached.exe-p 12345-m 1024-d Start,-p represents the port to be modified, and-m represents the maximum memory occupied (in M).

However, no matter how this command is invoked, the port is still 11211.

When you open the Windows Services Control Panel, you find that there are no-p-m parameters in the Memcached.exe default installed server startup parameters, only 1-d runservice parameters.

So no matter what command to start the service is useless, see the following figure:

Then think of directly modify the Windows service startup parameters, the following operation, open the registry, find:

Hkey_local_machine\system\currentcontrolset\services\memcached Server

The value of the ImagePath entry is: "C:\memcached\memcached.exe"-D runservice

Change to: "C:\memcached\memcached.exe"-p 12345-m 128-d Runservice

Restart the memcached service after saving, and then enter Netstat-n-A at the command line to see if the port is changed now, ^_^.

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.