Wednesday, September 19, 2012

Recreate SA database



Hello Rob,

I can't get any of the repair functions to pick this up either. What I would like you to do now is make a backup of the database by making a copy of D:\netqos\mysql51\data\super in another location. After that, I would like you to connect to mysql via mysql -P3308 super and then run the following command:

drop table runs2;

If this fails don't worry about it as it may not be able to see the table anyway. After this, please run the following to recreate the table:

CREATE TABLE `runs2` (
  `PROBE_ID` int(10) unsigned NOT NULL DEFAULT '0',
  `FEED_INDEX` tinyint(3) unsigned NOT NULL DEFAULT '0',
  `SOURCE_ID` smallint(5) unsigned NOT NULL DEFAULT '0',
  `APP_ID` int(10) unsigned NOT NULL DEFAULT '0',
  `SERVER_ID` int(10) unsigned NOT NULL DEFAULT '0',
  `TIME_END` int(11) NOT NULL DEFAULT '0',
  `CLIENT_ADDRESS` int(10) unsigned NOT NULL DEFAULT '0',
  `CLIENT_MASK` int(10) unsigned NOT NULL DEFAULT '0',
  `CLIENT_ID` int(10) unsigned NOT NULL DEFAULT '0',
  `DET_CLASS` int(10) unsigned NOT NULL DEFAULT '0',
  `DET_MASK` int(10) unsigned NOT NULL DEFAULT '0',
  `DETAIL1` int(10) unsigned DEFAULT NULL,
  `DETAIL2` int(10) unsigned DEFAULT NULL,
  `DETAIL3` int(10) unsigned DEFAULT NULL,
  `DETAIL4` int(10) unsigned DEFAULT NULL,
  `DETAIL5` int(10) unsigned DEFAULT NULL,
  `DETAIL6` int(10) unsigned DEFAULT NULL,
  `DETAIL7` int(10) unsigned DEFAULT NULL,
  `DETAIL8` int(10) unsigned DEFAULT NULL,
  `APP1_COUNT` float NOT NULL DEFAULT '0',
  `APP1_SUM` float NOT NULL DEFAULT '0',
  `APP2_COUNT` float NOT NULL DEFAULT '0',
  `APP2_SUM` float NOT NULL DEFAULT '0',
  `APP3_COUNT` float NOT NULL DEFAULT '0',
  `APP3_SUM` float NOT NULL DEFAULT '0',
  `APP4_COUNT` float NOT NULL DEFAULT '0',
  `APP4_SUM` float NOT NULL DEFAULT '0',
  `APP5_COUNT` float NOT NULL DEFAULT '0',
  `APP5_SUM` float NOT NULL DEFAULT '0',
  `APP6_COUNT` float NOT NULL DEFAULT '0',
  `APP6_SUM` float NOT NULL DEFAULT '0',
  `APP7_COUNT` float NOT NULL DEFAULT '0',
  `APP7_SUM` float NOT NULL DEFAULT '0',
  `APP8_COUNT` float NOT NULL DEFAULT '0',
  `APP8_SUM` float NOT NULL DEFAULT '0',
  `APP9_COUNT` float NOT NULL DEFAULT '0',
  `APP9_SUM` float NOT NULL DEFAULT '0',
  `APP10_COUNT` float NOT NULL DEFAULT '0',
  `APP10_SUM` float NOT NULL DEFAULT '0',
  `APP11_COUNT` float NOT NULL DEFAULT '0',
  `APP11_SUM` float NOT NULL DEFAULT '0',
  `MAINTENANCE` int(11) NOT NULL DEFAULT '0',
  KEY `TIME_END` (`TIME_END`),
  KEY `APP` (`APP_ID`,`TIME_END`),
  KEY `SERVER` (`SERVER_ID`,`TIME_END`),
  KEY `CLIENTS` (`CLIENT_ADDRESS`,`TIME_END`),
  KEY `CLIENT_ID` (`CLIENT_ID`,`TIME_END`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY RANGE (time_end)
(PARTITION p20120823_12h17m37 VALUES LESS THAN (1345738657) ENGINE = MyISAM,  PARTITION p20120826_02h17m37 VALUES LESS THAN (1345961857) ENGINE = MyISAM,  PARTITION p20120828_16h17m37 VALUES LESS THAN (1346185057) ENGINE = MyISAM,  PARTITION p20120831_06h17m37 VALUES LESS THAN (1346408257) ENGINE = MyISAM,  PARTITION p20120902_20h17m37 VALUES LESS THAN (1346631457) ENGINE = MyISAM,  PARTITION p20120905_10h17m37 VALUES LESS THAN (1346854657) ENGINE = MyISAM,  PARTITION p20120908_00h17m37 VALUES LESS THAN (1347077857) ENGINE = MyISAM,  PARTITION p20120910_14h17m37 VALUES LESS THAN (1347301057) ENGINE = MyISAM,  PARTITION p20120913_04h17m37 VALUES LESS THAN (1347524257) ENGINE = MyISAM,  PARTITION p20120915_18h17m37 VALUES LESS THAN (1347747457) ENGINE = MyISAM,  PARTITION p20120918_08h17m37 VALUES LESS THAN (1347970657) ENGINE = MyISAM,  PARTITION p20120920_22h17m37 VALUES LESS THAN (1348193857) ENGINE = MyISAM,  PARTITION pMaxValues VALUES LESS THAN MAXVALUE ENGINE = MyISAM) */;
/*!40101 SET character_set_client = @saved_cs_client */;

This should generate the new table for you with the needed configuration.
Please let me know if this takes care of the issue. Please let me know if there is anything else that we can assist you with in the meantime.

No comments:

Post a Comment