Database Update/Install Failed!



  • [SIZE=5][B]Hi,[/B][/SIZE]

    my fog-server trunk build 2109 on Ubuntu 14.04 LTS 64bit throws error:

    [SIZE=5][B][code][/B][/SIZE]

    [SIZE=5][B]Open Source Computer Cloning Solution[/B][/SIZE]

    [SIZE=5][B]Database Schema Installer / Updater[/B][/SIZE]
    [SIZE=5][B]Update/Install Failed![/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][SIZE=5][B]The following errors occured[/B][/SIZE][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Update ID:[/B] 1 - 0[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database Error:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database SQL:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B]CREATE DATABASE fog[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Update ID:[/B] 1 - 1[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database Error:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database SQL:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B]CREATE TABLE fog.groupMembers ([/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] gmID int(11) NOT NULL auto_increment,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] gmHostID int(11) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] gmGroupID int(11) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] PRIMARY KEY (gmID),[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] KEY new_index (gmHostID),[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] KEY new_index1 (gmGroupID)[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] ) ENGINE=MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Update ID:[/B] 1 - 2[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database Error:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database SQL:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B]CREATE TABLE fog.groups ([/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] groupID int(11) NOT NULL auto_increment,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] groupName varchar(50) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] groupDesc longtext NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] groupDateTime datetime NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] groupCreateBy varchar(50) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] groupBuilding int(11) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] PRIMARY KEY (groupID),[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] KEY new_index (groupName)[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] ) ENGINE=MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=latin1[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Update ID:[/B] 1 - 3[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database Error:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database SQL:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B]CREATE TABLE fog.history ([/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hID int(11) NOT NULL auto_increment,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hText longtext NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hUser varchar(200) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hTime datetime NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hIP varchar(50) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] PRIMARY KEY (hID)[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] ) ENGINE=MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=latin1[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Update ID:[/B] 1 - 4[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database Error:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][B]Database SQL:[/B][/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B]CREATE TABLE fog.hosts ([/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hostID int(11) NOT NULL auto_increment,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hostName varchar(16) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hostDesc longtext NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hostIP varchar(25) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hostImage int(11) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hostBuilding int(11) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hostCreateDate datetime NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B] hostCreateBy varchar(50) NOT NULL,[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B]…[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B]…[/B][/SIZE][/B][/SIZE]
    [SIZE=5][B][SIZE=5][B][/code][/B][/SIZE]
    [SIZE=5][B]Please help me and give me any hints then I solve this problem.[/B][/SIZE]
    [SIZE=5][B]Thank you and many greetings.[/B][/SIZE]


  • Senior Developer

    [quote=“Oma Voss, post: 34671, member: 22725”]Hi Junkhacker,

    it was unsuccessfully …[/quote]

    Can you give more information than, it was unsuccessful? Perhaps some log information? Maybe your mysql log file? Maybe the apache error logs?

    How does it fail, does it give any messages of any use?



  • Hi Junkhacker,

    it was unsuccessfully …


  • Developer

    is the value
    ’DATABASE_PASSWORD’, ‘51d86d’
    correct?
    if you did not set a password when you installed, try this
    ’DATABASE_PASSWORD’, ‘’



  • [code]
    <?php
    /**

    • Class Name: Config
    • Initializes default settings.
    • Most notably the sql connection.
      /
      class Config
      {
      /
      *
      • Calls the required functions to define the settings.
      • method db_settings()
      • method svc_setting()
      • method init_setting()
        /
        public function __construct()
        {
        self::db_settings();
        self::svc_setting();
        self::init_setting();
        }
        /
        *
      • db_settings()
      • Defines the database settings for FOG
      • @return void
        /
        private static function db_settings()
        {
        define(‘DATABASE_TYPE’, ‘mysql’); // mysql or oracle
        define(‘DATABASE_HOST’, ‘localhost’);
        define(‘DATABASE_NAME’, ‘fog’);
        define(‘DATABASE_USERNAME’, ‘root’);
        define(‘DATABASE_PASSWORD’, ‘51d86d’);
        }
        /
        *
      • svc_setting()
      • Defines the service settings.
      • (e.g. FOGMulticastManager,
      •   FOGScheduler,
        
      •   FOGImageReplicator)
        
      • @return void
        /
        private static function svc_setting()
        {
        define( “UDPSENDERPATH”, “/usr/local/sbin/udp-sender” );
        define( “MULTICASTLOGPATH”, “/opt/fog/log/multicast.log” );
        define( “MULTICASTDEVICEOUTPUT”, “/dev/tty2” );
        define( “MULTICASTSLEEPTIME”, 10 );
        define( “MULTICASTINTERFACE”, “eth0” );
        define( “UDPSENDER_MAXWAIT”, null );
        define( “LOGMAXSIZE”, “1000000” );
        define( “REPLICATORLOGPATH”, “/opt/fog/log/fogreplicator.log” );
        define( “REPLICATORDEVICEOUTPUT”, “/dev/tty3” );
        define( “REPLICATORSLEEPTIME”, 600 );
        define( “REPLICATORIFCONFIG”, “/sbin/ifconfig” );
        define( “SCHEDULERLOGPATH”, “/opt/fog/log/fogscheduler.log” );
        define( “SCHEDULERDEVICEOUTPUT”, “/dev/tty4” );
        define( “SCHEDULERSLEEPTIME”, 60 );
        }
        /
        *
      • init_setting()
      • Initial values if fresh install are set here
      • NOTE: These values are only used on initial
      • installation to set the database values.
      • If this is an upgrade, they do not change
      • the values within the Database.
      • Please use FOG Configuration->FOG Settings
      • to change these values after everything is
      • setup.
      • @return void
        */
        private static function init_setting()
        {
        define(‘TFTP_HOST’, “192.168.115.20”);
        define(‘TFTP_FTP_USERNAME’, “fog”);
        define(‘TFTP_FTP_PASSWORD’, “password”);
        define(‘TFTP_PXE_KERNEL_DIR’, ‘/var/www/fog/service/ipxe/’);
        define(‘PXE_KERNEL’, ‘bzImage’);
        define(‘PXE_KERNEL_RAMDISK’,127000);
        define(‘USE_SLOPPY_NAME_LOOKUPS’,true);
        define(‘MEMTEST_KERNEL’, ‘memtest.bin’);
        define(‘PXE_IMAGE’, ‘init.xz’);
        define(‘PXE_IMAGE_DNSADDRESS’, “192.168.115.5”);
        define(‘STORAGE_HOST’, “192.168.115.20”);
        define(‘STORAGE_FTP_USERNAME’, “fog”);
        define(‘STORAGE_FTP_PASSWORD’, “password”);
        define(‘STORAGE_DATADIR’, ‘/images/’);
        define(‘STORAGE_DATADIR_UPLOAD’, ‘/images/dev/’);
        define(‘STORAGE_BANDWIDTHPATH’, ‘/fog/status/bandwidth.php’);
        define(‘UPLOADRESIZEPCT’,5);
        define(‘WEB_HOST’, “192.168.115.20”);
        define(‘WOL_HOST’, “192.168.115.20”);
        define(‘WOL_PATH’, ‘/fog/wol/wol.php’);
        define(‘WOL_INTERFACE’, “eth0”);
        define(‘SNAPINDIR’, “/opt/fog/snapins/”);
        define(‘QUEUESIZE’, ‘10’);
        define(‘CHECKIN_TIMEOUT’,600);
        define(‘USER_MINPASSLENGTH’,4);
        define(‘USER_VALIDPASSCHARS’, ‘1234567890ABCDEFGHIJKLMNOPQRSTUVWZXYabcdefghijklmnopqrstuvwxyz_()^!#-’);
        define(‘NFS_ETH_MONITOR’, “eth0”);
        define(‘UDPCAST_INTERFACE’, “eth0”);
        define(‘UDPCAST_STARTINGPORT’, 63100 ); // Must be an even number! recommended between 49152 to 65535
        define(‘FOG_MULTICAST_MAX_SESSIONS’,64);
        define(‘FOG_JPGRAPH_VERSION’, ‘2.3’);
        define(‘FOG_REPORT_DIR’, ‘./reports/’);
        define(‘FOG_UPLOADIGNOREPAGEHIBER’,true);
        define(‘FOG_DONATE_MINING’, “0”);
        }
        }
        [/code]


  • guenter@FOG-Server:~$ service mysql restart
    stop: Unbekannter Auftrag: mysql
    start: Unbekannter Auftrag: mysql
    guenter@FOG-Server:~$


  • Developer

    correction [SIZE=13px][FONT=arial][COLOR=#262626]/var/www/fog/lib/fog/Config.class.php[/COLOR][/FONT][/SIZE]


  • Developer

    did you try tamatech’s suggestion and restart the mysql service?
    it looks like either the mysql service isn’t running, or perhaps the password is incorrect for mysql in the config file (fog/service/etc/config.php)



  • Hi Junkhacker,

    I do not know anymore.
    Maybe I should better remove the trunk by the system and install a stable version. How do I do that?

    Many greetings and thanks.


  • Developer

    he was asking what version you had installed before you upgraded to 2109



  • Hi need2,
    rev. 2109 from trunk:
    [url]https://svn.code.sf.net/p/freeghost/code/trunk[/url]


  • Moderator

    What revision were you updating from?


  • Developer

    Does “service mysql restart” bring the login page up?



  • Size comes from c&p from Browser, sorry …


Log in to reply
 

366
Online

38982
Users

10712
Topics

101677
Posts

Looks like your connection to FOG Project was lost, please wait while we try to reconnect.