mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-01-26 11:33:59 +00:00
26 lines
504 B
Plaintext
26 lines
504 B
Plaintext
---
|
|
syntax: markdown
|
|
tags: [tldr, common]
|
|
source: https://github.com/tldr-pages/tldr.git
|
|
---
|
|
# mysqlcheck
|
|
|
|
> Check and repair MySQL tables.
|
|
> More information: <https://dev.mysql.com/doc/refman/en/mysqlcheck.html>.
|
|
|
|
- Check a table:
|
|
|
|
`mysqlcheck --check {{table}}`
|
|
|
|
- Check a table and provide credentials to access it:
|
|
|
|
`mysqlcheck --check {{table}} --user {{username}} --password {{password}}`
|
|
|
|
- Repair a table:
|
|
|
|
`mysqlcheck --repair {{table}}`
|
|
|
|
- Optimize a table:
|
|
|
|
`mysqlcheck --optimize {{table}}`
|