Bug #36439 Tablespace already exists err message noticed after RESTORE despite dropping TS
Submitted: 30 Apr 2008 19:02 Modified: 20 Oct 2008 8:53
Reporter: Hema Sridharan Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Server: Falcon storage engine Severity:S3 (Non-critical)
Version:mysql-6.0-backup OS:Linux
Assigned to: Sergey Vojtovich CPU Architecture:Any
Tags: F_TABLESPACE

[30 Apr 2008 19:02] Hema Sridharan
Description:
1) I create database .
2) I create tablespace and tables that specify tablespace.
3)I backup database, Drop database and tablespaces.
4) Now I perform Restore , I get message as tablespace already exists although I  dropped the tablespace before Restore.

How to repeat:
CREATE DATABASE bup_ts;
USE bup_ts;

#Create tablespace, tables and load with data.

CREATE TABLESPACE hb1 ADD DATAFILE 'x' ENGINE=FALCON;
CREATE TABLESPACE hb2 ADD DATAFILE 'y' ENGINE=FALCON;
CREATE TABLE t2(id int, details char(40))ENGINE=FALCON TABLESPACE hb1;
CREATE TABLE t3(id int, details char(20))ENGINE=FALCON TABLESPACE hb2;

INSERT INTO t2 VALUES(1,'tablespace hb1'),(2, 'tablespace hb1');
INSERT INTO t3 VALUES(1, 'tablespace hb2'),(2, 'tablespace hb2')

BACKUP DATABASE bup_ts TO 'bup_ts.bak';

DROP DATABASE bup_ts;

DROP TABLESPACE hb1 ENGINE=FALCON;

DROP TABLESPACE hb2 ENGINE=FALCON;

RESTORE FROM 'bup_ts.bak';

Gives me the following message!
At line 89: query 'RESTORE FROM 'bup_ts.bak'' failed: 1666: Tablespace 'hb1' already exists
[1 May 2008 7:15] Sveta Smirnova
Thank you for the report.

Verified as described.
[5 May 2008 18:16] Kevin Lewis
Ann, please make sure the database and tablespace is really gone.
[16 Oct 2008 16:59] Kevin Lewis
Sergey, Here is another tablespace related bug that was switched to SR60BETA
[20 Oct 2008 8:53] Sveta Smirnova
Bug is not repeatable for me with current BZR trees (main and falcon team)
[20 Oct 2008 8:54] Sergey Vojtovich
Was unable to repeat with current sources. There were a lot of changes around tablespaces code since April.