Linux command
bcachefs-device 命令
安全
权限或系统影响较大,执行前请核对目标。
常用示例
Example
sudo bcachefs device add --label [group].[name] [path/to/mountpoint] [path/to/device]
Migrate data off
bcachefs device evacuate [path/to/device]
Example
bcachefs device remove [path/to/device]
说明
bcachefs device manages devices within a running bcachefs filesystem. It allows adding new devices to expand storage, evacuating data before removal, and permanently removing devices. Device labels organize storage into groups (like ssd or hdd) and individual device names, enabling tiered storage configurations.
参数
- --label _group.name_
- Assign a label to categorize the device (e.g., ssd.cache, hdd.bulk)
- --force
- Force device removal even if it would reduce redundancy
FAQ
What is the bcachefs-device command used for?
bcachefs device manages devices within a running bcachefs filesystem. It allows adding new devices to expand storage, evacuating data before removal, and permanently removing devices. Device labels organize storage into groups (like ssd or hdd) and individual device names, enabling tiered storage configurations.
How do I run a basic bcachefs-device example?
Run `sudo bcachefs device add --label [group].[name] [path/to/mountpoint] [path/to/device]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does --label _group.name_ do in bcachefs-device?
Assign a label to categorize the device (e.g., ssd.cache, hdd.bulk)