1

I am usually a Windows user, but I have decided to check out Django, and was recommended doing this on a Linux box.

I downloaded the Django-1.2.5.tar.gz, and by default it ended in the tmp folder. Should I unzip it here, or should it be moved to another folder first? Is this relevant to where it will end up once I install it?

I unpacked it in the tmp-folder, moved into the new folder and ran the installation procedure. Things seems to be in order, but I have no idea where everything went. Is Django now installed in the tmp folder, or is it automatically placed somewhere magic in this cryptic (from a Windows-user mindset) file-system?

I really like Ubuntu so far, so I hope to gain more understanding

1
  • Cryptic? Unix file systems are less cryptic than a bunch of drive letters and \\unc\paths :) Fuller answer coming...
    – Spacedman
    Mar 4, 2011 at 10:28

3 Answers 3

1

Firstly, /tmp should be considered temporary - anything in there might be deleted on reboot or before.

So its an okay place to download installation tarballs.

Normally when you do something called 'install' on a Linux box it means it gets put into the system permanently, into the recognised system directories such as /bin, /usr/local/, and so on. For python packages like Django, you might find its now in a 'site-packages' directory under /usr/lib/python2.5 or similar.

Now, that only applies if you run the install as 'root', the superuser. Normal users can't write to system directories.

Also... you can often run things without having to install them. You just do a 'build' and then run from the directory where the source files are (usually the directory where you extracted the tarball). The usual way of working can be to do the build as an ordinary user, and once you successfully do that, become 'root' and do the final install step so the package is available to everyone, permanently, in the system directories.

Hope that helps...

3
  • So the system handles the location of the software itself? No need to specify folders etc?
    – erikric
    Mar 4, 2011 at 11:15
  • 1
    No, the software itself decides where it will install to. It'll be in the documentation. I strongly recommend you do NOT install random packages though and instead heed the advice in my answer. Django is already in the Ubuntu repositories, built, packaged and read to go.
    – Pricey
    Mar 4, 2011 at 11:33
  • 2
    Agreed, try the repositories first, but one day (and always sooner then you think) you'll reach the point of 'you need the latest development version of XXX to use YYY'. The days of installing an entire system from source are not yet gone :)
    – Spacedman
    Mar 4, 2011 at 11:45
2

Check out https://help.ubuntu.com/community/InstallingSoftware for information on how we install software on Ubuntu. Its a completely different mindset to Windows, you should never really download and install software from random websites. Thousands upon thousands of different packages are already available, prebuilt and tested! You really want to avoid compiling from source whenever possible. If you do, you'll need to read the documentation thoroughly which will explain where everything will be installed to.]

For your specific case, I reckon you're after the 'python-django' package? (I searched for django on http://packages.ubuntu.com/search?keywords=django&searchon=names&suite=maverick&section=all and that seems right.)

Click on my first link for all the different options on how to install that package, or just type:

sudo apt-get install python-django

into a terminal window.

-1

sudo apt-get install python-django is working in Ubuntu 13.04

After installing python or update the packages by using,

sudo apt-get update

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .