Setup Subversion and Trac on CentOS 5

Recently I set up a virtual server to use as a development machine. It runs on CentOS 5 and hosts several Subversion repositories with associated Trac projects.

There are many guides and plenty of help on the net to help you setup such a system. However, when I tried to do it I came across a few problems and I hope this post may help at least a few people trying to do the same as me. I am not going to rewrite the great tutorials out there, I will just point you to them and note what things I did differently.

This ‘guide’ should get you from a fresh install of CentOS 5 linux to one or more working Subversion (SVN) repositories and associated Trac wiki’s. Apache/WebDAV is used as the network layer. I have only tested this on a fresh install of CentOS 5.

The Environment

I am aiming for the following:

  • CentOS 5, SVN installed. Apache2 as the network layer using mod_dav_svn.
  • Trac running on Apache with mod_python
  • SVN repositories located at: /srv/svn (e.g. /srv/svn/my-project), accessible via http://server/svn/my-project
  • Trac projects located at: /srv/trac (e.g /srv/trac/my-project) accessible via http://server/trac/my-project

How I did it

Not all the steps are vital (probably) but this is how I got it working. Feel free to skip any non-relevant steps (i.e. there is probably no need for a fresh install). Replace any occurence of <project> with the name of your first project.

1. Fresh install of CentOS. I followed most of the Perfect Setup Guide, except the mail and ISPConfig stuff. The important part is setting up the Apache2 web server.

2. Make sure SVN and mod_dav_svn are installed. As root:

yum install subversion mod_dav_svn
vim /etc/httpd/conf/httpd.conf

If the following two lines are not present, add them:

LoadModule dav_svn_module modules/mod_dav_svn.so
LoadModule authz_svn_module modules/mod_authz_svn.so

3. Install Trac: Follow Nick’s guide with the alternative Clearsilver installation below. Skip the Apache Configuration part.

Follow all of parts 1 and 2. Instead of part 3 do:

wget http://dag.wieers.com/rpm/packages/clearsilver/clearsilver-0.10.4-1.el5.rf.i386.rpm
rpm -i clearsilver-0.10.4-1.el5.rf.i386.rpm
wget http://dag.wieers.com/rpm/packages/clearsilver/python-clearsilver-0.10.4-1.el5.rf.i386.rpm
rpm -i python-clearsilver-0.10.4-1.el5.rf.i386.rpm

Continue with parts 4.1 and 4.2 of Nick’s guide. Remember, leave out Apache configuration section.

4. Create your first SVN Repository:

svnadmin create --fs-type fsfs /srv/svn/<project>

5. Initialise a Trac project for your new repository:

trac-admin /srv/trac/<project> initenv

For the trac-admin command use the defaults if not sure, giving a descriptive name for the project. The `Path to repository` is: /srv/svn/<project>.

6. Set the correct file permissions for apache

chown -R apache.apache /srv/svn/<project>
chown -R apache.apache /srv/trac/<project>

7. Tell apache where to find the new repository. Here we create an additional Apache configuration file specifically for the SVN repositories.

vim /etc/httpd/conf.d/subversion.conf

Add the following directive:

<Location /svn/<project>>
	DAV svn
	SVNPath /srv/svn/<project>
	AuthType Basic
	AuthName "<project> Repository"
	AuthzSVNAccessFile /srv/svn/svn-acl-conf
	AuthUserFile /srv/svn/<project>.htpasswd
	Require valid-user

8. Add a repository user:

touch /srv/svn/<project>.htpasswd
htpasswd -m /srv/svn/<project>.htpasswd <username>

9. Create the Access Control List for the SVN Repository

vim /srv/svn/svn-acl-conf

Add the following directives:

<username> =  rw

Where <username> represents the username of the repository user you created earlier.

10. Tell apache where to find the new Trac project. Here we create an additional Apache configuration file specifically for the Trac projects.

vim /etc/httpd/conf.d/trac.conf

