Results 1 to 3 of 3

Thread: Sugar CRM Community edition install on IIS7, Windows 2008 and Remote SQL Server 2008

  1. #1
    majdi.d is offline Junior Member
    Join Date
    Mar 2012
    Posts
    2

    Default Sugar CRM Community edition install on IIS7, Windows 2008 and Remote SQL Server 2008

    Hi,
    First post here, sugar install is driving me crazy. After spending a couple of hours fixing some file access rights issues, it is now passing the validation step and i am stuck on the Database Configuration.

    The server i am installing the CRM on is let's say 192.168.1.1, and the database server is 192.168.1.2, both have proper fully qualified domain names (windows domains, like server1.company.local and server2.company.local)
    i followed the steps described in this article http://www.sugarcrm.com/forums/f115/...008-etc-59701/ after failing to install it using the SQL Server stack.

    Our SQL server is 2008 R2 Standard Edition. IIS7, PHP 5.3 and SugarCE 6.4.2
    The error message i am getting everytime is "The provided database host, username, and/or password is invalid, and a connection to the database could not be established. Please enter a valid host, username and password
    * Required field"
    I tried everything, the IP, the server FQDN, leaving the instance empty, switching to another instance of SQLSERVER EXPRESS.... nothing works.
    Note that running the following script works and shows results, so i don't think that the SQL Server 2008 client is not installed properly.

    Installed PHP Extensions:
    php_curl
    php_mbstring
    php_pdo_sqlsrvr
    php_pdo_sqlsrvr_53_nts
    php_pdo_sqlsrvr_53_ts
    php_soap
    php_sqlsrvr
    php_sqlsrvr_53_nts
    php_sqlsrvr_53_ts
    php_tidy
    php_wincache

    Code:
    <?php
       $serverName = "192.168.10.2"; 
       $database = "sugarcrm_db";
    
       // Get UID and PWD from application-specific files. 
       $uid = someusername;
       $pwd = somepassword;
    
       try {
          $conn = new PDO( "sqlsrv:server=$serverName;Database = $database", $uid, $pwd); 
          $conn->setAttribute( PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION ); 
       }
    
       catch( PDOException $e ) {
          die( "Error connecting to SQL Server" ); 
       }
    
       echo "Connected to SQL Server\n";
    
       $query = 'select * from contacts'; 
       $stmt = $conn->query( $query ); 
       while ( $row = $stmt->fetch( PDO::FETCH_ASSOC ) ){ 
          print_r( $row ); 
       }
    
       // Free statement and connection resources. 
       $stmt = null; 
       $conn = null; 
    ?>

  2. #2
    Angel's Avatar
    Angel is offline Sugar Community Member
    Join Date
    Jul 2005
    Location
    Los Angeles
    Posts
    5,188

    Default Re: Sugar CRM Community edition install on IIS7, Windows 2008 and Remote SQL Server 2

    This combination can be a bit finicky at times, but the good news is that you appear to have all the right pieces on your system. Some minor adjustments should help get you going.

    Sugar will use the MS provided MS-SQL driver for PHP (php_sqlsvr). Given that you are using IIS, you need to use the non-thread safe one (nts). Your message indicates both are installed, you only need one. Remove the thread safe one and confirm that it is being loaded via phpinfo().

    Feel free to disable the PDO one while you are at it as Sugar won't use it (unless you need it for other purposes). Chances are that this change alone will kickstart it for you. If you still have problems, post the output of phpinfo() for us to inspect.
    Regards,

    Angel Magaņa
    Technical Solutions Architect
    Co-Author: Implementing SugarCRM 5.x (Packt Publishing -- Sept. 2010)
    Blog: http://cheleguanaco.blogspot.com.
    Twitter: @cheleguanaco.

  3. #3
    majdi.d is offline Junior Member
    Join Date
    Mar 2012
    Posts
    2

    Default Re: Sugar CRM Community edition install on IIS7, Windows 2008 and Remote SQL Server 2

    Quote Originally Posted by Angel View Post
    This combination can be a bit finicky at times, but the good news is that you appear to have all the right pieces on your system. Some minor adjustments should help get you going.

    Sugar will use the MS provided MS-SQL driver for PHP (php_sqlsvr). Given that you are using IIS, you need to use the non-thread safe one (nts). Your message indicates both are installed, you only need one. Remove the thread safe one and confirm that it is being loaded via phpinfo().

    Feel free to disable the PDO one while you are at it as Sugar won't use it (unless you need it for other purposes). Chances are that this change alone will kickstart it for you. If you still have problems, post the output of phpinfo() for us to inspect.
    just disabling unused dll's made it work. thanks a lot.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Problem with Sugar on Windows 2008 R2 Server with IIS7 and MS SqlServer 2005
    By LorenzoL in forum Installation and Upgrade Help
    Replies: 0
    Last Post: 2012-03-07, 02:50 PM
  2. Replies: 9
    Last Post: 2011-06-14, 08:34 PM
  3. Windows Server 2008 R2 with Remote SQL 2005 Documentation
    By slvrfxms@gmail.com in forum Installation and Upgrade Help
    Replies: 1
    Last Post: 2010-05-14, 04:33 PM
  4. SugarCE 5.2 - Windows 2008 - IIS7 - MYSQL - ERROR
    By Ledesma in forum Installation and Upgrade Help
    Replies: 11
    Last Post: 2009-09-14, 01:22 AM
  5. Windows Server 2008 & Sugar Upgrades
    By thowden in forum Installation and Upgrade Help
    Replies: 0
    Last Post: 2008-12-23, 08:09 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •