Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I want to install this module.

The problem is it requires that nginx is installed from source. I have it installed via apt-get install, and it is already serving web pages.

So which steps would you follow to change from one to the other? If possible I would like them to use the same paths. In the example it uses /opt, but apt-get installed it in a different place (I see entries in /etc, /lib, /usr/bin, /usr/share).

share|improve this question

1 Answer 1

up vote 1 down vote accepted

The basic procedure is to remove the installed version, and then install the new one:

    sudo apt-get purge nginx

Now, download the source tar ball of what you want to install and extract it:

    wget http://nginx.org/download/nginx-1.3.11.tar.gz
    tar xvvzf nginx-1.3.11.tar.gz 

The files you see in /etc and /lib are settings and service scripts and the like. They will be there no matter where you install nginx, apt installs nginx to /usr.

So, tell the included configure script to install in /usr:

cd nginx-1.3.11/
./configure --prefix=/usr

Then compile and install:

make
sudo make install
share|improve this answer
    
Thank you so much! –  ChocoDeveloper Feb 2 '13 at 3:13

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.