Memcached is a key/value-based storage system with a high response rate which, as the name suggests, is used to temporarily store frequent data in memory and avoid re-querying for them. Next, you’ll know how to install this database either Windows or a Linux distribution.
Install Memcached on Windows
Once downloaded we will unzip the file and run the memcached program.exe with the -d install parameter, which we can easily invoke from the CMD by typing the following:
c:\memcached\memcached.exe -d install
The above command should work in case we have unzipped Memcached under the directory c:-memcached
Install Memcached on Debian
It is not very difficult to install on Debian or Ubuntu as we have a repository with this by default. Simply use the following in the terminal:
sudo apt update sudo apt install memcached libmemcached-tools
Install Memcached on CentOS/RedHat
It is also not difficult to install it on Distributions based on CentOS or RedHat since, like Debian, here we also have in the default repository the installer.
yum -y install memcached
If we are thinking of using Memcached to cache other software we must first have an add-on that works as a bridge between the two.
# To use Memcached in PHP sudo apt install php-memcached # To use Memcached from Python pip3 install pymemcache # To use Memcached from NodeJS npm install memcached
Memcached is used by many companies, projects, and work environments that need to write and read temporary data with the shortest possible response time. In this way we will greatly optimize the application preventing it from querying frequent data or that have been consulted recently.