Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Problems installing 2.0.16 on W2K3

edited December 2010 in Vanilla 2.0 - 2.8
Environment W2k3, IIS 6
php 5.3
MySQL 5.1
VF installed off root in /private

When I access my site www.xxx.com/private I get the installer page. I complete the dbhost as localhost and all the other info. On clicking Continue-> it creates the database containing 25 tables. However, the installer page reappears. If I retype the homepage i get BONK.

The config.php is

<?php if (!defined('APPLICATION')) exit();

// Garden
$Configuration['Garden']['Installed'] = TRUE;
$Configuration['Garden']['Errors']['MasterView'] = 'error.master.php';

which seems a bit scarce. It has created the file, added some stuff, but shouldnt there be more info in there?

Commenting out the error-handler and trying again reveals

Fatal Error in Gdn_Database.Connection();

An error occurred while attempting to connect to the database
SQLSTATE[HY000] [2005] Unknown MySQL server host 'dbhost' (11004)
The error occurred on or near: C:\Inetpub\wwwroot\private\library\database\class.database.php

Can anyone help me with this problem? What is going wrong?

BTW the same server is running vB without issue.
Tagged:

Comments

  • Please edit the conf/config.php to say $Configuration['Garden']['Errors']['MasterView'] = 'deverror.master.php'; and post the error that you get (instead of the Bonk screen) here. I assume it's because it tries to create the User with UserID = 1 twice, MySQL throws an error and you get the Bonk screen.

    Still, that does not solve the initial problem with you getting the same page after installing.

    /cd
  • I gave a snippet in OP. But here is the full message:

    Fatal Error in Gdn_Database.Connection();

    An error occurred while attempting to connect to the database
    SQLSTATE[HY000] [2005] Unknown MySQL server host 'dbhost' (11004)
    The error occurred on or near: C:\Inetpub\wwwroot\private\library\database\class.database.php
    56: $this->_Connection = new PDO(strtolower($this->Engine) . ':' . $this->Dsn, $this->User, $this->Password, $this->ConnectionOptions);
    57: if($this->ConnectionOptions[1002])
    58: $this->Query($this->ConnectionOptions[1002]);
    59: } catch (Exception $ex) {
    60: trigger_error(ErrorMessage('An error occurred while attempting to connect to the database', $this->ClassName, 'Connection', $ex->getMessage()), E_USER_ERROR);
    61: }
    62: }
    63:
    64: return $this->_Connection;
    Backtrace:
    C:\Inetpub\wwwroot\private\library\database\class.database.phpPHP::Gdn_ErrorHandler();
    [C:\Inetpub\wwwroot\private\library\database\class.database.php:60] PHP::trigger_error();
    [C:\Inetpub\wwwroot\private\library\database\class.database.php:232] Gdn_Database->Connection();
    [C:\Inetpub\wwwroot\private\library\database\class.sqldriver.php:1584] Gdn_Database->Query();
    [C:\Inetpub\wwwroot\private\library\database\class.sqldriver.php:639] Gdn_SQLDriver->Query();
    [C:\Inetpub\wwwroot\private\applications\dashboard\models\class.permissionmodel.php:362] Gdn_SQLDriver->Get();
    [C:\Inetpub\wwwroot\private\applications\dashboard\models\class.permissionmodel.php:117] PermissionModel->PermissionColumns();
    [C:\Inetpub\wwwroot\private\applications\dashboard\models\class.usermodel.php:80] PermissionModel->CachePermissions();
    [C:\Inetpub\wwwroot\private\library\core\class.session.php:291] UserModel->DefinePermissions();
    [C:\Inetpub\wwwroot\private\library\core\class.auth.php:27] Gdn_Session->Start();
    [C:\Inetpub\wwwroot\private\bootstrap.php:170] Gdn_Auth->StartAuthenticator();
    [C:\Inetpub\wwwroot\private\index.php:28] PHP::require_once();
    Variables in local scope:
    [ex] array (
    'errorInfo' => NULL,
    )
    Need Help?
    If you are a user of this website, you can report this message to a website administrator.
    If you are an administrator of this website, you can get help at the Vanilla Community Forums.
    Additional information for support personnel:
    Application: Vanilla
    Application Version: 2.0.16
    PHP Version: 5.2.13
    Operating System: WINNT
    Server Software: Microsoft-IIS/6.0
    User Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10
    Request Uri: /private/
    Controller: Gdn_Database
    Method: Connection
  • TimTim Vanilla Staff
    It seems like you were heading in the right direction when you noticed how small the config file was. You're correct to assume that there should be additional information in there... such as your DB connection information. The mysql error you're seeing is just a side effect of the software not knowing your connection info and using the default "dbhost".

    Is it possible that something is overwriting that file, or preventing it from being written?
    Perhaps you could try adding the following line to somewhere near the top of index.php:

    define('DEBUG', TRUE);

    Then re-run the installer (by deleting the config.php file).

    Vanilla Forums COO [GitHub, Twitter, About.me]

  • Thx Tim,

    I added your code to both index.php and bootstrap.php. I deleted the config. I deleted cache. I ensured Avast antivirus services were stopped. For good measure I also set NTFS permissions for the whole directory tree to Everyone-FULL.

    Re-ran the installer. Same result.

    Config is created but no more than in OP.

    Here is a dump of another file created by the installer, library_map.ini

    [library]
    dashboard/modules/class__headmodule__php = "C:\Inetpub\wwwroot\private/applications/dashboard/modules/class.headmodule.php"
    class__configurationmodel__php = "C:\Inetpub\wwwroot\private/library/core/class.configurationmodel.php"
    class__phpmailer__php = "C:\Inetpub\wwwroot\private/library/vendors/phpmailer/class.phpmailer.php"
    class__passwordhash__php = "C:\Inetpub\wwwroot\private/library/core/class.passwordhash.php"

    Are those paths legit? Swapping between \ and /?

    Stumped.
  • Can someone pls post their working config.php? Of course, replace your confidential data with xxx. I can then manually edit the config.php with my details, and hopefully get this thing working.
  • edited December 2010
    Thx cdavid,

    With the manual edit config.php I got it working. I could start posting, and I could create users. But then I tried creating a catagory and...

    [quote]
    Fatal Error in PermissionModel.GetAllowedPermissionNamespaces();

    Invalid argument supplied for foreach()
    The error occurred on or near: C:\Inetpub\wwwroot\private\applications\dashboard\models\class.permissionmodel.php
    96: $ApplicationManager = new Gdn_ApplicationManager();
    97: $EnabledApplications = $ApplicationManager->EnabledApplications();
    98:
    99: $PluginNamespaces = array();
    100: foreach(Gdn::PluginManager()->EnabledPlugins as $Plugin) {
    101: if(!array_key_exists('RegisterPermissions', $Plugin) || !is_array($Plugin['RegisterPermissions']))
    102: continue;
    103: foreach($Plugin['RegisterPermissions'] as $PermissionName) {
    104: $Namespace = substr($PermissionName, 0, strrpos($PermissionName, '.'));
    [/quote]

    So it seems there are more issues. Thx for your help so far, but I will drop VF. I have vB running smoothly on this same server... At this time, I can't invest so much setup/debug time and have to call on the community just to get the basics working. I'll go with another instance of vB for the second forum. :(
  • *update*

    I just installed phpBB3.0.8 on this same server just to double check if there were indeed issues with the server.

    None. Easy install. phpBB up and running.

    I suggest that VF implements an installer similar to the new installer in phpBB3. It's very good. And the diagnostics would help track down where the problems could be.

    I have so say I remain stumped why vB and phpBB install without hitch on my server, but VF won't. It's a shame, I would have loved to get it working.
Sign In or Register to comment.