Hello all,

As I have written about in two earlier threads this week (you can read
them in the mysql.com archives at these URLs:

http://lists.mysql.com/cgi-ez/ezmlm-cgi?1:sss:91326#b
and
http://lists.mysql.com/cgi-ez/ezmlm-cgi?1:sss:91495#b

), I am unable to execute the "shutdown" command in mysqladmin.  This
is a problem, as I am building my database on a Macintosh laptop
running Darwin 1.4.1 / OS X 10.1.0 , and need to shut my computer down
fairly frequently -- usually at least once per day.  Later, I intend to
migrate the database to a HP/UX server, but until I get the ball
rolling I must work locally on my computer.

Sinisa Milivojevic has mentioned that a fix for this problem is
scheduled for the next MySQL release.  I'll gladly upgrade when it is
available, but in the meantime I need to work on this project for my
employer, and can't wait until then to get started.  Also, it sounds
geeky to say this but it's difficult to contain the excitement of
learning about MySQL and PHP, especially now that I have a job that
pays me to do so.  Until the next release is available, I must use the
dreaded "kill -9" shell command to shut down the MySQL daemon, which
may corrupt data in the database.  So I am wondering if anyone can shed
some light on this workaround that I am considering:

I have been reading about mysqldump in Paul DuBois's excellent book,
"MySQL" (New Riders, c 2000).  It seems that I can use mysqldump to
save my database data to a file before I execute the "kill -9" shell
command to shut down mysqld.  In the book, DuBois calls this
"refreshing" the database, and writes (pp. 435-6) that using

bash2.05$ mysqldump --add-drop-table samp_db > /path/to/backup/file

would be the correct way to do this.  This is because, apparently, a
database will give an error if I try to reload the backup file into it,
because the tables already exist.

This raises another question -- will the original database accept this
backup if it *has* been corrupted?  Or will I have to run isamchk or
myisamchk first, every time I wish to re-load ("refresh") the
information?  I understand that my database probably won't become
corrupted every single time from a "kill -9" command, but it is likely
to happen at some point as I will be doing this daily.

Does anyone think that this is a viable solution to my problem?  Thanks
very much for any input or thoughts!


-- Erik Price

PS: To all who respond, please CC me directly, as I am a "digester" and
will have to wait for the next digest to read your response.  Thank
you.

PPS: One final question, of which I think I already know the answer but
request confirmation: if I do some database development with my binary
install of mysql-3.23.43-apple-darwin1.3.7-powerpc (currently on my
hard drive), will I be able to dump the data to a file, remove the
MySQL installation entirely, compile mysql-3.23.44.tar.gz with a few
extra ./configure options, and re-load the data from the backup?  It
seems like this wouldn't be a problem, because the only thing I am
saving is backup information.  I would just have to make sure to create
a new database into which I can load the backup information.

__________________________________________________
Do You Yahoo!?
Find the one for you at Yahoo! Personals
http://personals.yahoo.com

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to