Solved

how to shrink MySQL DB

Posted on 2008-06-11
6
2,744 Views
Last Modified: 2008-09-18
I have a MySQL database running on Windows 2003.  It is rapidly occupying space on my server.  What is the best way to manage MySQL in order to purge data in order to reclaim space.  It should be noted that this MySQL is running InnoDB inside and therefore the standard 14 day purging of data does not reclaim any space since it puts all tables into one table space.  Thank you in advance
0
Comment
Question by:newtontech4
  • 2
6 Comments
 
LVL 4

Accepted Solution

by:
jojuez earned 250 total points
ID: 21769271
You may need to truncate your BIN logs. Are you backing up this server?
0
 
LVL 57

Expert Comment

by:giltjr
ID: 21769370
Can you identify what is exactly using the space?  Is it logs or is it the actual database/tablespace files?

If it is the actual tablespace files you should be able to reclaim space by doing reorgs regularly.
0
 

Author Comment

by:newtontech4
ID: 21769974
Hi giltjr - ibdata1 is growing the most.  I think this is due to the fact that InnoDB is being used.   This is a MySQL in my lab so i have not developed a back-up process yet.
0
 
LVL 57

Assisted Solution

by:giltjr
giltjr earned 250 total points
ID: 21772535
O.K.  Do a reorg is your  best bet for reclaiming space.  This is assuming that data is being purged/deleted.  If no data is being purged/delete, only added, then there is nothing you can do.  It will continue to get bigger and bigger.
0

Featured Post

The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

If your business is like most, chances are you still need to maintain a fax infrastructure for your staff. It’s hard to believe that a communication technology that was thriving in the mid-80s could still be an essential part of your team’s modern I…
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question