Wednesday, 10 September 2014

Installing Trac on Ubuntu

We've successfully installed SVN on our Ubuntu LAMP server so far, now its time for trac.

At the terminal prompt, type the following to get root access:


  • sudo su
Pre-requisites for installing Trac are that a Lamp server be already setup and SVN be installed along side it.

Install the following components by issuing the following command at the prompt:


  • apt-get install libapache2-mod-python python-setuptools  python-subversion
Go here: http://trac.edgewall.org/wiki/TracDownload   and copy either the HTTP or FTP link of the latest stable release and past it in front of the following command:

  • easy_install http://ftp.edgewall.com/pub/trac/Trac-xxx.tar

issue the following commands at prompt next:


  • cd /
  • mkdir /trac


Tuesday, 28 September 2010

Monday, 27 September 2010

Installing subversion on Ubuntu 10.04 Lamp server

This post is going to outline the steps i took to successfully install subversion on my LAMP server

First you need to add a new group call subversion, to do so you need to first enable viewing all users, to do this press ALT + F2. A run window would pop just like windows run command prompt, enter the following

  • gconf-editor
Now navigate to /apps/gnome-system-tools/users and click showall and close the window.


Go into System> Administration > Users and Groups and add a new group called subversion, add yourself and the user www-data to it. Press OK to save changes and close the window once done.

Fire up your terminal window and type sudo su admin rights


navigate to the root directory by

  • cd /
Then type:

  • mkdir /svn
  • cd /svn
  • mkdir /tester
Create an SVN repository by typing the following:

  • svnadmin create /svn/tester
Then type the following to correct the permissions:

  • chown -R www-data:subversion tester
  • chmod -R g+rws tester
To access the svn repository via your browser you have to tell apache where it is located. Firstly you have to install a package do so by typing the following:

  • apt-get install libapache2-svn

Now you will have to edit the dav_svn.conf file to tell it where the repositories are located, i like to have all the repositories listed when i type http://localhost/svn. To do so type the following at the terminal prompt:

  • gedit /etc/apache2/mods-available/dav_svn.conf

Once the text editor opens, type the following,


<Location /svn>
     DAV svn
     SVNParentPath /svn
     SVNListParentPath On
     AuthType Basic
     AuthName "Subversion Repository"
     AuthUserFile /etc/subversion/passwd
     <LimitExcept GET PROPFIND OPTIONS REPORT>
        Require valid-user
     </LimitExcept>
  </Location>

and hit save, close the editor.

Restart apache now by typing the following at the terminal prompt:

  • /etc/init.d/apache2 restart
Now that you have SVN setup you will have to create a password file for authentication, a -c delimiter will be used to create the file and then all other users will be added without the -c

  • htpasswd -c /etc/subversion/passwd user_name
It will prompt you for a password and then to confirm the password.

To add more users simply type the following at the terminal prompt:

  • htpasswd /etc/subversion/passwd Second_user_name


You should now be able to access your svn repository by pointing your browser to

  • http://localhost/svn
Happy Developing

--Eddy

Ubuntu 10.04 with LAMP server

Let me first explain a little bit about what i'm going to do and why i need to do it. My company requires a stable and secure development environment from which the product, which is all the applications and code cannot be carried out of the office with the employees. For this purpose i proposed a local LAMP server, running SVN and Trac ( to be discussed later).

The reason for this blog is to document my attempts at different installations and tasks in Ubuntu, as well as fixes which have been taken from a lot of different sources because one just doesn't work. Hopefully this blog will help you with your problems.

For this purpose i chose Ubuntu because of all the support that comes with it, you could choose any other distribution of your choice. I tried working on Centos, but it almost drove me mad.

First things first, grab a fresh distribution of Ubuntu from www.Ubuntu.com . I chose the Desktop version because of the Graphical User Interface that comes with it, coming from a life of using Windows from the word go, a nice GUI is always welcome to fiddle around when things arent going your way.

once you've installed Ubuntu login with the account you created during the installation and fire up the terminal. You should find it under Application > Accessories.

Type: 
  • sudo su
at the prompt and it will ask you to type in the root password. Do that and you have admin rights and wont have to type sudo with every command.

To install LAMP (Linux Apache Mysql PHP) simply type at the terminal prompt:
  •  sudo tasksel install lamp-server
This should bring up a blue screen and start downloading packages, it will ask you to enter a password for mysql half way through, enter something you can remember later on as well.

Once the installation has completed, type the following in the address bar of your browser
  • http://localhost  OR http://127.0.0.1   
 You should see a page saying IT WORKS! if you do then you've successfully installed Apache, if not then browse around and should be able to find something that works for you.

At this point you need to install a front end to manage Mysql, a good one is PHPMYADMIN

To install phpmyadmin simply type the following at the terminal prompt:
  •  apt-get install phpmyadmin
During the installation it will ask you to enter 2 passwords, the first is the one you gave while install MySql and the second one is to access the front end of phpmysql. Once the installation is complete, point your browser to

  •  http://localhost/phpmyadmin OR http://127.0.0.1/phpmyadmin
 Enter the password you gave while installing phpmyadmin and you should now have access to phpmyadmin to manage all your databases. 
Alright, so its been a couple of days since i last updated the blog.

This is the story about how i crashed our dedicated server taking down all our client websites along with it.

We run two separate servers, one for development and testing and the other for deployment. The development and testing server isn't stable and has very poor backup options. So we thought we'd create a separate account for testing. So i began fidgeting with the server installing Subversion and Trac. While installing Trac i made an extremely noob mistake, something i should have taken precautions while doing, but didn't. I ran a Perl install command from the root account instead of the client account.

I was already playing with the httpd apache file and so after running the install command when i rebooted, all hell broke loose and apache simply refused to start. This is when i started to panic, if it was the test server the downtime wouldnt have mattered all that much, but considering the fact that it was our deployment server and alot of projects were serving content on the internet was a big problem.

I quickly called up the support of our hosting company and raised a ticket along with it. Thankfully the support team restored the last working copy of the apache httpd file and peace was restored.

Firstly, i cant emphasize enough how important it is if you are running a deployment server that you have good support. We host our server with Liquid Web and kudos to them for the prompt response.

--Eddy

Thursday, 16 September 2010

About this blog

Please dont be taken in by the absolute meaning of the domain, it doesn't mean what it says.

Linux 'Woes' refers to all the hard times my distro has and will give me at my attempt to try and learn and master it to whatever extent i can.

Coming from a Window life, things are quite difficult by i have to appreciate all the Ubuntu community has done to help me out by just being their with their help.

My first woe should be up in a couple of hours where i took our production server down 'accidentally', leading to mass panic and chaos with client rants on the fly.

--Eddy