PSORTb version 2.1.0 Installation Instructions


PSORTb is described in: Gardy, J.L., Laird, M.R., Chen, F., Rey, S., Walsh, C.J., Ester, M., Brinkman, F.S. PSORTb v.2.0: Expanded prediction of bacterial protein subcellular localization and insights gained from comparative proteome analysis. Bioinformatics 21(5):617-23. Please cite this publication if you use PSORTb in your research.

The standalone version of PSORTb is distributed under the GNU General Public Licence (Gnu GPL). The program was initially been developed for the Linux environment, but has since been ported to OS X (Darwin).

This document describes the installation of the PSORTb version 2.0.1 command line program and the PSORTb server packages. For most purposes, following the installation instructions for the command line version will be sufficient - the server package installation instructions are only necessary if one wishes to set up their own local PSORTb server.

For further information, please contact


PSORTb has several prerequisites that must be installed for a fully functional version.

1. Either a Linux distribution or Mac OS X
PSORTb has been tested and found to work on the following Linux distributions to date: RedHat 7.3 and 9.0, SuSE 9.0, Mandrake 9.2.

2. Perl version 5.005_03 or higher (5.6.x or higher recommended)
The latest version of Perl can be obtained from

3. The Bioperl library version 1.2.x or higher
While PSORTb *has* been tested on earlier versions of Bioperl, the latest version is strongly recommended. Bioperl can be obtained from

IMPORTANT NOTE REGARDING BIOPERL: There seems to be a problem between Bioperl and BLAST on some platforms, in which the system call to BLAST returns a -1 return code. Unfortunately, despite our best efforts, we have not been able to solve this problem. As a result, PSORTb may not run properly when installed onto certain platforms. This problem has been reported on a small number of machines to date running PSORTb under RedHat 9.0 and Solaris. The problem is not apparent, however, on other machines running these distributions, or when the program was tested under RedHat 7.3, SuSE 9.0, and Mandrake 9.2.

If you encounter this problem, we have developed a workaround. Comment out the line:

$self->throw("$executable call crashed: $? $commandstring\n")unless ($status==0) ;

in the file Bio/Tools/Run/ at approximately line 633.

Please contact us at in the event that you find this problem occuring under other distributions, or if the workaround does not solve the problem. Please include in your email your operating system type and version, the version of Perl you are using (the output of 'perl -V' is best), and the version of Bio::Tools::PSort you are using. Your feedback will help us in solving this problem!

4. The Perl Algorithm::SVM and Algorithm::HMM modules
The latest versions of both modules are available on the PSORTb website at

5. A working installation of standalone NCBI BLAST
BLAST can be obtained from the NCBI FTP site at

6. A working installation of PFTOOLS
PFTOOLS can be obtained from

7. A working version of the XML-RPC perl module version 1.26 or higher
XML::RPC can be obtained from

PSORTb can also be installed as a server. External programs are able to send requests to the PSORTb server via an XML-RPC API. This option is highly recommended if PSORTb is going to be used extensively on a continuous basis. We have included a sample Perl web-client with this package. If you plan on setting up PSORTb to act as a server, the following additional packages are required:

1. Apache version 1.3.x with mod_perl already installed
For more information on apache and mod_perl, please consult the corresponding websites at and
A prior working installation of Apache and mod_perl is assumed in this document.

2. The Perl IO::String modules and the Perl Apache::Singleton (if running a web server)
All modules can be obtained from CPAN at


Please ensure that you have installed all of the prerequisite packages before performing this step.

Unzip the Bio-Tools-PSort archive. Next, in the directory created when you unzipped the Bio-Tools-PSort archive, run the following commands (Note that you will most likely have to have administrative privileges to run these commands successfully):

perl Makefile.PL
make test
(optional, but recommended)
make install

This should install and test all of the modules distributed with the package. If this step is successful, please proceed to the next step - configuring standalone PSORTb.


Bio::Tools::PSort stores per-module configurations and other necessary files under the 'psort' directory. These files are not installed in the previous step, and it is recommended that you copy this directory to a more permanent location like /usr/local/psort/ using a command like cp -r psort /usr/local/

This command will create a new directory called /usr/local/psort/. Note that you will have to have the appropriate permissions to execute this command.

It is also necessary to create the BLAST database used by the Bio::Tools::Run::SCLBlast module. After performing the above step, switch into the $PSORT_ROOT/conf/analysis/sclblast directory (where $PSORT_ROOT is the directory where you just copied the files to), and using the formatdb program distributed with the NCBI BLAST package, run the command (ensuring the formatdb is in your $PATH variable)

Standalone PSORTb requires several environment variables to be set so that it can find the locations of various programs it requires. You will have to set the following variables:


to point to the PSORT_ROOT directory, the location of PFTOOLS (pfscan specifically) and the location of the BLAST installation, respectively.

A local PSORTb program is available in $PSORT_ROOT/bin and can be used to test your setup.

Once this step has been successfully completed, installation of standalone PSORTb is complete. This will be sufficient for most users of the program. However, if you wish to set up a PSORTb server, you must proceed to the following step - configuring a PSORTb server. If you're not sure whether or not you want to set one up, you probably don't need need one and can just stop here :-)


If you DO NOT want to setup a PSORTb server, you DO NOT have to perform this step.

This section assumes you have a working installation of Apache/mod_perl and have installed all of the required modules outlined in the PREREQUISITES section. It also assumes that you have completed the previous section detailing the installation of standalone PSORTB - if you haven't completed the previous section, go back and do so now.

Open up Apache's httpd.conf in an editor and add the following lines in the mod_perl setup section (assuming one exists - you can add them at almost any point in the file):

PerlSetVar RpcMethodDir /usr/local/psort/server/rpc/
PerlChildInitHandler Apache::RPC::Server->init_handler

Note that if you have not installed the PSORTb files into the recommended $PSORT_ROOT directory, you should change the value of the first line to point to the correct location.

The above lines set up the Apache webserver to listen for XML-RPC requests. The code defining the methods used to handle the requests are located in the RpcMethodDir (in this case /usr/local/psort/server/rpc).

Next, you'll need to associate a mod_perl handler with a specific request URL. Inside the VirtualHost definition that you want to handle the requests (it doesn't have to be inside a VirtualHost section though) add the following lines:

<Location /RPC>
SetHandler perl-script
PerlHandler Apache::RPC::Server

A sample file has also been included with this package, and is located under $PSORT_ROOT/server/

You should copy the appropriate sections into your file (usually located in the same directory as httpd.conf). MAKE SURE THAT YOU MODIFY THE $PSORT_ROOT, $HMMTOP_DIR and $BLAST_DIR VARIABLES TO POINT TO THE APPROPRIATE LOCATIONS ON YOUR SYSTEM.

Note that you should also ensure that is being loaded by Apache - there should be an Apache directive similar to:

PerlRequire conf/

in your httpd.conf file. If it doesn't exist, you'll have to add it, ensuring that the path to is correct relative to the httpd root.

Restarting Apache should now provide you with a PSORTb server installation. The PSORTb program provided in $PSORT_ROOT/bin can be used to test your SERVER installation if you use the --server option.