Welcome to the dBforums forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions, articles and access our other FREE features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload your own photos and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact support.

If you prefer not to see double-underlined words and corresponding ads, place your cursor
here for ContentLink opt out.

Go Back  dBforums > Database Server Software > MySQL > Is it possible to compact an Innodb Table?

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 12-09-03, 07:05
acivita acivita is offline
Registered User
 
Join Date: Dec 2003
Posts: 2
Is it possible to compact an Innodb Table?

hi
i have a mysql 4.0.16 db with innodb tables...
the database tables are frequently updated by deleting all data and putting in new data every 15 minutes..
in this situation the database size is 13 GB instead of 3 Gb as should be? is there a way to compact the Innodb tables?
i've fund a tool only for myisam such as myisamchk..
Thank you
Reply With Quote
  #2 (permalink)  
Old 12-09-03, 09:36
omiossec omiossec is offline
Registered User
 
Join Date: Jan 2003
Location: Paris, France
Posts: 320
There is no tool like this cause INNODB use a table space instead of multiple files.

But you can use this simple tech to defrag your tables and speed up you indices

Dump your data to a text file
drop the table
recreate it and import you data

You can also use

ALTER TABLE yourtablename TYPE=InnoDB
__________________
Olivier Miossec
--
http://www.lasso-developpeur.net/
--
Reply With Quote
  #3 (permalink)  
Old 12-09-03, 09:56
acivita acivita is offline
Registered User
 
Join Date: Dec 2003
Posts: 2
Innodb

well thx..
i've noticed that on /var/lib/mysql there are many file in this format:
machinename-bin.001 to 00n...
each file has many MB size..but what are these files?
i've 23 files of that type..and i've deleted the first 21 ..and restarted mysql and all seems to work fine? is it possible to avoid the creation of such files? or is there a way to tell mysql to cancel them automatically?
thx
Reply With Quote
  #4 (permalink)  
Old 12-09-03, 14:13
omiossec omiossec is offline
Registered User
 
Join Date: Jan 2003
Location: Paris, France
Posts: 320
Red face

thas was your transaction logs or your data

You can configure how many file can be used by INNODB
in MySql Start up option

http://www.lasso-developpeur.net/us/...o?id=22&tab=db
__________________
Olivier Miossec
--
http://www.lasso-developpeur.net/
--
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On