1.8 KiB
1.8 KiB
tags
| tags | ||
|---|---|---|
|
Detailed Steps:
- Connect and Identify the USB Drive:
- Plug the USB drive into your Proxmox server.
- Use the
lsblkcommand to list block devices and identify the correct device name (e.g.,/dev/sdb1,/dev/sdc1). Pay attention to the size to ensure you've selected the correct drive.
Code
lsblk
- Format the USB Drive:
- Use the appropriate command to format the drive with a suitable filesystem. For backups,
ext4is a good choice.
- Use the appropriate command to format the drive with a suitable filesystem. For backups,
Code
mkfs.ext4 /dev/sdX1
- Replace
/dev/sdX1with the actual device name you identified. - Note: If you are using the drive for Windows VMs, you might need to format it with NTFS.
- Create a Mount Point:
- Create a directory where you want to mount the USB drive.
Code
mkdir /mnt/usb_storage
- Mount the USB Drive:
- Mount the formatted drive to the created mount point.
Code
mount /dev/sdX1 /mnt/usb_storage
- Configure Automatic Mounting:
- Edit the
/etc/fstabfile to ensure the drive is automatically mounted after a reboot.
- Edit the
Code
nano /etc/fstab
- Add a line similar to the following, replacing the UUID, mount point, and filesystem type as needed:
Code
UUID=your_uuid /mnt/usb_storage ext4 defaults,noatime,nofail 0 2
- To find the UUID, use
lsblk -o +UUID as root. - Note: The
nofailoption prevents the system from failing to boot if the drive is not available.
- Add as Proxmox Storage (Optional):
- In the Proxmox web interface, navigate to Datacenter > Storage.
- Click "Add" and select "Directory".
- Configure the storage ID, directory (mount point), and filesystem type (e.g.,
ext4). - You can then use this storage for backups or other purposes.