Sugar Community Edition 6.2.3 Installation Guide
Overview
This document describes how to install and upgrade Sugar Community Edition. This information is intended for administrators. After installation, you can create users and perform other administrative tasks in Sugar.
SugarCRM uses GNU General Public License version 3 for the Sugar Community Edition.
Before installing Sugar 6.2.0, ensure that you have the appropriate components installed on your server.
Installation prerequisites and guidelines
This section lists the memory, database, and software requirements for installation.
| Note: | Install the MB String module on your web server to support multi-byte characters. |
Memory requirements
Increase the value of the memory_limit parameter in the php.ini file as follows:
| • | MySQL Server: 256M or higher |
| • | MS SQL Server: 256M or higher |
Database requirements
- For MySQL, install version 5.0 or 5.1 to use with Sugar 6.2
- For Microsoft SQL Server, download the SQL Server Driver for PHP version 2.0.1 (as per the instructions on the Microsoft website) and extract the contents to the /ext directory of the PHP installation
Select from the following DLLs as appropriate for the PHP version you are using:
| Driver File | PHP Version | Thread Safe | Use with PHP .dll |
| php_sqlsrv_53_nts_vc6.dll | 5.3 | No | php5.dll |
| php_sqlsrv_53_nts_vc9.dll | 5.3 | No | php5.dll |
| php_sqlsrv_53_ts_vc6.dll | 5.3 | Yes | php5ts.dll |
| php_sqlsrv_53_ts_vc9.dll | 5.3 | Yes | php5ts.dll |
| php_sqlsrv_52_nts_vc6.dll | 5.2 | No | php5.dll |
| php_sqlsrv_52_ts_vc6.dll | 5.2 | Yes | php5ts.dll |
Add the following line in php.ini to enable it:
extension=<dll_name>;
where dll_name is a driver file listed in the table above.
The driver also requires you to install the Microsoft SQL Server Native Client on the web server. Install the version for SQL Server 2008 even if you are installing on SQL Server 2005.
Securing your Sugar installation
To ensure that your Sugar installation is secure from unauthorized access, for Apache, it is recommended that you configure the system as described below.
Before you install Sugar, set AllowOverride to All for the Sugar installation directory in thehttpd.conf file. After you install Sugar, a .htaccessfile is created in your Sugar installation directory. This file contains the following content:
# BEGIN SUGARCRM RESTRICTIONS
RedirectMatch 403 (?i)^.*\.log$
RedirectMatch 403 (?i)/+not_imported_.*\.txt
RedirectMatch 403 (?i)/+(soap|cache|xtemplate|data|examples|include|log4php|metadata|modules)/+.*\.(php|tpl)
RedirectMatch 403 (?i)/+emailmandelivery\.php
RedirectMatch 403 (?i)/+cache/+upload
# END SUGARCRM RESTRICTIONS
To test the validity of these restrictions, access the sugarcrm.log through the browser to ensure that error #403 is displayed. If not, check your Apache configuration to ensure that htaccess is enabled. For more information, check the Apache documentation.
Downloading and installing Sugar
If you are installing Sugar on your machine for the first time, follow the instructions in this section. If you have an earlier version of Sugar installed on your machine, refer to Upgrading Sugar for instructions on how to upgrade your Sugar instance.
Follow the steps listed below to install Sugar:
| 1. | Install the platform-appropriate (Linux or Windows) version of PHP, web server, and database on your machine. |
| 2. | Download Sugar files. |
| 3. | Copy the Sugar files to your web server. Check for dependencies and requirements, and set them. |
| 4. | Navigate to the php.ini file located in your Sugar root directory and set the variables_order parameter to EGPCS. |
| 5. | Restart the web server. |
| 6. | Install Sugar Community Edition with the Sugar Setup Wizard. |
| Note: | Restart the web server before proceeding with the installation if you have modified the php.ini file. |
To download the latest Sugar files
| 1. | Go to http://www.sugarcrm.com/ |
| 2. | Navigate to Support & Training/Support Portal or visit |
| 3. | Login using your Sugar username and password. |
| 4. | Click Download Purchased Software. |
| 5. | Populate the Download Key field in the Download Manager page and click Submit. |
| 6. | Click the link for the appropriate zip file to download it. |
To copy Sugar files to the web server
After you download Sugar, you need to unzip the files and set permissions.
| 1. | Locate the webrootdirectoryon your web server. This directory stores publicly accessible files. Common locations for webroot are: |
| 2. | Unzip the Sugar zip file into your webroot. |
| 3. | Rename this directory. |
| 4. | Set permissions on the Sugar files. The following directories, all subdirectories, and files must be writable by your web server user: |
| ¢ | cache |
| ¢ | custom |
| ¢ | modules |
| ¢ | config.php |
| ¢ | config_override.php |
| ¢ | sugarcrm.log |
| Note: | Typically, there are multiple versions of the log file, such as sugarcrm.log, sugarcrm.log.1, sugarcrm.log.2, and so on. |
| ¢ | apache (Linux/Apache) |
| ¢ | nobody (Linux/Apache) |
| ¢ | IUSR_computerName (Windows/IIS) |
| 5. | Ensure that file permissions are set for Read/Execute to includes directory and sugar root directory (in addition to the already existing list of directories/files) before you view Sugar on your browser. |
Using the Sugar Setup Wizard
Use the Sugar Setup Wizard after copying the Sugar files into your web root. The Sugar Setup Wizard is located at
http://<yourServer>/<yourSugarDirectory>/install.php.
For example: http://localhost/Sugar-Full_6.2.0/install.php
You can perform a typical installation or a custom installation. Typical installation is recommended, but you can choose custom installation for the following reasons:
| • | The same Database Admin User should not be used as the Sugar database administrator |
| • | Locale settings should be specified during installation instead of after logging into Sugar |
| 1. | Launch your browser and enter the URL mentioned above. |
| 2. | Click Next. |
| 3. | Review the information and click Next. |
| 4. | Review the license, check I Accept, and click Next. |
| Note: | You can modify any of your settings at any time prior to clicking Install in the Confirm Setting menu. To modify any settings, click the Back button on your browser to return to the appropriate page. |
| 5. | Select Typical Install. Input the license key information in the Download Key field.You can also enter it after you have installed the application. |
| 6. | Click Next. |
| 7. | Select the database that is installed on your system and click Next. |
| a. | Enter the database name. The Installer uses sugarcrm as the default name for the database. You can specify a new name. |
| b. | Enter the Host Name or the Host Instance for My SQL and SQL Server. |
| c. | Enter the username and password for the Database Administrator and specify the Sugar Database Username. |
| d. | Ensure that the Database Administrator you specify has the permissions to create and write to the Sugar database. |
| e. | Accept No as the default value if you do not want the Sugar Demo data. Select Yes to populate the database with the Sugar Demo data. |
| 8. | Click Next. |
| 9. | Click Accept to accept the database name or click Cancel and enter a new name in the Database Name field. |
| 10. | Enter a name for the Sugar administrator. |
| 11. | Enter a password for the Sugar admin, re-enter it to confirm the password, and click Next. |
| 12. | Click Print Summary for a printout of the settings for your records. |
| 13. | Click Install. |
| 14. | Click Next when the setup is complete. |
| 15. | Enter the necessary information and click Send Registration to register your Sugar instance with SugarCRM; or click No Thanks to skip registration. |
| 1. | Launch the browser and enter the URL described above. |
| 2. | Click Next. |
| 3. | Review the information and click Next. |
| 4. | Review the license, check I Accept, and click Next. |
| 5. | Select Custom Install and click Next. |
| 6. | Select the database of your choice and click Next. |
| 7. | Enter the database name. |
| a. | Enter the Host Name or the Host Instance for My SQL and SQL Server. |
| b. | Enter the username and password for the Database Administrator and specify the Sugar Database Username. |
| c. | Accept No as the default value if you do not want the Sugar Demo data. Select Yes to populate the database with the Sugar Demo data. |
| 8. | Click Next. |
| 9. | Click Accept to drop current tables or click Cancel and specify a new database name. |
| 10. | Click Next. |
| 11. | Enter the URL of your Sugar instance. |
| 12. | Enter a name for your system to display on the Sugar application’s browser title bar. |
| 13. | Enter a name for the Sugar administrator. The Sugar administrator (default name admin) has administrative privileges in Sugar. You can change the default name. |
| 14. | Enter a password for the Sugar administrator, re-enter it to confirm the password, and click Next. |
| 15. | Select the desired security options and input information in the relevant fields. |
| 16. | Click Next. |
| 17. | Click Show Passwords and Print Summary to include the database user and the Sugar admin passwords in the printout. |
| 18. | Click Install. |
| 19. | Click Next when the setup is complete. |
| 20. | Enter the necessary information and click Send Registration to register your Sugar instance with SugarCRM or click No Thanks to skip registration. |
Upgrading Sugar
This section describes how to upgrade Sugar Ultimate, Sugar Enterprise, Sugar Corporate, Sugar Professional, and Sugar Community Edition using the Upgrade Wizard or the Silent Upgrader.
You can upgrade from Sugar versions 6.0.x and 6.1.x to Sugar 6.2.0.
Download the appropriate upgrade.zip file from the Sugar website to your local machine to upgrade your Sugar application. For example, to upgrade Sugar Professional from 6.0.x to 6.2.0, you will need the SugarPro-Upgrade-6.0.x-to-6.2.0.zipfile. To upgrade from 6.1.0, you will need the SugarPro-Upgrade-6.1.x-to-6.2.0.zip file
For Sugar Ultimate, Sugar Enterprise, Sugar Corporate, and Sugar Professional, download the Upgrade zip file from the Sugar Support Portal at http://www.support.sugarcrm.com into your local machine. For Sugar Community Edition, you can upload the Upgrade zip file to your local machine from the SugarCRM website.
Log into the Sugar application to use the Upgrade Wizard. Run a PHP script from the command line on the server where the Sugar instance is installed to use the Silent Upgrader.
| CAUTION: | It is strongly recommended that you run the upgrade process on a copy of your production system. |
Compatibility matrix for upgrade
| PHP version | 5.2.1-5.2.6, 5.2.8-5.2.15, 5.2.17, 5.3.0 - 5.3.6 |
| Databases | MySQL - 5.0x, 5.1 MSSQL - 2005, 2008 Oracle - 10g, 11g (Oracle is supported only for Sugar Ultimate and Sugar Enterprise) |
| Operating systems | Windows: Sugar runs on any OS that runs PHP Linux: Sugar runs on any OS that runs PHP Mac: Sugar runs on any OS that runs PHP |
Upgrade prerequisites
| • | Backup your current Sugar directory and database before beginning the upgrade process. |
| • | Disable op-code caching before upgrading your Sugar installation if op-code caching is enabled in the PHP configuration file. You can enable it after the upgrade process is complete. |
| • | Increase the default value of the parameters listed below before you begin the upgrade process if you are using Zend Core 2.0: |
| ¢ | Navigate to C:\Program Files\Zend\Core\etc\fastcgi.conf and increase the default value for ConnectionTimeout to 3000 seconds and RequestTimeout to 6000 seconds. |
| ¢ | Navigate to the php.ini file and increase the default value of max_execution_time to 6000 seconds. |
| • | Perform the following for the large size of the upgrade files: |
| ¢ | Modify and save the value of Maximum upload size to 21000000 (20MB) in the Advanced section of the System Settings page of your current Sugar installation. |
| ¢ | Navigate to the php.ini file on your web server and configure the parameters listed below in the Advanced section of the System Settings page of your current Sugar installation: |
| l | Set post_max_size to at least 60MB |
| l | Set upload_max_filesize settings to at least 60MB |
| l | Set max_input_time to a large number |
| l | Set memory_limit to 256MB |
Restart the web server and begin the upgrade process.
| • | Ensure that LimitRequestBody is set to a large number or use the default value of 2GB if you are using an Apache web server and LimitRequestBody is set in the httpd.conffile. Restart Apache and begin the upgrade process. |
| • | Ensure that the webserver user has write permissions to the Sugar database. The upgrade to Sugar 6.2 will add and replace files in several locations including the Sugar root directory. The webserver user must have write permissions for the root folder and all sub-directories during the upgrade process. |
| • | The process of upgrading can take up to 30 minutes. Set the CGI script timeout to more than the default 300 seconds to ensure that the CGI application does not time out if you are using the IIS web server. |
| • | Save PHP files for customized modules (for example, accounts.php) in the Customs directory and not within the main module. Existing customizations may be overridden by changes in Sugar 6.2 during upgrade. |
Using the Upgrade Wizard
The Upgrade Wizard provides a quick way to upgrade to the latest version of the Sugar application. It includes critical upgrade logic as well as the SQL commands needed to upgrade the application.
Ensure that the config.php file for your installation, located in the Sugar root directory, is writable, before using the Upgrade Wizard.
| Note: | Manual upgrades by file replacements and running the upgrade SQL are not supported. |
| 1. | Download the appropriate Sugar Upgrade zip file from the Sugar website to your local machine. For example, download the SugarPro-Upgrade-6.0.x-to-6.2.0.zipfile to upgrade Sugar Professional from version 6.0.x to 6.2.0. Download the appropriate conversion file to convert to Sugar Professional or Sugar Enterprise. |
| 2. | Log into your existing Sugar application as the administrator and click admin on the right-hand corner of the page. |
| 3. | Click Upgrade Wizard in the Systems panel of the Administration Home page. |
| 4. | Click Next. |
| 5. | Click Next if the system check is successful. |
| 6. | Click Browse, and navigate to the location of the upgrade zip file and select it. |
| 7. | Click Upload Upgrade to upload the package to the Sugar application. |
| 8. | Click Next. |
| 9. | Click Recheck to rerun Preflight Check. Click Next to skip this step. |
| 10. | Click Next. |
| a. | The Confirm Layouts page appears as Step 5 in the Upgrade Wizard |
| b. | The Confirm Layouts page displays the Notes module with the EditView and DetailView layouts. The Email Templates layouts do not display on the Confirm Layouts page because the existing layouts were not customized. |
| c. | The Administrator has the option of choosing to merge the changes in the Notes module with the existing customized EditView layout. |
| 11. | Uncheck the module if you do not want to add the new fields to a module. |
| 12. | Click Next. |
| 13. | Click Next. |
| 14. | The Debrief page confirms the upgrade installation. Complete the steps for manual merging of files or running SQL queries now. |
| 15. | Click Done. |
| 16. | Click Repair and select the Rebuild Relationships andRebuild Extensions options in the Systems panel of the Administration Home page. |
| 17. | Manually merge the files by extracting the skipped file from the patch zip file if you unchecked any files to prevent the Upgrade Wizard from overwriting them. Merge the file installed in the Sugar application directory. |
| Note: | Check the upgradeWizard.log file in the Sugar folder for information on unsuccessful Sugar upgrades. |
Locking down the Upgrade Wizard
You can lock down the Upgrade Wizard to ensure that no user with administrative privileges can upgrade any of them, if you are managing multiple instances of the Sugar application and you want to maintain complete control over the Sugar instances. Follow the steps listed below to lock down functions on the Administration page:
| 1. | Navigate to the config.php file in the Sugar root directory. |
| 2. | Set the following parameter to true as below: |
| 3. | Save the file. |
Converting Sugar editions
The Upgrade Wizard enables you to convert from one Sugar edition to another. Obtain the Sugar license key from your sales representative for the Sugar edition you want.
The table below lists the supported conversions.
| Sugar Edition | Supported Conversion |
| Sugar Community Edition versions 6.0.x, 6.1.x | Sugar Ultimate 6.2.0 Sugar Enterprise 6.2.0 Sugar Corporate 6.2.0 Sugar Professional 6.2.0 |
| Sugar Professional versions 6.0.x, 6.1.x | Sugar Ultimate 6.2.0 Sugar Enterprise 6.2.0 Sugar Corporate 6.2.0 |
| Sugar Enterprise versions 6.0.x, 6.1.x | Sugar Ultimate 6.2.0 |
You will need to obtain the Sugar license key from your sales representative for the Sugar edition you want.
Conversions are a two-step process. First you must upgrade your existing Sugar application from the current version to 6.2.0. You can then convert to the desired Sugar edition using the appropriate conversion zip file.
For example, to move from Sugar Community Edition 6.1.3 to Sugar Enterprise 6.2.0, you must first convert to Community Edition 6.2.0 using the 6.1.x-to-6.2.0.zip file. You can then convert from Community Edition 6.2.0 to Enterprise 6.2.0 using the SugarCE-to-SugarEnt-Conversion-6.2.0.zip file.
Using the Sugar Silent Upgrader
The Silent Upgrader enables you to avoid some of the limitations that the web application environment may have that prevents the Upgrade Wizard from completing the upgrade. The upload size limit (by PHP and sometimes even by web server), the CGI (or equivalent) timeout limit, and the MySQL (or equivalent) session timeout limit are some of the challenges people run into when upgrading Sugar. The Silent Upgrader either avoids the limitations or better controls the settings in its stand-alone execution environment.
| Note: | The silentUpgrade.php script creates new files for the user. For example, for the root user it create files as user/group root. Since Apache cannot read this, you must ensure that the web server user has the permissions to read and write the script. |
| 1. | Execute the silentupgrade.php script from the command line on the server where the Sugar instance is installed: |
| 2. | Log into the Sugar application as the administrator and rebuild relationships and extensions using the Repair option in the Systems sub-panel after upgrading. |
Uninstalling a Sugar instance
Follow the steps listed below to uninstall your Sugar instance:
| 1. | Navigate to the location where Sugar is installed on your machine and delete the Sugar root directory. |
| 2. | Delete the Sugar database schema from the MySQL or MS SQL server database. |
Copyright 2004-2011 SugarCRM Inc.
Community Edition License