DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH
 

(mysql.info.gz) myisamchk repair options

Info Catalog (mysql.info.gz) myisamchk check options (mysql.info.gz) Table maintenance (mysql.info.gz) myisamchk other options
 
 5.7.3.4 Repair Options for `myisamchk'
 ......................................
 
 `myisamchk' supports the following options for table repair operations:
 
 `--backup, -B'
      Make a backup of the `.MYD' file as `file_name-time.BAK'
 
 `--character-sets-dir=PATH'
      The directory where character sets are installed.   Character
      sets.
 
 `--correct-checksum'
      Correct the checksum information for the table.
 
 `--data-file-length=#, -D #'
      Maximum length of the data file (when re-creating data file when
      it's "full").
 
 `--extend-check, -e'
      Do a repair that tries to recover every possible row from the data
      file.  Normally this will also find a lot of garbage rows. Don't
      use this option unless you are totally desperate.
 
 `--force, -f'
      Overwrite old temporary files (files with names like
      `TBL_NAME.TMD') instead of aborting.
 
 `--keys-used=#, -k #'
      For `myisamchk', the option value indicates which indexes to
      update.  Each binary bit of the option value corresponds to a
      table index, where the first index is bit 0.  For `isamchk', the
      option value indicates that only the first # of the table indexes
      should be updated.  In either case, an option value of 0 disables
      updates to all indexes, which can be used to get faster inserts.
      Deactivated indexes can be reactivated by using `myisamchk -r' or
      (`isamchk -r').
 
 `--no-symlinks, -l'
      Do not follow symbolic links. Normally `myisamchk' repairs the
      table that a symlink points to.  This option doesn't exist as of
      MySQL 4.0, because versions from 4.0 on will not remove symlinks
      during repair operations.
 
 `--parallel-recover, -p'
      Uses the same technique as `-r' and `-n', but creates all the keys
      in parallel, using different threads.  This option was added in
      MySQL 4.0.2.  _This is alpha code. Use at your own risk!_
 
 `--quick, -q'
      Achieve a faster repair by not modifying the data file. You can
      specify this option twice to force `myisamchk' to modify the
      original data file in case of duplicate keys.
 
 `--recover, -r'
      Do a repair that can fix almost any problem except unique keys
      that aren't unique (which is an extremely unlikely error with
      `ISAM'/`MyISAM' tables).  If you want to recover a table, this is
      the option to try first. You should try `-o' only if `myisamchk'
      reports that the table can't be recovered by `-r'.  (In the
      unlikely case that `-r' fails, the data file is still intact.)
 
      If you have lots of memory, you should increase the value of
      `sort_buffer_size'.
 
 `--safe-recover, -o'
      Do a repair using an old recovery method that reads through all
      rows in order and updates all index trees based on the rows found.
      This is an order of magnitude slower than `-r', but can handle a
      couple of very unlikely cases that `-r' cannot.  This recovery
      method also uses much less disk space than `-r'. Normally, you
      should repair first with `-r', and then with `-o' only if `-r'
      fails.
 
      If you have lots of memory, you should increase the value of
      `key_buffer_size'.
 
 `--set-character-set=NAME'
      Change the character set used by the table indexes.
 
 `--sort-recover, -n'
      Force `myisamchk' to use sorting to resolve the keys even if the
      temporary files should be very big.
 
 `--tmpdir=PATH, -t PATH'
      Path of the directory to be used for storing temporary files. If
      this is not set, `myisamchk' uses the value of the `TMPDIR'
      environment variable.  Starting from MySQL 4.1, `tmpdir' can be
      set to a list of directory paths that will be used successively in
      round-robin fashion for creating temporary files. The separator
      character between directory names should be colon (`:') on Unix
      and semicolon (`;') on Windows, NetWare, and OS/2.
 
 `--unpack, -u'
      Unpack a table that was packed with `myisampack'.
 
Info Catalog (mysql.info.gz) myisamchk check options (mysql.info.gz) Table maintenance (mysql.info.gz) myisamchk other options
automatically generated byinfo2html