enterprise-support team mailing list archive
-
enterprise-support team
-
Mailing list archive
-
Message #03986
[Bug 1399562] [NEW] Optimize table removes the data directory in partitions
Public bug reported:
nilnandan@Dell-XPS:~$ mysql -uroot -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 38
Server version: 5.6.21-70.1 Percona Server (GPL), Release 70.1, Revision 698
Copyright (c) 2009-2014 Percona LLC and/or its affiliates
Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input
statement.
mysql> use test
Database changed
mysql>
mysql> CREATE TABLE `TEST` (
-> `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
-> `a2` mediumtext NOT NULL,
-> `a3` char(100) NOT NULL,
-> `prt` tinyint(1) unsigned NOT NULL,
-> PRIMARY KEY (`id`,`prt`)
-> ) ENGINE=InnoDB AUTO_INCREMENT=0 DEFAULT CHARSET=latin1 ROW_FORMAT=FIXED
-> /*!50100 PARTITION BY LIST (`prt`)
-> (PARTITION p0 VALUES IN (0) ENGINE = InnoDB,
-> PARTITION p1 VALUES IN (1) DATA DIRECTORY = '/tmp' ENGINE = InnoDB) */;
Query OK, 0 rows affected, 2 warnings (0.08 sec)
mysql> show warnings;
+---------+------+--------------------------------------+
| Level | Code | Message |
+---------+------+--------------------------------------+
| Warning | 1478 | InnoDB: assuming ROW_FORMAT=COMPACT. |
| Warning | 1478 | InnoDB: assuming ROW_FORMAT=COMPACT. |
+---------+------+--------------------------------------+
2 rows in set (0.00 sec)
mysql> show create table TEST \G
*************************** 1. row ***************************
Table: TEST
Create Table: CREATE TABLE `TEST` (
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`a2` mediumtext NOT NULL,
`a3` char(100) NOT NULL,
`prt` tinyint(1) unsigned NOT NULL,
PRIMARY KEY (`id`,`prt`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ROW_FORMAT=FIXED
/*!50100 PARTITION BY LIST (`prt`)
(PARTITION p0 VALUES IN (0) ENGINE = InnoDB,
PARTITION p1 VALUES IN (1) DATA DIRECTORY = '/tmp' ENGINE = InnoDB) */
1 row in set (0.00 sec)
mysql> OPTIMIZE TABLE TEST;
+-----------+----------+----------+-------------------------------------------------------------------+
| Table | Op | Msg_type | Msg_text |
+-----------+----------+----------+-------------------------------------------------------------------+
| test.TEST | optimize | note | Table does not support optimize, doing recreate + analyze instead |
| test.TEST | optimize | status | OK |
+-----------+----------+----------+-------------------------------------------------------------------+
2 rows in set, 2 warnings (0.16 sec)
mysql> show create table TEST \G
*************************** 1. row ***************************
Table: TEST
Create Table: CREATE TABLE `TEST` (
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`a2` mediumtext NOT NULL,
`a3` char(100) NOT NULL,
`prt` tinyint(1) unsigned NOT NULL,
PRIMARY KEY (`id`,`prt`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ROW_FORMAT=FIXED
/*!50100 PARTITION BY LIST (`prt`)
(PARTITION p0 VALUES IN (0) ENGINE = InnoDB,
PARTITION p1 VALUES IN (1) ENGINE = InnoDB) */
1 row in set (0.00 sec)
mysql>
** Affects: mysql-server
Importance: Unknown
Status: Unknown
** Affects: percona-server
Importance: Undecided
Status: Confirmed
** Affects: percona-server/5.6
Importance: Undecided
Status: Confirmed
** Tags: 5.6.21 upstream
** Bug watch added: MySQL Bug System #75112
http://bugs.mysql.com/bug.php?id=75112
** Also affects: mysql-server via
http://bugs.mysql.com/bug.php?id=75112
Importance: Unknown
Status: Unknown
** Changed in: percona-server
Status: New => Confirmed
--
You received this bug notification because you are a member of Ubuntu
Server/Client Support Team, which is subscribed to MySQL.
Matching subscriptions: Ubuntu Server/Client Support Team
https://bugs.launchpad.net/bugs/1399562
Title:
Optimize table removes the data directory in partitions
To manage notifications about this bug go to:
https://bugs.launchpad.net/mysql-server/+bug/1399562/+subscriptions
Follow ups
References