PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Saturday, November 12, 2022

[FIXED] How to install memcached from binaries and include in c file

 November 12, 2022     c, c++, linux, memcached, ubuntu     No comments   

Issue

I am trying to install memcached on ubuntu 16.04. I need to install it manually as I want to modify the files. I also don't want to install it locally as my changes might not be what other people want from their memcached.

I have tried following the instructions from the github https://github.com/memcached/memcached/wiki/Install (changing the prefix and libevent path to be in my home directory).


Libevent installation:

./configure --prefix=/path/to/home/local_include

make

make install


This seemed to work as the memcached config did not complain.


memcached installation:

wget https://memcached.org/latest

tar -zxf memcached-1.5.13.tar.gz

./configure --prefix=/path/to/home/local_include --with-libevent=/path/to/home/local_include

make

make test

make install


Doing this I saw no errors. This is the result when I finished make install:

 make  install-recursive
 make[1]: Entering directory `/path/to/home/memcached-1.5.13'
 Making install in doc
 make[2]: Entering directory `/path/to/home/memcached-1.5.13/doc'
 make  install-am
 make[3]: Entering directory `/path/to/home/memcached-1.5.13/doc'
 make[4]: Entering directory `/path/to/home/memcached-1.5.13/doc'
 make[4]: Nothing to be done for `install-exec-am'.
  /usr/bin/mkdir -p '/path/to/home/local_includes/share/man/man1'
  /usr/bin/install -c -m 644 memcached.1 '/path/to/home/local_includes/share/man/man1'
 make[4]: Leaving directory `/path/to/home/memcached-1.5.13/doc'
 make[3]: Leaving directory `/path/to/home/memcached-1.5.13/doc'
 make[2]: Leaving directory `/path/to/home/memcached-1.5.13/doc'
 make[2]: Entering directory `/path/to/home/memcached-1.5.13'
 make[3]: Entering directory `/path/to/home/memcached-1.5.13'
  /usr/bin/mkdir -p '/path/to/home/local_includes/bin'
   /usr/bin/install -c memcached '/path/to/home/local_includes/bin'
  /usr/bin/mkdir -p '/path/to/home/local_includes/include/memcached'
  /usr/bin/install -c -m 644 protocol_binary.h '/path/to/home/local_includes/include/memcached'
 make[3]: Leaving directory `/path/to/home/memcached-1.5.13'
 make[2]: Leaving directory `/path/to/home/memcached-1.5.13'
 make[1]: Leaving directory `/path/to/home/memcached-1.5.13'

when I run ps ax | grep memcached however no trace of the program being installed is apparent.


I also tried reinstalling and change the make install instruction to:

make install --prefix=PREFIX

and

make install --prefix=/path/to/home/local_lib


though neither of them were registered as acceptable arguments (though the INSTALL instructions seemed to indicate they would be).

If anyone has any ideas I would appreciate them. Thanks.


Solution

You built the binary but have not started it.

Try starting it via: sudo service memcached restart

If that doesn't work, then run this: sudo /etc/init.d/memcached restart



Answered By - sturdynut
Answer Checked By - Cary Denson (PHPFixing Admin)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing