List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:January 6 2000 12:40pm
Subject:Re: shutdown mysql when backing up?
View as plain text  
At 12:26 PM +0000 2000-01-06, Tim Bunce wrote:
>On Thu, Jan 06, 2000 at 05:01:39AM +0000, hypnos wrote:
>>  I am going to begin backing up important files onto
>>  another machine (over NFS).  My mysql databases are
>>  included in this.  I assume the easiest way to do
>>  this is just copy everything from my data directory
>>  (/usr/local/var/) down.  My question is, should I
>>  shutdown mysql before I copy these files to the other
>>  drive?  Or is there a better way to back the files up?
>
>Oracle has a way to take a table (actually a tablespace) 'offline'
>via SQL for making hot backups.
>
>It would be handy if MySQL offered something similar. Perhaps via
>a "LOCK tablename OFFLINE" statement that would flush and close the
>corresponding table and index files.
>
>Sounds simple to implement (as an extension to a WRITE lock).
>
>A backup script could then LOCK OFFLINE and UNLOCK each table in turn
>and, while each is locked, copy the corresponding table and index files
>to a separate directory.
>
>A simple and effective hot-backup.
>
>Monty, is this a good idea or is there a better way?


Would this be different in some way from LOCK READ plus FLUSH TABLES
before copying the files?

-- 
Paul DuBois, paul@stripped
Thread
shutdown mysql when backing up?hypnos6 Jan
  • Re: shutdown mysql when backing up?Tim Bunce6 Jan
    • Re: shutdown mysql when backing up?Paul DuBois6 Jan
      • Re: shutdown mysql when backing up?Tim Bunce6 Jan
        • Re: shutdown mysql when backing up?Tim Bunce6 Jan
          • RE: shutdown mysql when backing up?Daniel Lafraia7 Jan
            • Re: shutdown mysql when backing up?Tim Bunce7 Jan
        • Re: shutdown mysql when backing up?Michael Widenius7 Jan
          • is update more expensive than insert in Mysql?Cheng-Wei Cheng7 Jan
            • Re: is update more expensive than insert in Mysql?Patrick Greenwell7 Jan
            • Re: is update more expensive than insert in Mysql?Mark Zieg7 Jan
          • Re: shutdown mysql when backing up?Tim Bunce7 Jan
            • Re: shutdown mysql when backing up?Michael Widenius7 Jan
  • Re: shutdown mysql when backing up?Scott Hess6 Jan
    • Re: shutdown mysql when backing up?hypnos7 Jan
Re: is update more expensive than insert in Mysql?wayne_strauss7 Jan
  • Re: is update more expensive than insert in Mysql?Kyle Hayes7 Jan
  • Re: is update more expensive than insert in Mysql?Michael Widenius10 Jan
    • Re: is update more expensive than insert in Mysql?Eric Peters11 Jan
      • Re: is update more expensive than insert in Mysql?Benjamin Pflugmann11 Jan
      • Re: is update more expensive than insert in Mysql?Michael Widenius11 Jan
Re: shutdown mysql when backing up?Fred Lindberg7 Jan