Bugzilla:Win32Install: Difference between revisions

A lot of cleanup, including using bzr instead of cvs
(A lot of cleanup, including using bzr instead of cvs)
Line 13: Line 13:
=== Bugzilla ===
=== Bugzilla ===


There's two main methods to getting the Bugzilla source - from CVS or in a tarball. The best method for fetching Bugzilla is to grab it directly from CVS, as this will allow for simple upgrades, even if you have customised Bugzilla.  
There's two main methods to getting the Bugzilla source - from bzr or in a tarball. The best method for fetching Bugzilla is to grab it directly from bzr, as this will allow for simple upgrades, even if you have customised Bugzilla.  


Read the [http://www.bugzilla.org/releases/3.2/release-notes.html Release Notes] before you do anything.  
Read the [http://www.bugzilla.org/releases/4.0/release-notes.html Release Notes] before you do anything.  


==== Installing Bugzilla From CVS ====
==== Installing Bugzilla From bzr ====


Download the CVSNT client from [http://www.cvsnt.org/] (2.15 Meg).
Download the Bazaar standalone installer from the [http://wiki.bazaar.canonical.com/WindowsDownloads Bazaar website], and run the installer.
 
Run the installation, you'll only need to install the '''Command line client''' and the '''Password Server (:pserver:) Protocol'''. Once the install has completed, log out and log in again to pick up the changes to the PATH.  


Note: this document assumes you want to install Bugzilla into '''C:\Bugzilla'''.  
Note: this document assumes you want to install Bugzilla into '''C:\Bugzilla'''.  
Line 27: Line 25:
Open the command line, and cd to the '''parent''' of the directory you want to install Bugzilla into. As we'll be installing Bugzilla into '''C:\Bugzilla''', the current directory must be '''C:\'''.  
Open the command line, and cd to the '''parent''' of the directory you want to install Bugzilla into. As we'll be installing Bugzilla into '''C:\Bugzilla''', the current directory must be '''C:\'''.  


  C:\>'''set CVSROOT=:pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot'''
  C:\>'''bzr co -r tag:bugzilla-4.0.2 bzr://bzr.mozilla.org/bugzilla/4.0 Bugzilla'''
C:\>'''cvs login'''
Logging in to :pserver:anonymous@cvs-mirror.mozilla.org:2401:/cvsroot
CVS password: '''anonymous'''
C:\>'''cvs checkout -d Bugzilla -rBugzilla_Stable Bugzilla'''
cvs checkout: cwd=C:\ ,current=C:\
cvs checkout: Updating Bugzilla
U Bugzilla/.cvsignore
U Bugzilla/Bugzilla.pm
...
U Bugzilla/template/en/default/whine/multipart-mime.txt.tmpl
U Bugzilla/template/en/default/whine/schedule.html.tmpl
cvs checkout: Updating Bugzilla/template/en/extension
U Bugzilla/template/en/extension/filterexceptions.pl
cvs checkout: Updating Bugzilla/template/en/extension/hook
   
   
  C:\>
  C:\>


==== Upgrading From CVS ====
It can take a minute or two to download all files, be patient. In the example above, '''tag:bugzilla-4.0.2''' means we want to install Bugzilla 4.0.2, and '''bugzilla/4.0''' in the URL is the branch this version belongs to (bzr doesn't guess this part of the URL for you). If you already installed Bugzilla using bzr and want to upgrade to a newer version, please follow the instructions given [[Bugzilla:Bzr#Updating_to_a_Newer_Release|here]].
 
If you've already installed an earlier version of Bugzilla from CVS or from a TarBall, updating is easy. Even if you've made customisations, CVS is smart enough to merge. If CVS needs help merging, it displays a C in the first column of its report. You need to resolve such conflicts manually.
 
C:\Bugzilla>'''cvs update -R -d -rBugzilla_Stable'''
cvs update: Updating .
P editusers.cgi
cvs update: Updating Bugzilla
P Bugzilla/Bug.pm
P Bugzilla/BugMail.pm
P Bugzilla/Chart.pm
P Bugzilla/Flag.pm
P Bugzilla/User.pm
P Bugzilla/Util.pm
cvs update: Updating Bugzilla/Auth
U Bugzilla/Auth/CGI.pm
cvs update: Updating Bugzilla/Template
cvs update: Updating Bugzilla/Template/Plugin
...
cvs update: Updating template/en/default/search
cvs update: Updating template/en/default/whine
cvs update: Updating template/en/extension
C:\Bugzilla>


==== Installing Bugzilla From the TarBall ====
==== Installing Bugzilla From the TarBall ====


Download Bugzilla from [http://bugzilla.org/download.html] (2.4 Meg).  
Download Bugzilla from the [http://www.bugzilla.org/download/#stable Bugzilla download page] (2.9 MB).  


Bugzilla ships as a Tarball, which has the extension .tar.gz. Any decent Windows archive tool should be able to extract tarballs.  
Bugzilla ships as a Tarball, which has the extension .tar.gz. Any decent Windows archive tool should be able to extract tarballs.  
Line 83: Line 41:
==== Upgrading From TarBall ====
==== Upgrading From TarBall ====


If you installed Bugzilla from the TarBall, the simplest way to upgrade is to follow the '''CVS Upgrading''' instructions.  
If you installed Bugzilla from the TarBall, the simplest way to upgrade is to follow the instructions given above about bzr.


=== MySQL ===
=== MySQL ===
Line 89: Line 47:
==== Download MySQL  ====
==== Download MySQL  ====


Download the MySQL "Windows Essentials" installer from [http://dev.mysql.com/downloads/mysql/4.1.html#Windows http://dev.mysql.com/downloads/mysql/4.1.html] (14.1 Meg).
Download the MySQL 32-bit or 64-bit MSI installer from the [http://www.mysql.com/downloads/mysql/ MySQL website] (28 MB).  
 
MySQL 5.x is now stable enough and can be used.  


==== Install  ====
==== Install  ====
Line 111: Line 67:
  Enter password: '''********'''
  Enter password: '''********'''
  Welcome to the MySQL monitor.  Commands end with ; or \g.
  Welcome to the MySQL monitor.  Commands end with ; or \g.
  Your MySQL connection id is 15 to server version: 4.0.20a-debug
  Your MySQL connection id is 1
Server version: 5.5.15 MySQL Community Server (GPL)
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
   
   
  mysql> '''GRANT ALL PRIVILEGES ON bugs.* TO 'bugs'@'localhost' IDENTIFIED BY 'sockmonkey';'''
  mysql> '''GRANT ALL PRIVILEGES ON bugs.* TO 'bugs'@'localhost' IDENTIFIED BY 'sockmonkey';'''
  Query OK, 0 rows affected (0.03 sec)
  Query OK, 0 rows affected (0.03 sec)
mysql> '''quit'''
Bye
C:\mysql\bin>
If you are running MySQL 4.1, you may encounter the '''Client does not support authentication protocol requested by server''' error message. To fix this, once the user has been created you will have to reset the password using OLD_PASSWORD:
C:\mysql\bin>'''mysql --user=root -p mysql'''
Enter password: '''********'''
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 15 to server version: 4.1.11-nt
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> '''set password for 'bugs'@'localhost' = OLD_PASSWORD('sockmonkey');'''
Query OK, 0 rows affected (0.00 sec)
   
   
  mysql> '''quit'''
  mysql> '''quit'''
Line 145: Line 81:
=== ActiveState Perl ===
=== ActiveState Perl ===


==== Download ActiveState Perl 5.8.1 or Higher ====
==== Download ActiveState Perl  ====


Download the ActiveState Perl 5.8.1 or Higher MSI from: http://www.activestate.com/activeperl/ .  
Download the ActiveState Perl 5.12.4 or higher MSI installer from the [http://www.activestate.com/activeperl/downloads ActiveState website].


Note that Bugzilla requires ActiveState Perl 5.8.1 as it needs CGI.pm version 2.93 or higher. 5.8.0 ships with CGI.pm version 2.81, 5.8.1 ships with CGI.pm version 3.00.
Note that Bugzilla currently requires Perl 5.8.1 or higher, but it's highly recommended to install ActivePerl 5.12 or higher. Bugzilla 4.2 will be the last version to support Perl 5.8.x. The next release will require Perl 5.10.1 or better. Also, there are several bugs in Perl 5.8.x which have been fixed in 5.10.1 and 5.12.
 
There is [https://bugzilla.mozilla.org/show_bug.cgi?id=281920 a bug in Time::Local 1.10], which is shipped with ActiveState Perl 5.8.6, that will cause warnings to be generated at the top of every buglist. It's a good idea to avoid version 5.8.6 (version 5.8.4 works without issue).


==== Install ====
==== Install ====
Line 165: Line 99:
If you already have ActiveState Perl installed, now's a good time to ensure you're running the latest version of ActiveState Perl, along with the latest versions of the modules.  
If you already have ActiveState Perl installed, now's a good time to ensure you're running the latest version of ActiveState Perl, along with the latest versions of the modules.  


To upgrade ActiveState Perl, follow the directions at: [http://aspn.activestate.com/ASPN/docs/ActivePerl/install.html#upgrade_56 http://aspn.activestate.com/ASPN/docs/ActivePerl/install.html]
Upgrading ActiveState Perl requires to delete the old version and install the new one. The reason is that Perl modules installed with one version of Perl are not compatible with a newer version of Perl. So you will have to reinstall these modules again.
 
To upgrade your modules, simply run '''ppm upgrade'''
 
==== Create Temp Directory ====
 
On Windows, Perl has a hard time of locating the correct directory to write its temporary files (CGI.pm, File::Spec). Basically it has a list of paths hard coded to use, instead of querying Windows for the correct path.
 
To avoid problems, create the '''C:\Temp''' directory (it has to be on drive C) and ensure SYSTEM has write and modify access.  


==== Install Modules  ====
==== Install Modules  ====


Bugzilla requires a number of perl modules to be installed. They are available in the ActiveState repository and the following additional repositories:<br>Perl 5.8.x:<br>&nbsp;&nbsp;&nbsp;'''http://theoryx5.uwinnipeg.ca/ppms/'''<br>Perl 5.10.x:<br>&nbsp;&nbsp;&nbsp;'''http://cpan.uwinnipeg.ca/PPMPackages/10xx/''' and<br>&nbsp;&nbsp;&nbsp;'''http://trouchelle.com/ppm10/'''<br>  
Bugzilla requires a number of perl modules to be installed. They are available in the ActiveState repository and the following additional repositories:<br>Perl 5.8.x:<br>&nbsp;&nbsp;&nbsp;'''http://theoryx5.uwinnipeg.ca/ppms/'''<br>Perl 5.10.x:<br>&nbsp;&nbsp;&nbsp;'''http://cpan.uwinnipeg.ca/PPMPackages/10xx/''' and<br>&nbsp;&nbsp;&nbsp;'''http://trouchelle.com/ppm10/'''<br>Perl 5.12 doesn't require any additional repository. It already contains everything that Bugzilla needs.


If you use a proxy server or a firewall you may have trouble running PPM. This is covered in the [http://aspn.activestate.com/ASPN/docs/ActivePerl/faq/ActivePerl-faq2.html#ppm_and_proxies ActivePerl FAQ].  
If you use a proxy server or a firewall you may have trouble running PPM. This is covered in the [http://aspn.activestate.com/ASPN/docs/ActivePerl/faq/ActivePerl-faq2.html#ppm_and_proxies ActivePerl FAQ].  


The '''Net::LDAP''' module is only required if you want to [http://www.bugzilla.org/docs/tip/html/extraconfig.html#bzldap use Active Directory for authentication].  
The '''Net::LDAP''' module is only required if you want to use Active Directory for authentication.  


The following are the commands and ouput for a 5.10.x perl module installation:
The following are the commands and ouput for a 5.10.x perl module installation. If you don't want to use the command-line interface but prefer a nice Graphical User Interface (GUI), simply type "ppm", or look for the Perl Package Manager in the Windows Start bar.


  C:\&gt;ppm version
  C:\&gt;ppm version
Line 325: Line 251:
=== Apache ===
=== Apache ===


It is recommended that you run Bugzilla with the Apache web server. If you want to use IIS to run Bugzilla, there are [http://www.bugzilla.org/docs/2.20/html/configuration.html#http-iis configuration instructions] in the Bugzilla documentation.  
It is recommended that you run Bugzilla with the Apache web server. If you want to use IIS to run Bugzilla, there are [http://www.bugzilla.org/docs/4.0/en/html/configuration.html#http-iis configuration instructions] in the Bugzilla documentation.  


==== Download Apache 2.x ====
==== Download Apache 2.x ====


Download the Apache HTTP Server version 2.x or high from: http://httpd.apache.org/download.cgi (5.8 Meg).
Download the Apache HTTP Server version 2.2.x or higher from: http://httpd.apache.org/download.cgi


==== Install ====
==== Install ====
Line 507: Line 433:
  C:\&gt;
  C:\&gt;


=== Extras ===
While Bugzilla 2.20 has built in support for SMTP servers, it doesn't (yet) support SMTP authentication or debugging of SMTP errors.
If you require SMTP authentiation (including POP before SMTP), you can use [http://www.glob.com.au/sendmail/ Glob's sendmail wrapper]. Download and install as per the instructions on that site.
If you enable logging in Sendmail, you need to ensure that your Apache account has write access to '''C:\usr\lib'''.


=== Configure Bugzilla ===
=== Configure Bugzilla ===
Line 525: Line 444:
  C:\bugzilla&gt;'''perl checksetup.pl'''
  C:\bugzilla&gt;'''perl checksetup.pl'''
   
   
  Checking perl modules ...
Set up gcc environment - 4.4.3
  Checking for       AppConfig (v1.52)   ok: found v1.55
* This is Bugzilla 4.1.3 on perl 5.14.1
  Checking for            CGI (v2.93)   ok: found v3.10
* Running on Win7 Build 7601 (Service Pack 1)
  Checking for    Data::Dumper (any)    ok: found v2.121_04
  Checking for   Date::Format (v2.21)   ok: found v2.22
  Checking perl modules...
  Checking for             DBI (v1.38)   ok: found v1.48
  Checking for               CGI.pm (v3.51)     ok: found v3.55
  Checking for     File::Spec (v0.84)   ok: found v3.05
Checking for          Digest-SHA (any)      ok: found v5.62
  Checking for     File::Temp (any)    ok: found v0.16
  Checking for            TimeDate (v2.21)    ok: found v2.24
  Checking for       Template (v2.08)   ok: found v2.13
Checking for            DateTime (v0.28)     ok: found v0.70
  Checking for     Text::Wrap (v2001.0131) ok: found v2001.09293
  Checking for    DateTime-TimeZone (v0.79)    ok: found v1.35
  Checking for   Mail::Mailer (v1.65)   ok: found v1.67
Checking for                  DBI (v1.614)    ok: found v1.616
  Checking for       Storable (any)    ok: found v2.13
Checking for    Template-Toolkit (v2.22)    ok: found v2.22
  Checking for           Email-Send (v2.16)     ok: found v2.198
  Checking for           Email-MIME (v1.904)   ok: found v1.908
  Checking for                 URI (v1.37)    ok: found v1.58
Checking for      List-MoreUtils (v0.22)     ok: found v0.32
  Checking for   Math-Random-ISAAC (v1.0.1)    ok: found v1.004
Checking for                Win32 (v0.35)    ok: found v0.44
Checking for            Win32-API (v0.55)    ok: found v0.62
Checking available perl DBD modules...
  Checking for               DBD-Pg (v1.45)     ok: found v2.17.2
  Checking for           DBD-mysql (v4.001)   ok: found v4.019
  Checking for           DBD-SQLite (v1.29)     ok: found v1.33
  Checking for           DBD-Oracle (v1.19)    ok: found v1.27
   
   
  The following Perl modules are optional:
  The following Perl modules are optional:
  Checking for             GD (v1.20)   ok: found v2.16
  Checking for                   GD (v1.20)     ok: found v2.45
  Checking for     Chart::Base (v1.0)   ok: found v2.3
  Checking for               Chart (v2.1)     ok: found v2.4.2
Checking for    XML::Parser (any)    ok: found v2.34
  Checking for         Template-GD (any)       ok: found v1.56
  Checking for       GD::Graph (any)     ok: found v1.43
  Checking for           GDTextUtil (any)       ok: found v0.86
  Checking for GD::Text::Align (any)     ok: found v1.18
  [...]
  Checking for    PatchReader (v0.9.4)  ok: found v0.9.5
   
   
Most ActivePerl modules are available at Apache's ppm repository.
A list of mirrors is available at
    http://www.apache.org/dyn/closer.cgi/perl/win32-bin/ppms/
You can add the repository with the following command:
    ppm rep add apache http://www.apache.org/dist/perl/win32-bin/ppms/
Checking user setup ...
   
   
  This version of Bugzilla contains some variables that you may want
  This version of Bugzilla contains some variables that you may want
Line 592: Line 516:
  C:\bugzilla&gt;perl checksetup.pl
  C:\bugzilla&gt;perl checksetup.pl
   
   
  Checking perl modules ...
  [...]
Checking for      AppConfig (v1.52)  ok: found v1.55
Checking for            CGI (v2.93)  ok: found v3.10
Checking for    Data::Dumper (any)    ok: found v2.121_04
Checking for    Date::Format (v2.21)  ok: found v2.22
Checking for            DBI (v1.38)  ok: found v1.48
Checking for      File::Spec (v0.84)  ok: found v3.05
Checking for      File::Temp (any)    ok: found v0.16
Checking for        Template (v2.08)  ok: found v2.13
Checking for      Text::Wrap (v2001.0131) ok: found v2001.09293
Checking for    Mail::Mailer (v1.65)  ok: found v1.67
Checking for        Storable (any)    ok: found v2.13
The following Perl modules are optional:
Checking for              GD (v1.20)  ok: found v2.16
Checking for    Chart::Base (v1.0)    ok: found v2.3
Checking for    XML::Parser (any)    ok: found v2.34
Checking for      GD::Graph (any)    ok: found v1.43
Checking for GD::Text::Align (any)    ok: found v1.18
Checking for    PatchReader (v0.9.4)  ok: found v0.9.5
Most ActivePerl modules are available at Apache's ppm repository.
A list of mirrors is available at
    http://www.apache.org/dyn/closer.cgi/perl/win32-bin/ppms/
You can add the repository with the following command:
    ppm rep add apache http://www.apache.org/dist/perl/win32-bin/ppms/
Checking user setup ...
Creating data directory (./data) ...
Creating graphs directory...
Creating .htaccess...
Creating Bugzilla/.htaccess...
Creating ./data/.htaccess...
Creating ./template/.htaccess...
Creating ./data/webdot/.htaccess...
Precompiling templates ...
Checking for    MySQL Server (v3.23.41) ok: found v4.0.20a-debug
Creating table user_group_map ...
Creating table series_data ...
Creating table longdescs ...
Creating table dependencies ...
Creating table components ...
Creating table keywords ...
Creating table cc ...
Creating table duplicates ...
Creating table groups ...
Creating table flagtypes ...
Creating table profiles ...
Creating table products ...
Creating table bugs_activity ...
Creating table series_categories ...
Creating table keyworddefs ...
Creating table fielddefs ...
Creating table group_control_map ...
Creating table profiles_activity ...
Creating table group_group_map ...
Creating table user_series_map ...
Creating table bugs ...
Creating table series ...
Creating table versions ...
Creating table flagexclusions ...
Creating table logincookies ...
Creating table watch ...
Creating table bug_group_map ...
Creating table votes ...
Creating table attachments ...
Creating table flags ...
Creating table milestones ...
Creating table tokens ...
Creating table flaginclusions ...
Creating table quips ...
Creating table namedqueries ...
Creating initial dummy product 'TestProduct' ...
Populating duplicates table...
Creating duplicates directory...
Migrating old chart data into database ...
Adding group tweakparams ...
Adding group editusers ...
Adding group creategroups ...
Adding group editcomponents ...
Adding group editkeywords ...
Adding group admin ...
Adding group editbugs ...
Adding group canconfirm ...
  Looks like we don't have an administrator set up yet.  Either this is your
  Looks like we don't have an administrator set up yet.  Either this is your
  first time using Bugzilla, or your administrator's privileges might have
  first time using Bugzilla, or your administrator's privileges might have
Line 695: Line 534:
==== Parameters ====
==== Parameters ====


You should now be able to log into to Bugzilla using the account '''checksetup.pl''' just created. Point your web browser to &gt;http://localhost/, choose '''Log in to an existing account''', and login.  
You should now be able to log into to Bugzilla using the account '''checksetup.pl''' just created. Point your web browser to http://localhost/, choose '''Log in to an existing account''', and login.  


In the page footer, choose '''Parameters'''.  
In the page footer, choose '''Parameters'''.  
Line 775: Line 614:
== Installing Bugzilla on Microsoft Windows with IIS ==
== Installing Bugzilla on Microsoft Windows with IIS ==


Bugzilla works with IIS as a normal '''CGI application'''; follow the Microsoft documentation with regards to configuring IIS.
Bugzilla works with IIS as a normal '''CGI application'''; follow the Microsoft documentation with regards to configuring IIS. On Windows 7, configuring IIS 7 is very easy, as explained in this [http://lpsolit.wordpress.com/2010/10/22/make-bugzilla-work-with-iis7-easy/ blog post].


=== Common Problems ===
=== Common Problems ===
Confirmed users
683

edits