View Full Version : How to flush tables ?
Sharg
Mon 19th Feb '01, 7:53pm
Before running a myisamchk I need to "flush tables".
Should I run the flush command WHILE the mysql daemon is running, or after its shut down ?
Thanks,
Mitrofan
Tue 20th Feb '01, 11:28am
If you shut down mysql you will not be able to run commands on it.
You may want to shut down Apache to prevent any changes made to mySQL while you doing the maintainence.
The only time I shut down mySQL is when I want to backup the database with the tar utility.
When I want to do any kind of mainainence, including mysqldump, I just shut down Apache.
Sharg
Tue 20th Feb '01, 12:00pm
You may want to shut down Apache to prevent any changes made to mySQL
Hey great idea to shut down apache when you want radically no mysql change, I'll do that now ;)
Mitrofan
Tue 20th Feb '01, 12:08pm
Yes, this way I know that no users are connected to mySQL and therefore no changes are being made to my database and I can safely do maintainence.
After I'm done doing mysqldump, I just start up Apache again. This usually only take under 5 minutes of webserver downtime.
Chris Schreiber
Tue 20th Feb '01, 12:43pm
The command is:
mysqladmin -uuser -p flush-tables
It should just return you to a command line again, almost instantly.
Sharg
Tue 20th Feb '01, 12:54pm
Chris is back !! Chris is back :))
Thanks,
Chris Schreiber
Tue 20th Feb '01, 1:01pm
Originally posted by Sharg
Chris is back !! Chris is back :))
LOL Yes sorry I haven't been around too much lately.
Thanks,
Anytime :)
vBulletin® v3.8.0 Beta 3, Copyright ©2000-2008, Jelsoft Enterprises Ltd.