Learning & Integrating web technology and code help directory

What is Memcached

No comments

What is Memcached ?


Memcached is an open source, high-performance, distributed memory object caching system. This tutorial provides a basic understanding of all the relevant concepts of Memcached needed to create and deploy a highly scalable and performance-oriented system.
Software professionals, students and IT enthusiats who wish to learn and apply the concepts of Memcached in simple and easy steps should read this tutorial.
This tutorial has been designed for absolute beginners and to get best out of it the reader should know the basics of data structures.
Memcached is an open source, high-performance, distributed memory caching system intended to speed up dynamic web applications by reducing the database load. It is a key-value dictionary of strings, objects, etc, stored in the memory, resulting from database calls, API calls, or page rendering.
Memcached was developed by Brad Fitzpatrick for LiveJournal in 2003. However, it is now being used by Netlog, Facebook, Flickr, Wikipedia, Twitter, and YouTube among others.
The key features of Memcached are as follows −
  • It is open source.
  • Memcached server is a big hash table.
  • It significantly reduces the database load.
  • It is perfectly efficient for websites with high database load.
  • It is distributed under Berkeley Software Distribution (BSD) license.
  • It is a client-server application over TCP and/or UDP.

Memcached is not −

  • a persistent data store
  • a database
  • application-specific
  • a large object cache
  • fault-tolerant or
  • highly available

Installing Memcached on Ubuntu

To install Memcached on Ubuntu, go to terminal and type the following commands −
$sudo apt-get update
$sudo apt-get install memcached

Confirming Memcached Installation

To check if Memcached is presently running or not, run the command given below −
$ps aux | grep memcached
This command should show that Memcached is running on the default port11211.
To run Memcached server on a different port, run the command given below −
$memcached -p 11111 -U 11111 -u user -d
It should start the server and listen on TCP port 11111 and UDP port 11111as a daemon process.
This command is explained below −
  • -p is for TCP port number
  • -U is for UDP port number
  • -u is for user name
  • -d runs memcached as daemon process
You can run multiple instances of Memcached server through a single installation.

No comments :

Post a Comment