1. The system has installed GCC, make, libtool and other tools
2, yum installation of ICU, Libcul
Yum install libicu-devel-y
yum install curl-devl-y
3, compile and install Erlang, SpiderMonkey JS Engine, CouchDB
Installing Erlang
You need to configure the Java compilation environment before installing Erlang, and other FOP (FAKEFOP), wxwidgets hints do not exist to ignore. It is recommended that you compile with Javac
Setting the environment variables for Erlang in the/etc/profile file
#Erlang Environment
Export Erl_home=/usr/local/erlang
Export Path=${erl_home}/bin:${path}
Enter Erl, a command prompt appears >
Install SpiderMonkey JS Engine
Create an installation script
#vim Inst
#!/bin/bash
if test "$USER" = root; then
wget http://ftp.mozilla.org/pub/mozilla.org/js/js-1.7.0.tar.gz-o-| Tar xvz
cd js/src
make-f makefile.ref
mkdir-p/usr/include/smjs/-v
CP *.{ H,TBL}/usr/include/smjs/
-v CD linux_all_dbg. OBJ
CP *.h/usr/include/smjs/-v
mkdir-p/usr/local/{bin,lib}/-v
CP js/usr/local/bin/
-V CP libjs.so/usr/local/lib/
-v Else
echo "You must is root." Try sudo $ "
fi
Increases execution permissions: chmod u+x./inst
Perform the installation:./inst
Input JS, you can see the command prompt of JS >
Install Couchdb
./configure failed
Error tip: Configure:error:Could not find the JSAPI header. The error hint is obvious, can not find the JS related header file.
--with-js-include configuration options are available in/configure--help.
Use this option:
#./configure--prefix=/usr/local/couchdb--with-js-include=/usr/include/smjs
Configuration succeeded
#make
#make Install
#useradd couchdb
#chown-R couchdb/usr/local/couchdb/var/
#cp/usr/local/couchdb/etc/rc.d/couchdb/etc/ Init.d/couchdb
Change the bind_address=127.0.0.1 in the Couchdb/etc/couch/default.ini file to 192.168.3.199 (host IP), which is accessible to other machines.
COUCHDB installation environment is more attached, where Erlang and SpiderMonkey installation is prone to various problems, requiring patience.
Reference:
"1" http://www.ibm.com/developerworks/cn/opensource/os-cn-couchdb/
"2" http://blog.csdn.net/bbiao/article/details/5021032