Looking for a better way to optimize DB

On all my systems I’ve had problems with mySQL using a lot of resources. Anyway I was trying to do an optimize on a database which is 2GB. Once it gets to my largest table everything just stops working that’s mySQL related and the server slows down. I left the table optimizing overnight (7 or 8 hours) and it didn’t even finish. Just in the same spot. Any alternate way to do this or do I need like 6 cores to use mySQL properly?

Howdy,

Well, 2GB is a large database, but that should work… how much RAM do you have on your server? You can determine that by running “free -m”.

-Eric

I have 4GB DDR3 RAM usually using 600mb for the webserver.

Could it be that my /tmp is less than 2GB? I’m not sure how to increase partitions but I’d rather just use a standard folder for it and not a partition like my other system.

It’s unlikely to be related to your /tmp partition size, as it shouldn’t ever need to put your table data in /tmp.

Though, you could verify that by monitoring the command “df -h” while optimizing your database, that will show how much free space is available on your various partitions.

-Eric