tldr/pages/linux/fsck.md

17 lines
544 B
Markdown
Raw Permalink Normal View History

2016-06-23 18:41:44 +01:00
# fsck
> Check the integrity of a filesystem or repair it. The filesystem should be unmounted at the time the command is run.
> More information: <https://manned.org/fsck>.
2016-06-23 18:41:44 +01:00
- Check filesystem `/dev/sdXN`, reporting any damaged blocks:
2016-06-23 18:41:44 +01:00
`sudo fsck {{/dev/sdXN}}`
2016-06-23 18:41:44 +01:00
- Check filesystem `/dev/sdXN`, reporting any damaged blocks and interactively letting the user choose to repair each one:
2016-06-23 18:41:44 +01:00
`sudo fsck -r {{/dev/sdXN}}`
2016-06-23 18:41:44 +01:00
- Check filesystem `/dev/sdXN`, reporting any damaged blocks and automatically repairing them:
2016-06-23 18:41:44 +01:00
`sudo fsck -a {{/dev/sdXN}}`