2014-02-11 03:44:02 +04:00
|
|
|
# srm
|
|
|
|
|
2016-01-07 20:31:27 +03:00
|
|
|
> Securely remove files or directories.
|
2016-01-20 14:42:47 +03:00
|
|
|
> Overwrites the existing data one or multiple times. Drop in replacement for rm.
|
2014-02-11 03:44:02 +04:00
|
|
|
|
2016-01-20 20:59:42 +03:00
|
|
|
- Remove a file after a single-pass overwriting with random data:
|
2014-02-11 03:44:02 +04:00
|
|
|
|
|
|
|
`srm -s {{/path/to/file}}`
|
2016-01-20 14:42:47 +03:00
|
|
|
|
2016-01-20 20:59:42 +03:00
|
|
|
- Remove a file after seven passes of overwriting with random data:
|
2016-01-20 14:42:47 +03:00
|
|
|
|
2014-02-11 03:44:02 +04:00
|
|
|
`srm -m {{/path/to/file}}`
|
|
|
|
|
2016-01-20 20:59:42 +03:00
|
|
|
- Recursively remove a directory and its contents overwriting each file with a single-pass of random data:
|
2014-02-11 03:44:02 +04:00
|
|
|
|
2016-01-20 14:42:47 +03:00
|
|
|
`srm -r -s {{/path/to/folder}}`
|
2014-02-11 03:44:02 +04:00
|
|
|
|
2016-01-07 20:31:27 +03:00
|
|
|
- Prompt before every removal:
|
2014-02-11 03:44:02 +04:00
|
|
|
|
2015-10-28 11:33:06 +03:00
|
|
|
`srm -i {{\*}}`
|