How do I create a bootable USB recovery drive for Linux devices?
Last updated:Jul 20, 2022
How do I create a bootable USB recovery drive for Linux devices?
Purpose
This article guides you through how to create a bootable USB drive for restoring Linux devices which had been backed up by Active Backup for Business. With this USB drive, you can restore data from backups on your Synology NAS to your Linux devices.
Resolution
-
Create a bootable USB drive with ISO burning software
- Go to Download Center.
- Click the Select product type drop-down menu and select NAS.
- Click the Select your Synology Product drop-down menu and select your Synology NAS model.
- Go to the OS version field and select your OS version.
- Go to the Desktop Utilities tab, find Synology Active Backup for Business Recovery Media Creator (Synology-Recovery-Media.iso), and click Download.
- Use 3rd-party ISO burning software to copy Synology-Recovery-Media.iso onto a USB drive or DVD.
- You can use this USB drive or DVD to boot up the device you wish to restore.
-
Create a bootable USB drive for Legacy BIOS
- Go to Download Center.
- Click the Select product type drop-down menu and select NAS.
- Click the Select your Synology Product drop-down menu and select your Synology NAS model.
- Go to the OS version field and select your OS version.
- Go to the Desktop Utilities tab, find Synology Active Backup for Business Recovery Media Creator (Synology-Recovery-Media.iso), and click Download.
- Open a Linux Terminal and enter below command to install the packages and dependencies. In the following steps, we will take Ubuntu for example.
apt-get install syslinux syslinux-utils
- Insert a USB drive.
- List all the partitions to locate the inserted USB drive. The partitions are displayed by their device's names. For example: /dev/sda, /dev/sdb or /dev/sdc. In this tutorial, we take /dev/sdc for example.
fdisk -l
- Enter the command below to format the USB drive to FAT32. Replace /dev/sdc with the actual name of the USB drive.
mkdosfs -I /dev/sdc -F 32
- Enter the command below to copy Synology-Recovery-Media.iso to the USB drive.
dd if=Synology-Recovery-Media.iso of=/dev/sdc bs=1M
- You can use this USB drive to boot up the device you wish to restore.
-
Create a bootable USB drive for UEFI
- Go to Download Center.
- Click the Select product type drop-down menu and select NAS.
- Click the Select your Synology Product drop-down menu and select your Synology NAS model.
- Go to the OS version field and select your OS version.
- Go to the Desktop Utilities tab, find Synology Active Backup for Business Recovery Media Creator (Synology-Recovery-Media.iso), and click Download.
- Open a Linux Terminal and enter the command below to mount the downloaded recovery media. In the following steps, we will take Ubuntu for example.
mkdir -p /mnt/abb
mount -o loop Synology-Recovery-Media.iso /mnt/abb - Insert a USB drive.
- List all the partitions to locate the inserted USB drive. The partitions are displayed by their device’s names. In this tutorial, we take /dev/sdc for example.
fdisk -l
- Enter the commands below to set the USB drive as a GPT formatted disk and create a EFI system partition.
fdisk /dev/sdc
g
: Create a new empty GPT partition tablen
and1
: Create a partition with default valuest
and1
: Change the partition type to EFI system partitionw
: Save changes
- Enter the command below to format the volume you newly created.
mkfs.vfat -I /dev/sdc1
- Enter the command below to mount the volume.
mkdir -p /mnt/usb
mount /dev/sdc1 /mnt/usb - Enter the command below to copy Synology-Recovery-Media.iso to the USB drive.
cp -r /mnt/abb/* /mnt/usb/
- Enter the command below to unmount the USB drive and the recovery media.
umount /mnt/usb
umount /mnt/abb - You can use this USB drive to boot up the device you wish to restore.
-
Troubleshooting
If you cannot boot up the Linux server after recovery, please try the following methods for troubleshooting first.
- Please refer to this article to boot up the Linux device.
- Change to UEFI or BIOS mode. Some of the recovery drives created by 3rd-party burning software can only be booted in either of two modes. You can refer to the application providers' websites for more suggestions.