# Nginx apt-get vs. from source

**URL:** <https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816>\
**Category:** Deployment\
**Created:** [August 11, 2007, 2:34pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816 "2007-08-11T14:34:35Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 2:34pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/1 "2007-08-11T14:34:35Z")

</div>

hi!

I need to install nginx on Ubuntu 6.06. I don’t know what’s better… to  
build it from source as described on nginx site or with apt-get.

I’m asking because when I installed Ruby with apt-get I got version 1.84  
and then had to remove it and build from source…

What would you recommend for nginx? My biggest concerns are:

- will I get the latest version
- will “apt-get upgrade” work with it
- will everything work without problems (I mean is installing from  
source better in any other way?)

thank you!

david

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 4:29pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/2 "2007-08-11T16:29:55Z")

</div>

In general, you should always go with the package unless you need a more  
recent version for some reason. Using the version that’s packaged for  
your  
distribution means that it will upgrade automatically (including  
security  
updates), you’ll be sure it’s using the right version of shared  
libraries,  
and it’s much easier to install and remove.

The version of nginx in ubuntu feisty is 0.4.13 (  
[Ubuntu – Error](http://packages.ubuntu.com/feisty/web/nginx) ) and the most recent  
version of  
nginx is 0.5.30. If 0.4.13 is good enough for you then I’d use that.  
Check  
the changelog ( [http://nginx.net/CHANGES-0.5](http://nginx.net/CHANGES-0.5) )

BTW, I’d recommend using aptitude instead of apt-get, it handles  
dependencies better.

Paul

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 8:30pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/3 "2007-08-11T20:30:21Z")

</div>

Hi,

There is no nginx package for 6.06, afaik (at least not in main,  
universe, or multiverse). I have just set up a fresh 6.06 system, and  
I downloaded the 0.5.30 (latest) nginx source, and built with the  
standard ‘./configure && make’ - then ‘sudo make install’. No  
problems, and works fine for me. You will need ‘sudo aptitude install  
build-essential’ first, though, to get gcc and related build  
utilities.

Tony

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 9:02pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/4 "2007-08-11T21:02:25Z")

</div>

yes, that’s what I was going to do (and probably will).

I want to understand Ubuntu’s package manager philosophy though.

So say that there was a possibility to install nginx to 6.06 via  
aptitude, how would they decide when the new version is ready so that  
users can reach it via upgrade. And especially why is there a lag  
between version in a package and the newest one.

thank you,  
david

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 6:12pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/5 "2007-08-11T18:12:35Z")

</div>

Paul, thank you very much

0.5.30 seems pretty old in comparison to 0.4.13 (not that I know a lot  
about the differences, only judging from the version number)…  
but if I do decide to go with aptitude / apt-get, will 0.4.13 then get  
upgraded by aptitude to the next version? what’s the philosophy there…  
is there always a few months lag between latest and supported version?

and because this is not the latest version of ubuntu, does that matter?  
6.06 is LTS (long-term support) however…

thank you in advance!

PS: I also didn’t know it’s better to use aptitude versus apt-get …  
thank you for that tip as well.

David

Paul D. wrote:

> In general, you should always go with the package unless you need a more  
> recent version for some reason. Using the version that’s packaged for  
> your  
> distribution means that it will upgrade automatically (including  
> security  
> updates), you’ll be sure it’s using the right version of shared  
> libraries,  
> and it’s much easier to install and remove.
> 
> The version of nginx in ubuntu feisty is 0.4.13 (  
> [Ubuntu – Error](http://packages.ubuntu.com/feisty/web/nginx) ) and the most recent  
> version of  
> nginx is 0.5.30. If 0.4.13 is good enough for you then I’d use that.  
> Check  
> the changelog ( [http://nginx.net/CHANGES-0.5](http://nginx.net/CHANGES-0.5) )
> 
> BTW, I’d recommend using aptitude instead of apt-get, it handles  
> dependencies better.
> 
> Paul

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 9:22pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/6 "2007-08-11T21:22:30Z")

</div>

ok - my general philosophy is to stick with the distro packages  
wherever possible - in that way you are sure that the interlocking  
mesh of dependencies is (hopefully!) handled correctly, and where  
there are major bugs or security issues, then the package is updated  
throught the ‘sudo aptitude update’ mechanism. For your source  
compiled stuff, you are responsible for keeping it up to date and  
secure - which can be a major headache if you have several programs  
built from source to maintain.

The downside to using the distro packages is that you may not have  
that ‘latest, greatest’ feature you _must_ have.

Distro packages for a particular distro version (eg. 6.06) will not  
usually be ‘upgraded’ to a later version - for that, you usually need  
to upgrade the whole distro to the newer version.

I you are looking for stability and security, stick with 6.06 - or if  
you want to be on the edge, then upgrade to the latest (7.04 ‘feisty’)

I use 6.06 for servers, and have 7.04 on the desktop.

The lag between versions is due to when the distro package list for a  
new distro version is locked down prior to release. Any upstream  
releases after that date would then only make it into the next distro  
version.

hth, Tony

On 11/08/07, D. Krmpotic [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> ## thank you, david
> 
> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).
> 
> >

–  
Tony White  
Speechnet Technologies Ltd

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 9:22pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/7 "2007-08-11T21:22:30Z")

</div>

On 8/11/07, D. Krmpotic [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> I want to understand Ubuntu’s package manager philosophy though.

LTS in 6.0.6 LTS stands for Long Term Support. Ubuntu committed to  
support this version until year 2011 (which isn’t really long at all,  
considering how many computer systems built in 1970s are still in  
production).

The release policy for versions like that is “stability tramps  
coolness”. So, the distro maintainers will generally provide bugfixes  
and security patches, but won’t upgrade to anything that creates a  
risk of incompatibility with apps people are already running.

Which is why RedHat EL 4 is still on Ruby 1.8.1, and Ubuntu 6 on 1.8.4.

–  
Alex Verkhovsky

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 9:41pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/8 "2007-08-11T21:41:23Z")

</div>

ok, now the only problem is that 6.06 doesn’t have NGINX at all…

I guess the only option here is to build from source, right?

I also would like to know if there will be nginx installable via  
aptitude for 6.06 at all?

thank you

Alexey V. wrote:

> On 8/11/07, D. Krmpotic [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:
> 
> > I want to understand Ubuntu’s package manager philosophy though.
> 
> LTS in 6.0.6 LTS stands for Long Term Support. Ubuntu committed to  
> support this version until year 2011 (which isn’t really long at all,  
> considering how many computer systems built in 1970s are still in  
> production).
> 
> The release policy for versions like that is “stability tramps  
> coolness”. So, the distro maintainers will generally provide bugfixes  
> and security patches, but won’t upgrade to anything that creates a  
> risk of incompatibility with apps people are already running.
> 
> Which is why RedHat EL 4 is still on Ruby 1.8.1, and Ubuntu 6 on 1.8.4.
> 
> –  
> Alex Verkhovsky

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 10:11pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/9 "2007-08-11T22:11:41Z")

</div>

ok, I’ll just compile it myself… problem solved.

thank you  
david

Alexey V. wrote:

> On 8/11/07, D. Krmpotic [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:
> 
> > I also would like to know if there will be nginx installable via  
> > aptitude for 6.06 at all?
> 
> From official distro packages - probably not.
> 
> There is a possibility of adding Nginx packages to RubyWorks stack  
> (which is an APT and RPM repository). At least, we are thinking about  
> it.
> 
> –  
> Alex Verkhovsky

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 12, 2007, 12:55am UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/10 "2007-08-12T00:55:51Z")

</div>

So I did install it… everything seemed to go through fine, but I  
decided to check for file /etc/init.d/nginx (a few sites mention it)…  
and I found out that this file doesn’t exist. Is this something to worry  
about or it’s normal somehow? I want to be sure about that before trying  
to go further. Thank you!david

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 12, 2007, 1:13am UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/11 "2007-08-12T01:13:22Z")

</div>

ok, I guess this is the answer:

wget [http://notrocketsurgery.com/files/nginx](http://notrocketsurgery.com/files/nginx) -O /etc/init.d/nginx  
sudo chmod +x /etc/init.d/nginx  
sudo update-rc.d nginx defaults

(or you can get it from [http://www.romej.com/downloads/nginx.txt](http://www.romej.com/downloads/nginx.txt) –  
not sure if there is any significant difference)

David

D. Krmpotic wrote:

> So I did install it… everything seemed to go through fine, but I  
> decided to check for file /etc/init.d/nginx (a few sites mention it)…  
> and I found out that this file doesn’t exist. Is this something to worry  
> about or it’s normal somehow? I want to be sure about that before trying  
> to go further. Thank you!david

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 12, 2007, 3:01am UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/12 "2007-08-12T03:01:52Z")

</div>

I package nginx for Fedora and have written an init script for it. The  
most  
recent version can always be found in fedora CVS. Anyone is welcome to  
it.

[http://cvs.fedora.redhat.com/viewcvs/rpms/nginx/devel/nginx.init](http://cvs.fedora.redhat.com/viewcvs/rpms/nginx/devel/nginx.init)

enjoy,

-jeremy

---

<div class="post-metadata">

**Author:** ![dxk3355](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/d6d6ee/32.png) [@dxk3355](https://www.ruby-forum.com/u/dxk3355)\
**Post date:** [August 11, 2007, 9:57pm UTC](https://www.ruby-forum.com/t/nginx-apt-get-vs-from-source/111816/13 "2007-08-11T21:57:32Z")

</div>

On 8/11/07, D. Krmpotic [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> I also would like to know if there will be nginx installable via  
> aptitude for 6.06 at all?

From official distro packages - probably not.

There is a possibility of adding Nginx packages to RubyWorks stack  
(which is an APT and RPM repository). At least, we are thinking about  
it.

–  
Alex Verkhovsky
