Announcement

Collapse
No announcement yet.

Problems on MySQL restore

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Problems on MySQL restore

    MySQL source machine: Server version: 5.0.51-log MySQL Community Edition (GPL)
    MySQL destination machine: Server version: 5.0.77 Source distribution

    I performed this command:

    mysqldump --all-databases > backup.sql
    Then gzipped it and transferred it to the new server. No problems so far.

    When I try to restore from the command line as per normal:

    mysql -p < backup.sql
    I get this error message after a while:

    ERROR 2005 (HY000) at line 9393: Unknown MySQL server host 'won't' (1)
    Searching the backup file in vi shows zero instances of the string "won't", and line 9393 is this:

    SET character_set_client = @saved_cs_client;

    In context, that's:
    Code:
    `votedate` int(10) unsigned NOT NULL default '0',
      `voteoption` int(10) unsigned NOT NULL default '0',
      `votetype` int(10) unsigned NOT NULL default '0',
      PRIMARY KEY  (`pollvoteid`),
      UNIQUE KEY `pollid` (`pollid`,`userid`,`votetype`),
      KEY `userid` (`userid`)
    ) ENGINE=MyISAM AUTO_INCREMENT=782493 DEFAULT CHARSET=latin1;
    SET character_set_client = @saved_cs_client;
    
    --
    -- Dumping data for table `pollvote`
    --
    
    LOCK TABLES `pollvote` WRITE;
    /*!40000 ALTER TABLE `pollvote` DISABLE KEYS */;
    @
    @
    @
    @
    @
    @
    @
    @
    Trying it another way, I can open mysql and issue the command:

    source /path/to/backup.sql

    This chugs along for a while, then gets stuck in a loop reporting this:

    No connection. Trying to reconnect...
    ERROR 2005 (HY000): Unknown MySQL server host 'Tuckerrn2337' (1)
    ERROR:
    Can't connect to the server
    Now, I'd think Tuckerrn2337 would be a username, but I'm not seeing it in the vBulletin install. I'm not seeing it when I search the .sql file either.

    I'm at a loss here. Any idea what I'm doing wrong?
    The High Road

  • #2
    Here is the command I use to backup. Replace user, password and vbulletin_current_db_name as needed.

    mysqldump --opt -uuser –ppassword vbulletin_current_db_name > backup.sql

    Herer is the command I use to restore. Create a new database and replace vbulletin_new_db_name as needed.

    mysql –p vbulletin_new_db_name < backup.sql

    Comment


    • #3
      So I ran it again on a Windows machine running MySQL 5.5 and it went through cleanly.

      I wonder if it's an issue with the MySQL version, or possibly that I've got replication turned on?

      I'll keep looking at it.
      The High Road

      Comment


      • #4
        Looks like the MySQL version direct from MySQL.com/Oracle worked fine where the one from the yum repository was failing. Now, to research whether that's something I want to deal with or not.

        Still doesn't make any sense to me, though.

        Thanks.
        The High Road

        Comment

        widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
        Working...
        X