Installing Mantis On Iisc
One of the first tasks in my new job was to install bug-reporting software for in-house development. I have used Mantis Bug Tracker (before and found it easy-to-use and not overloaded with unnecessary features. To use Mantis Bug Tracker, PHP needs to be installed first.
Since the servers are Windows servers, PHP must be configured with IIS. My installation notes are listed below. Install PHP • Download PHP - 5.2.5-Win32.zip (binaries - NOT installer) - provided • Extract zipped PHP and save to C: php • Rename php.ini-dist to php.ini (This file is in the root folder.) • Add C: php to the Path variable. (Optional) • In the PHP folder, locate the files php5ts.dll and php_mssql.dll and place them in the C: windows folder so they can be accessed. Configure PHP.ini • To configure mail on PHP, locate the line 'SMTP' and add the SMTP mail host and port.
• The following must be done so that PHP will work with IIS. To get PHP to work as a CGI for IIS, change:; cgi.force_redirect = 1 to: cgi.force_redirect = 0 • To set up PHP to work with MS SQL, uncomment the following line under extensions: extension=php_mssql.dll Configure IIS and PHP to work together This assumes that IIS is already installed on the web server. First, create a new folder on the web server to store the PHP web files. Click Start ->Settings ->Control Panel. Double-click Administrative Tools. Double-click Internet Services Manager. On the Tree tab on the left, click the plus sign beside your computer's name.
Under the 'Development' node under 'Web Sites', right click on 'Development' and create a new Virtual Directory for the PHP websites named PHPWeb. Browse to the new folder created at the beginning of this section. Choose read/write/access options that you wish to include (can be changed later) and 'Finish' to create. This closes the wizard too. Right click on 'Development' and view Properties.
Choose the Home Directory tab, then choose Configuration (near the bottom) 8. Click Add, then Browse. Navigate to C: PHP php-cgi.exe, and select this. Add in.php as the extension, and tick Check that file exists. Now click OK on all subsequent windows, and exit Internet Services Manager. Right click on the new directory PHPWeb. Click the 'Documents' tab.
Add index.php to the list of default content pages. Configure PHP and MSSQL 1.
Download a new copy of ntwdblib.dll - provided. (The one packaged with PHP5 is out of date, so it won't work if it's not replaced.) 2. Copy the file into the c: php (root) folder. Also place a copy of the file in c: windows system32 MS SQL Database server The 'mixed' SQL access should be selected; it is by default on the SQL server. Nothing needs changed. New users can be set up for accessing Mantis Bug Tracker. Create a new user for Mantis.
Installing Mantis 1. Download a copy of Mantis. Mantis 1.1.0 is what was used for this installation. Unzip this and put it into the new folder that was previously created for storing the PHP pages on the web server. If the database for Mantis has not been set up, you will be prompted to type in password/usernames/host for the database to install the 'bugtracker' database that Mantis uses. Type in the database host.
If MSSQL is configured correctly and the password and username is correct, the database creation for Mantis will be successful.
Personal Bug Tracking with Mantis on Windows GBB Services::: Personal Bug Tracking with Mantis on Windows by Whenever I do work for a client, I check my changes into their version control system, and I update my tasks using their bug tracking system (when they have one). Independently of that, I also use my own personal version control system to track the changes I make as I develop.
But, I've never used a personal bug tracking system. That I should change my evil ways, and so I did.
New users can be set up for accessing Mantis Bug Tracker. Create a new user for Mantis. Installing Mantis. Download a copy of Mantis. Mantis 1.1.0 is what was used for this installation. Unzip this and put it into the new folder that was previously created for storing the PHP pages on the web server. Mantis Installation - Learn Mantis in simple and easy steps starting from basic to advanced concepts with examples including Introduction, Features, Installation.
After hearing about the hassles a client had with the closed source product TestTrack Pro from Seapine Software (the outgoing mail port is hard coded) I decided to go with an open source product. If I need to tweak things, I don't want to depend on the owners of the source to get around to making the changes I want, if they make them at all.
Free is nice, but not crucial. GBB Services spends thousands of dollars every year on development software (and thousands more on hardware).
We're willing to spend money for the right products! The best known open source bug tracker seems to be, and I downloaded it. That's about as far as I got. It's way too complicated for my purposes, and I dumped it quickly. Then I heard about.
'Easy to install, easy to customize, free, open source, works on Windows 2000.' It sounded good. It took me a while to get Mantis working, mostly because I didn't know what I was doing.
Knowing what I know now, I can get Mantis installed on a fresh machine a LOT faster. With this note I'll be sharing some of what I learned. Mantis requires that at least two other open source programs are installed and working. They are the database application MySQL, and the scripting language PHP.
I didn't have either before I started, so I had to install and use both for the first time, and then I had to coordinate their use with Mantis. It's no problem, if things go well. I'll be mentioning some diagnostics you can run to immediately tell if things are going well or not. Also, Mantis requires that a web server be installed.
I've gotten it working on two machines: a windows 2000 machine with IIS running, and a windows XP machine with Apache running. Some details are different, depending on the http server used. If you don't care which one you use, it's probably less of a hassle to work with IIS.
Incidentally, every bug tracking product I know of requires a database program, and just about all the bug tracking systems are accessed via a browser, which means that a web server has to installed. You won't get away from these requirements by avoiding Mantis! If you haven't installed IIS, Apache, or some other http server, you'll need to that first. I've provided some pointers, but it's not the main emphasis of this essay.
Also, if you care about security, you won't find any help here. I'm not really concerned about password security (for web server administration, mysql administration, or Mantis administration) since I'm the only one who's accessing my machines. Finally, if you're interested in setting up email notifications, you won't find any help here. I don't need them for personal bug tracking. I could only find two sources of information for installing Mantis on Windows 2000 systems. One is by (the leader of the Mantis project) at, and the other is by (a contract programmer specializing in Java and C++ programming for the Web, Windows and Macintosh). Both sources were extremely helpful, and although these notes are meant to be usable without them, it sure wouldn't hurt to read them.
I strongly recommend methodically going through the following steps in order, and not starting any step until all previous steps have been successfully achieved: In this essay I'll be recommending that you create various diagnostic files which are to be placed in the location Since I've already created them and placed them in the zip file (1,238 bytes), you can save yourself some typing (or at least some cut and paste mouse clicking) by downloading. Just create the subdirectory mantisinfo under the web root and unzip the files there. This section is extremely sketchy compared to the other sections.
It's the bare minimum you'll need to get through the installation. If you're looking to install IIS on a Windows 2000 machine, open up the control panel, click on 'Add/Remove Programs', then click on 'Add/Remove Windows Components' (which is a button to the left of the 'Currently installed programs' list). If 'Internet Information Services (IIS)' is unchecked, check it. Hit 'Next' and get your Windows 2000 Professional installation disk. Once you've successfully installed IIS, you'll probably want to become familiar with the command line incantations 'net start w3svc' and 'net stop w3svc'.
If you're looking to install, download the installation program and follow the instructions. The configuration file you'll have to become familiar with is 'C: Program Files Apache Group Apache conf httpd.conf'. Being able to type 'net start apache' and 'net stop apache' at the command line will also come in handy. Create a page 'index.html' in your (web site) root directory, and then point your web browser to it. You will probably want to use the url Firstly, go to the site at and download the file 'mysql-4.0.17-win.zip'. It's 23,911,855 bytes and is available in the section.
Look for 'Windows 95/98/NT/2000/XP/2003 (x86) 4. Coin Hack Whirled Definition more. 0.17 22.8M') To install MySQL, unzip 'mysql-4.0.17-win.zip', placing the files in some temporary directory. Then run the 'setup.exe' program. It will offer to install MySQL in the 'C: mysql' directory. That's fine with me. I then choose the 'Typical' option and let the installation program run to completion. The next step is to copy one of the files my-huge.cnf, my-large.cnf, my-medium.cnf, my-small.cnf in 'C: mysql ' to 'C: my.cnf'. This becomes the initialization file for MySQL.
The 'huge', 'large', etc descriptors refer to the amount of memory and disk space of the local machine. I've gone with copying 'my-medium.cnf' to 'C: my.cnf'.
There's a couple of lines in my.cnf that read. C: temp>net start mysql System error 2 has occurred. The system cannot find the file specified. C: temp>you need to fix this before continuing. The first thing I would check is the 'path to executable' as described above.
OK, now let's test the that the server is working by running some client programs. The easiest thing to try is to type 'c: mysql mysql.exe' (not 'mysql d' this time, we want the client program, not the server daemon). You should get a welcome message and the mysql prompt 'mysql>'. Type 'exit' to quit the application. The entire interaction should look something like. C: temp>net stop mysql The MySQL service is stopping. The MySQL service was stopped successfully.
C: temp>c: mysql bin mysql ERROR 2003: Can't connect to MySQL server on 'localhost' (10061) C: temp>net start mysql The MySQL service is starting. The MySQL service was started successfully.
C: temp>c: mysql bin mysql Welcome to the MySQL monitor. Commands end with; or g. Your MySQL connection id is 1 to server version: 4.0.17-max-debug Type 'help;' or ' h' for help.
Type ' c' to clear the buffer. Mysql>exit Bye C: temp>At this stage the MySQL stage of the installation is done. If you haven't got the server running, there isn't much point to doing anything else. You've got to find out why it's not working. If you can't, you can try running mysql as a standalone application ( 'mysql d --standalone'). The details of what to get are different, depending on whether you're using or as your web server.
Either way, you'll want to get the installer. Get the file 'php-4. Rogers Next Box User Manual. 3.4-installer.exe' (1,068,496 bytes) from the php section. Look for 'PHP 4.3.4 installer [1,043Kb] - 03 November 2003'. Run the program 'php-4.3.4-installer.exe'. I just go with the defaults. For my Windows2000/IIS system, the Server Type was identified as 'Microsoft IIS 4 or higher', which is correct.
Run the installation to the end. Skip the next section and got to. Get the file 'php-4.3.4-installer.exe' (1,068,496 bytes) from the php section. Look for 'PHP 4.3.4 installer [1,043Kb] - 03 November 2003'. Run the program 'php-4.3.4-installer.exe'.
I just go with the defaults, EXCEPT for picking the Server Type as 'Apache'. For my WindowsXP/Apache system, the Server Type was identified as 'Microsoft IIS 4 or higher', which is NOT correct. Run the installation to the end.
Now get 'php-4.3.4-Win32.zip' (6,978,847 bytes) from the php section. Look for 'PHP 4.3.4 zip package [6,815Kb] - 03 November 2003'. Unzip the contents of 'php-4.3.4-Win32.zip' in some temporary directory.
Now move the unzipped 'sapi' subdirectory so that it becomes a subdirectory of 'c: php'. Now move the file c: php php4ts.dll to c: php sapi php4ts.dll. The final step is to modify the Apache configuration file 'httpd.conf'. Firstly, stop the apache server via the command line: 'net stop apache'. Add the following 3 lines to httpd.conf.
Connected successfully 2003-12-28 02:24:51 Assuming that you're getting something like the above two lines, it's finally time to install Mantis itself. Go to the site at and download the 0.18.0 release. You'll want to get the file 'mantis-0.18.0.tar.gz' (543,328 bytes). The first thing to do is to unzip 'mantis-0.18.0.tar.gz', keeping the directory structure intact.
All the files will be rooted at 'mantis-0.18.0'. The next step is to move that Mantis root directory to 'c: inetpub wwwroot mantis' (assuming that the root directory of your http server is 'c: inetpub wwwroot'). The last thing to do to make sure that you have a minimal installation working is to copy the file config_inc.php.sample to config_inc.php Point your browser to. You should get a diagnostics page that shows 5 colored boxes, with all of them green, except for the second one. You should have green ( GOOD ) for 'Opening connection to database on host' but red ( BAD ) for 'Selecting database' The next step is to turn all 5 boxes to green.
Kill the browser window and continue with the steps below. To make life a little easier, I'll stick with defaults and call the database 'bugtracker'. To do this, open a command line window and type 'c: mysql bin mysql', and hit return. Assuming that the mysql server is running, you should get the mysql prompt 'mysql>'. At that prompt type 'CREATE DATABASE bugtracker;' and hit return. These are sql instructions, and the semicolon is necessary. By the way, if you're unfamiliar with sql, I don't think it will matter for working with Mantis.
Once you've set things up, you really don't need to do much with MySQL at all. If all went well, you should see something like the message: Query OK, 1 row affected (0.02 sec) The mysql prompt should be available again. Type 'exit' and hit return. You're should now be back to seeing the command line prompt. Now type 'c: mysql bin mysql bugtracker. C: temp>c: mysql bin mysql Welcome to the MySQL monitor. Commands end with; or g.
Your MySQL connection id is 6 to server version: 4.0.17-max-debug Type 'help;' or ' h' for help. Type ' c' to clear the buffer. Mysql>CREATE DATABASE bugtracker; Query OK, 1 row affected (0.01 sec) mysql>exit Bye C: temp>cd c: mysql bin C: mysql bin>mysql bugtracker At this stage, Mantis should work. Pointing to should give you a page with 5 green 'GOOD' table entries. If, like me, you don't want email notification, and you don't want to see email error information for the email capability you're not using, there's one more step.
Change the line. $g_to_email = '; $g_enable_email_notification = OFF; Now you're done!
You should now be able to point to and get a login form. Using the Username 'administrator' and the Password 'root', you should be able to get in. Add a few users, add a project or two, create some categories, and go for it. You should definitely bookmark the following pages: You should also be aware of the admin page: and the stylesheet modification page: You should be aware of the following configuration files: c: my.cnf (the configuration file for MySQL) c: winnt php.ini (the configuration file for php) c: inetpub wwwroot mantis config_inc.php (the configuration file for Mantis). Something you might want to do is to have two or more completely separate Mantis projects. One possible reason might be to create a throwaway project that you can use to experiment with. Another reason might be to keep client projects completely separate from each other.
One way to do have another Mantis project is by copying the 'mantis' subdirectory to a new 'mantis A' subdirectory. Then go to c: inetpub wwwroot mantis and edit config_inc.php The default database used by Mantis is 'bugtracker'. Since the whole point of a second Mantis installation is to keep the Mantis databases separated, change the default 'bugtracker' in config_inc.php to something else, say 'bugtracker A' All that's left is the mysql magic incantation. C: temp>cd c: mysql bin C: mysql bin>mysqldump bugtracker >bugtrackerBackup.txt C: mysql bin>mysql bugtracker mysql Welcome to the MySQL monitor. Commands end with; or g. Your MySQL connection id is 3 to server version: 4.0.17-max-debug Type 'help;' or ' h' for help. Type ' c' to clear the buffer.
Mysql>DROP DATABASE bugtracker; Query OK, 0 rows affected (0.13 sec) mysql>CREATE DATABASE bugtracker; Query OK, 1 row affected (0.00 sec) mysql>exit Bye C: mysql bin>mysql bugtracker If you have corrections, additions, modifications, etc please let me know January 1 2004 Posted January 3 2004 Last Updated.