Add the following directives:

<Location /trac/<project>>
	SetHandler mod_python
	PythonHandler trac.web.modpython_frontend
	PythonOption TracEnv /srv/trac/<project>
	PythonOption TracUriRoot /trac/<project>

<Location "/trac/<project>/login">
	AuthType Basic
	AuthName "trac"
	AuthUserFile /srv/trac/<project>.htpasswd
	Require valid-user

11. Add a Trac user:

touch /srv/trac/<project>.htpasswd
htpasswd -m /srv/trac/<project>.htpasswd <username>

12. Give admin permissions to the Trac user you just created:

trac-admin /srv/trac/<project> permission add <username> TRAC_ADMIN

Where <username> represents the username of the Trac user you just created.

13. Restart Apache:

service httpd restart

You should now have SVN and Trac installed. You will have an SVN repository setup (http://server/svn/<project>) and the Trac wiki (http://server/trac/<project>) associated with the repository.

Please let me know if this helped you. If you come across any problems I will be happy to try and help.


The last part of CentOS HowTos: Subversion will give you a quick introduction on how to use SVN.

Subversion setup guides: here and here

Trac setup guides: here and here.

ClearSilver template system (used by Trac).

Setting up CentOS 5.0

  • beds

    Thanks a lot, just tried this out, left out the trac install, worked first time.

  • http://www.pcbender.com PCBender

    Great howto. Thanks. One small change on your item 4…

    svnadmin create -fs-type fsfs /srv/svn/

    should be:

    svnadmin create –fs-type fsfs /srv/svn/

    Note the double dash in front of fs-type.



  • Daniel

    I’m glad it helped you out.

    Thanks for reporting the error, I will fix it right away.

  • Daniel

    This saved me a lot of work. Big Thanks!

    Additionally to the steps above I had to add

    LoadModule dav_svn_module modules/mod_dav_svn.so
    LoadModule authz_svn_module modules/mod_authz_svn.so

    to my /etc/httpd/conf/httpd.conf

    otherwise I got
    Unknown DAV provider: svn

  • daniel

    One more thing (just in case anyone else is running into this)
    I had to disable SELinux otherwise modpython couldn’t access /srv/trac//VERSION

  • Daniel Skinner

    Glad it helped you out. Thanks for the feedback, I will add that to the guide shortly.

  • Mike

    When you yum install mod_dav_svn, you get /etc/httpd/conf.d/subversion.conf, so you don’t really need to make any subversion changes to httpd.conf. Edit /etc/httpd/conf.d/subversion.conf instead.

  • http://www.sailboatvn.co.uk sailboatvn

    Thanks Daniel for posting this guide.
    I tried to follow this tutorial (but skipped the Trac steps) and just came up some problem on my Centos 5 (latest one)

    1. I added these lines

    LoadModule dav_svn_module modules/mod_dav_svn.so
    LoadModule authz_svn_module modules/mod_authz_svn.so

    the apache did not start until I added an other line:
    LoadModule dav_module modules/mod_dav.so

    2. Everything seem work fine, I can see the successful message as below when type http://localhost/svn

    Revision 0: /

    Powered by Subversion version 1.4.2 (r22196).

    the problem is that i could not able to create, edit or commit the file to repository.

    Here is the error message:

    Can’t create directory ‘/subversion/svn/db/transactions/0-1.txn’: Permission denied.

    Anyone have idea why this happended?


  • Daniel Skinner

    Can you create, edit or commit from a command line?

    If you can then you might need to ensure the user which apache is running as has permission to write to the files.

    On my version apache is the user, so I would try something like:

    chown -R apache.apache /subversion/svn/

    Let me know it that works!

  • http://www.sailboatvn.co.uk Sailboatvn

    Hi Daniel,

    Thanks for your reply.

    1. I could not create, edit or commit from command line at all.

    2. Not sure which version apache is for user or root, but all the steps (your guides) above were done under ROOT account

    I typed this command line

    # httpd -version

    and got this respond

    Server version: Apache/2.2.3
    Server built: Nov 10 2007 12:44:14

    3. I did try your suggestion

    chown -R apache.apache /subversion/svn/

    and also

    chown -R apache.apache /subversion

    but the same error message came back still.

    I’m quite stumped 🙁

    Please let me know if you have any other thoughts.



  • Pingback: Installing Trac on CentOS 5 « Compulsivo, Inc.()

  • Daniel Skinner



    cd /subversion/svn/
    ls -la

    Do the permissions look reasonable?

    If not, try doing a temporary hack: chmod -R 777 to see if that fixes the issue – if it does don’t leave it like that but at least we have identified it’s file/ownership permissions that is problematic.

  • http://www.sailboatvn.co.uk Dave Bui

    Hi Daniel,

    Thanks very much for helps. The problem was came from SELinux, it actually blocked users from accessing to httpd service.. Phew.. here is the error message from Setroubleshoot

    SELinux prevented /usr/sbin/httpd from writing 10-1.txn.Detailed DescriptionSELinux prevented /usr/sbin/httpd from writing 10-1.txn.

    If 10-1.txn is a core file, you may want to allow this. If 10-1.txn is not a core file, this could signal a intrusion attempt.

    Allowing Access

    Changing the “allow_daemons_dump_core” boolean to true will allow this access: “setsebool -P allow_daemons_dump_core=1.”

    The following command will allow this access:

    setsebool -P allow_daemons_dump_core=1

    Please note that the suggestion does not work at all. I disable SELinux by editting /etc/selinux/config and change the SELINUX line to SELINUX=permissive:

    Cheers mate.

  • Pete

    I also thought I did fairly well. Everything seemed to install and restart, but I get this error

    ClearSilver not installed (No module named neo_cgi)

    when I browse to my trac url. However, if I go back and revisit the clearsilver rpm instructions, I’m told clearsilver IS already installed. Any ideas?

  • Daniel Skinner

    Try re-installing the python bindings:

    wget http://dag.wieers.com/rpm/packages/ clearsilver/python-clearsilver-0.10.4-1.el5.rf.i386.rpm
    rpm -i python-clearsilver-0.10.4-1.el5.rf.i386.rpm

  • Pete

    Thanks Daniel that did the trick; we are now on Trac 😉

  • Pingback: Install phpUnderControl on CentOS 5 | Daniel Skinner: News and Articles on Web Development()

  • http://www.trickylinux.com Steven Russo

    Hey awesome blog! Know anyone who would be interested in part time admin’ing a Linux box? Hit me up!

  • http://emilientaque.fr Emilien

    Does this guide remain valid in case of virtual hosts configuration ?


  • Daniel Skinner

    Hi Emilien,

    Yes, this guide will apply to a VHost setup.

    You should be able to simply replace the Location directives with VirtualHost directives. The content of the directive remains the same with the addition of the servername and serveralias directives of course.

    For the trac login you may want to place the location directive within the trac virtualhost if that is how you would like things setting up.

    Let me know how it goes.


  • http://emilientaque.fr Emilien

    Yeah, it works well !
    Thank you Daniel.


  • Ian


    I’ve gotten Trac and subversion installed, however i’m using Trac 11.1 and i’m getting a lot of python tracebacks in my httpd error logs:

    PythonHandler trac.web.modpython_frontend: File “/usr/lib/python2.4/site-packages/Trac-0.11.1-py2.4.egg/trac/web/main.py”, line 381, in dispatch_requestn env = open_environment(env_path, use_cache=not run_once)

    PythonHandler trac.web.modpython_frontend: File “/usr/lib/python2.4/site-packages/Trac-0.11.1-py2.4.egg/trac/env.py”, line 567, in open_environmentn env = env_cache.setdefault(env_path, open_environment(env_path))

    PythonHandler trac.web.modpython_frontend: File “/usr/lib/python2.4/site-packages/Trac-0.11.1-py2.4.egg/trac/env.py”, line 571, in open_environmentn env = Environment(env_path)

    PythonHandler trac.web.modpython_frontend: File “/usr/lib/python2.4/site-packages/Trac-0.11.1-py2.4.egg/trac/env.py”, line 185, in __init__n load_components(self, plugins_dir and (plugins_dir,))

    PythonHandler trac.web.modpython_frontend: File “/usr/lib/python2.4/site-packages/Trac-0.11.1-py2.4.egg/trac/loader.py”, line 109, in load_componentsn loadfunc(env, search_path, auto_enable=plugins_dir)

    PythonHandler trac.web.modpython_frontend: File “/usr/lib/python2.4/site-packages/Trac-0.11.1-py2.4.egg/trac/loader.py”, line 39, in _load_eggsn distributions, errors = working_set.find_plugins(

    PythonHandler trac.web.modpython_frontend: File “/usr/lib/python2.4/site-packages/pkg_resources.py”, line 640, in __init__n self.scan(search_path)

    PythonHandler trac.web.modpython_frontend: File “/usr/lib/python2.4/site-packages/pkg_resources.py”, line 669, in scann for dist in find_distributions(item):

    PythonHandler trac.web.modpython_frontend: File “/usr/lib/python2.4/site-packages/pkg_resources.py”, line 1577, in find_on_pathn for entry in os.listdir(path_item):

    PythonHandler trac.web.modpython_frontend: OSError: [Errno 13] Permission denied: ‘/srv/trac/test/plugins’

    Any light you can shed on this?

    Much appreciated!


  • Ian

    Upon further analysis, SELinux on CentOS5 was the culprit…

  • http://www.wcnconsultancy.co.uk Daniel Skinner

    That’s nearly always the problem! I would be interested in knowing how to get it working with SELinux in enforcing mode – This is something I will look into.

  • Ian

    It’s really very simple… I had to beat my head on my desk before i realized how simple it was, but it’s simple, heh.

    From root’s home directory (i use this path, because doing this poops a few files out, and it really doesn’t matter where you do it from) SELinux must be running for this to work.

    grep -i ‘Trac’ /var/log/audit/audit.log |audit2allow -M trac

    This will create a file called trac.pp, and another called trac.te.

    Then, to import it into the kernel:

    semodule -i trac.pp

    That’s it. You’re done.


    audit2allow allows you to create a policy based on the AVC in the audit.log file that SELinux generates. You find the lines that show that the service ‘trac’ has been blocked, and audit2allow uses them to create a policy package (.pp file).

    Once you’re done, load the .pp file by using the semodule command.

  • Ian


    And there’s a way to avoid having to do this with subversion as well… If you put your respository in /var/www, you don’t have to worry about setting up an SELinux policy.

    This trick doesn’t work with Trac, you still have to create a policy. I think because python is accessing files.

  • http://www.wcnconsultancy.co.uk Daniel Skinner

    Excellent – Thanks for the explanation.

  • Ian

    My pleasure, excellent tutorial!

  • Pingback: Installing Trac on CentOS 5 | Compulsivo()

  • Maksim

    Thanks you huge, all work, a manual simply fairy tale. It was taken with others in the sum about 5 hours, now all has earned from the first attempt. Thanks.

  • Adrian


    SVN and Trac commands work fine, but when I try to going to the url on the browser I get a 500 error. The error log reports:

    [Wed Nov 19 22:40:03 2008] [error] [client] PythonHandler trac.web.modpython_frontend: Traceback (most recent call last):
    [Wed Nov 19 22:40:03 2008] [error] [client] PythonHandler trac.web.modpython_frontend: File “/usr/lib64/python2.4/site-packages/mod_python/apache.py”, line 287, in HandlerDispatchn log=debug)
    [Wed Nov 19 22:40:03 2008] [error] [client] PythonHandler trac.web.modpython_frontend: File “/usr/lib64/python2.4/site-packages/mod_python/apache.py”, line 464, in import_modulen module = imp.load_module(mname, f, p, d)
    [Wed Nov 19 22:40:03 2008] [error] [client] PythonHandler trac.web.modpython_frontend: File “/usr/local/lib/python2.5/site-packages/Trac-0.11.2-py2.5.egg/trac/__init__.py”, line 14, in ?n __version__ = __import__(‘pkg_resources’).get_distribution(‘Trac’).version
    [Wed Nov 19 22:40:03 2008] [error] [client] PythonHandler trac.web.modpython_frontend: ImportError: No module named pkg_resources

    Any ideas of what I could be doing wrong?

    Thank you.

  • Adrian

    BTW – I am on CentOS 5.2 and I installed Trac-0.11.2 . SVN version is 1.54. CentOS installs default with Python 2.4, but I installed 2.5 through yum using remi’s repository.

    The trac web server brings everything up ok. I am just having a really hard time getting this to work in Apache.

    Thank you.

  • http://www.destiny-denied.co.uk/ Daniel Skinner

    The error you are seeting is a Python exception and ultimately the error is ‘No module named pkg_resources’

    It Python setuptools installed?

  • vodanh

    on the clicent I’m fill usrname and passwork see low

    Authorization Required

    This server could not verify that you are authorized to access the document requested. Either you supplied the wrong credentials (e.g., bad password), or your browser doesn’t understand how to supply the credentials required.

    pls help me

  • http://opensourcedevelopment.net Mike


    You can use Naraio for trac, subversion,Apache and openldap.
    It can be downloaded from http://opensourcedevelopment.net.

    It is free open source product…..


  • blaise

    hello, you should prefer this solution about selinux 😉

    sudo chcon -R -h -t httpd_sys_content_t /srv/svn
    sudo chcon -R -h -t httpd_sys_content_t /srv/trac/

    subversion explains this trick in link below

  • blaise

    sorry I spoke to fast about trac,
    the solution is here:

  • Alejandro

    Hey, thanks for the guide, it was the only one that guided me to a successful Trac configuration (or the only one I could understand, at least). I have a couple of questions:

    1. How do I have /trac in the browser to list all my projects? I believe it can be done by Trac.

    2. Is there anyway to do the creation of new projects without having to add them every time by hand to httpd.conf? Maybe there is a more practical way?

    Thanks in advance.

  • http://www.destiny-denied.co.uk/ Daniel Skinner

    I’m glad the post was of use to you!

    1. I’m not entirely sure – sounds reasonable though.

    2. Yes there is. You need to write some form of shell script to make the changes for you. Note there is a non-interactive version of trac-admin you will need to use.

    Alternatively, the next evolution of this setup is to use something like Buildix which will elegantly solve 1 and 2 for you by providing a rich integration between Trac, CruiseControl and Subversion, allowing you to easily create and manage projects.

    See: http://buildix.thoughtworks.com/

  • fizeen

    izeen: Your comment is awaiting moderation.

    Hi daniel,
    Thanks for your excellent work.I have installed as per your suggestion without tracker.I am able to modify my original file and commit so that the modification can be accessed by respective revision numbers in command prompt.When i try to view it in apache i am able to see the files but there is no option of editing or deleting the files.can u help me and also i am getting the error message
    while restarting the httpd service but access to the svn repository is working fine

    service httpd restart
    shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
    chdir: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
    Stopping httpd: [ OK ]
    Starting httpd: [ OK ]

  • http://www.rubenortiz.es Rubén Ortiz

    I have to tell: THANKS!

    I still have to understand all steps, because uses of .so modules of APACHE as mod_dav_svn.so are a mistery for me. We don’t use SVN currently. Now Im going to make a post to spanish users of TRAC. I was able to backup/restore from a older version of TRAC. Let me post some doubts in future 😀


    Rubén Ortizs last blog post..Unable to open pty: No such file or directory

  • Pingback: Rubén Ortiz » Instalar TRAC en CentOS 5()

  • Bryan

    Thank you so much!

    Instead of the guide linked in step 3, I just used “yum install trac”. Everything seems to be working great.

  • Jim

    This looks really good. The last piece I would like to do is add SSL for some security. Any suggestions?

  • http://www.rusiczki.net/blog/ Janos

    I was having two problems:

    1. Couldn’t log into the SVN repository (at http://server/svn/project) – Apache was writing in the error log that it doesn’t have permission to open the htpasswd file, even after I chmodded it to 777.
    2. Accessing the TRAC URL was giving a 500 Internal Server Error and complaining in the log about being unable to load Genshi.

    Solution? Disable SELinux.

  • rtessmann

    Great HowTo. It works!

  • phx


    i followed your steps and seems to work, but i bound already a VirtualHost to *:80.

    So have i to add another VirtualHost with a different ServerName?

    Perhaps you can share some infos 🙂

    Thx a lot!

  • P

    Hey there,

    I followed everything and it is working fine. Trac is up and all. Only thing is I can not connect to my SVN server. When I try
    svn list I get:

    svn: PROPFIND request failed on ‘/svn/’
    svn: PROPFIND of ‘/svn/’: 403 Forbidden ()

    for my server url I used http://server/svn/ where “server” is the URL where trac is happily running.

    any ideas?



  • Pingback: Setting up Subversion and Trac on CentOS 5 | Phazeon.com()

  • Ryders

    Mate… love your work, heaps helpful and will make it in my list of best-of’s!

  • raghava

    Ihave cent os 4.7, python 2.3.4 and trying to install trac 0.11.4, after i configured every thing i got this error can any body help me…

    Traceback (most recent call last):
    File “/usr/lib/python2.3/site-packages/Trac-0.11.4-py2.3.egg/trac/web/api.py”, line 367, in send_error

    File “/usr/lib/python2.3/site-packages/Trac-0.11.4-py2.3.egg/trac/db/api.py”, line 111, in _parse_db_str
    scheme, rest = db_str.split(‘:’, 1)
    ValueError: unpack list of wrong size

  • phaneendra

    why don’t u used pam authentication.

  • http://www.rubenortiz.es Rubén Ortiz


    nice guide! I linked you in my blog. One question, in which part of your guide we associate Trac and SVN?

    “and the Trac wiki (http://server/trac/) associated with the repository.”

    Is some strange to understand currently.


  • guild

    When I run the command:

    trac-admin /srv/trac/support permission add usaf TRAC_ADMIN

    I get the following error:

    Traceback (most recent call last):
    File “/usr/bin/trac-admin”, line 7, in ?
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py”, line 1314, in run
    return admin.onecmd(command)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py”, line 133, in onecmd
    rv = cmd.Cmd.onecmd(self, line) or 0
    File “/usr/lib/python2.4/cmd.py”, line 219, in onecmd
    return func(arg)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py”, line 426, in do_permission
    self._do_permission_add(user, action)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py”, line 463, in _do_permission_add
    self._permsys.grant_permission(user, action)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/perm.py”, line 320, in grant_permission
    self.store.grant_permission(username, action)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/perm.py”, line 223, in grant_permission
    db = self.env.get_db_cnx()
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/env.py”, line 273, in get_db_cnx
    return DatabaseManager(self).get_connection()
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/db/api.py”, line 85, in get_connection
    connector, args = self._get_connector()
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/db/api.py”, line 118, in _get_connector
    scheme, args = _parse_db_str(self.connection_uri)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/db/api.py”, line 146, in _parse_db_str
    scheme, rest = db_str.split(‘:’, 1)
    ValueError: need more than 1 value to unpack

  • Gannu

    I am a newbie to Trac and SVN. I successfully installed SVN on my CentOS server. Now I Installed Trac 0.11.5, when I browse it I am getting the following error
    “Internal Error

    TracError: OSError: [Errno 13] Permission denied: ‘/srv/trac/repos/plugins'”

    and when i run trac-admin /srv/trac/repos permission add root1 TRAC_ADMIN command then I am getting the following message on the server

    /root/.python-eggs/MySQL_python-1.2.3c1-py2.6-linux-i686.egg-tmp/_mysql.so:6: RuntimeWarning: Python C API version mismatch for module _mysql: This Python has API version 1012, module _mysql has version 1013.
    ¸¼ÀÔØôLX`dl ´¸Ô $,04<@DLPT`dlpt|Á
    PuTTYTraceback (most recent call last):
    File “/usr/bin/trac-admin”, line 7, in ?
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py”, line 1314, in run
    return admin.onecmd(command)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py”, line 133, in onecmd
    rv = cmd.Cmd.onecmd(self, line) or 0
    File “/usr/lib/python2.4/cmd.py”, line 219, in onecmd
    return func(arg)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py”, line 426, in do_permission
    self._do_permission_add(user, action)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/admin/console.py”, line 463, in _do_permission_add
    self._permsys.grant_permission(user, action)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/perm.py”, line 320, in grant_permission
    self.store.grant_permission(username, action)
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/perm.py”, line 226, in grant_permission
    (username, action))
    File “/usr/lib/python2.4/site-packages/Trac-0.11.5-py2.4.egg/trac/db/util.py”, line 59, in execute
    return self.cursor.execute(sql_escape_percent(sql), args)
    File “/usr/lib/python2.4/site-packages/sqlite/main.py”, line 255, in execute
    self.rs = self.con.db.execute(SQL % parms)
    _sqlite.IntegrityError: columns username, action are not unique
    [root@load repos]# PuTTY

    Please help me with this.

  • http://www.bizplancorner.com kashif

    Nice post! Thanks for sharing. I tried this and it helps me a great deal. Keep up the good work.

  • Lyndon


    Thanks for this. I successfully installed Trac on a subdomain using this method. Is there another way of installing trac and SVN for each domain/subdomain?

    Also, when I go to http://server/svn/my_repo, it show 404 error. Does this mean that I didn’t successfully install my SVN?

    Sorry for my noob questions and thanks in advance if you reply to this.


  • http://www.beeworksconsulting.com Duy Nguyen

    Great tutorial, I went through your guide and got no problem. Now I have the SubVersion and Trac installed. Thanks a lot!

  • Duy


    Followed your instruction but only one user can access the repo (the user created above). But user created in the ACL and the same steps above when they log in there just Forbidden 403 error returned.

    Any help?

  • Giedrius

    I have the same problem as a mate above:
    “Accessing the TRAC URL was giving a 500 Internal Server Error and complaining in the log about being unable to load Genshi.”

    Genshi is installed! Genshi 0.5.1

    Solution? Help !

  • Giedrius

    Ok, I disabled selinux and it helped! 🙂

  • carlo

    Thank you so much!!! It helped me to setup the subversion and trac. It works perfectly when I created the first project. Now, my question is how to create a new project for trac? : )

  • http://www.destiny-denied.co.uk/ Daniel Skinner

    @carlo: Use trac-admin /srv/trac/ initenv

  • http://www.designerhandbags888.com replica handbags sale

    Thank you so much!!!
    It helped me to setup the subversion and trac.

  • http://www.facebook.com/profile.php?id=100003469591521 Mateus

    I cannot start this beta on Ubuntu 12.10 64 bit. It seems like the plreobm is with some extension. Don’t have time to check this, so switched back to stable.[7217:7217:0115/104938:ERROR:extension_prefs.cc(1540)] Bad or missing pref ‘version’ for extension ‘ahfgeienlihckogmohjhadlkjgocpleb’terminate called after throwing an instance of ‘std::logic_error’ what(): basic_string::_S_construct null not validAborted (core dumped)