Yandex Cloud
Search
Contact UsGet started
  • Pricing
  • Customer Stories
  • Documentation
  • Blog
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • AI Studio
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Center for Technologies and Society
    • Yandex Cloud Partner program
  • Pricing
  • Customer Stories
  • Documentation
  • Blog
© 2025 Direct Cursus Technology L.L.C.
Service page
Yandex BareMetal
Documentation
Yandex BareMetal
  • Getting started
    • All guides
      • Leasing a server
      • Getting information about a server
      • Updating a server
      • Connecting to the KVM console
      • Stopping and starting a server
      • Cancel a server lease
      • Uploading a custom OS image
      • Connecting an existing BareMetal server to Cloud Backup
      • Using the Rescue CD
        • Reinstalling the OS from a Marketplace image
        • Reinstalling the OS from your ISO image
      • Configuring the MC-LAG aggregation group
      • Resetting a password on the server
      • Replacing a disk in a RAID array
      • Adding a new SSH key for a user
      • Restoring the OS bootloader
      • Disk status analysis with HW Watcher
    • Overview
      • Overview
      • Server configurations
      • Disk status analysis
      • Additional server settings
      • Overview
      • DHCP
      • MC-LAG
      • Restrictions in BareMetal networks
    • Images
    • Quotas and limits
    • All tutorials
    • Connecting an existing BareMetal server to Cloud Backup
    • Configuring VRRP for a cluster of BareMetal servers
    • Establishing network connectivity in a BareMetal private subnet
    • Establishing network connectivity between BareMetal and Virtual Private Cloud private subnets
    • Establishing network connectivity between a BareMetal private subnet and on-premise resources
    • Delivering USB devices to a BareMetal server or virtual machine
    • Configuring an OPNsense firewall in high availability cluster mode
    • Deploying a web app on BareMetal servers with an L7 load balancer and Smart Web Security protection
  • Monitoring metrics
  • Audit Trails events
  • Access management
  • Pricing policy
  • FAQ

In this article:

  • Boot the server from your custom ISO image in UEFI mode
  • Configure the basic OS settings
  • Partition your disks and create RAID 10 arrays
  • Alternative disk partitioning options
  • Installing system files
  1. Step-by-step guides
  2. Servers
  3. Reinstalling the server OS
  4. Reinstalling the OS from your ISO image

Reinstalling an OS from a custom ISO image

Written by
Yandex Cloud
Improved by
Danila N.
Updated at August 25, 2025
  • Boot the server from your custom ISO image in UEFI mode
  • Configure the basic OS settings
  • Partition your disks and create RAID 10 arrays
    • Alternative disk partitioning options
  • Installing system files

Yandex BareMetal allows you to install and reinstall a server OS from a custom ISO image. This way, you can install Linux or Windows operating systems on your server. Note that if the OS you want to install requires a license, you must provide your own license.

When installing or reinstalling an OS from your custom ISO image, you can freely redistribute the available disk space on the server.

Creating fault-tolerant disk configurations requires experience and understanding of RAID and/or LVM technologies. We recommend using Marketplace public OS images instead, resorting to this installation method only if you need customizations beyond Marketplace options.

For example, you might need to install from your own ISO image if the required OS is not available in Marketplace, or you need a custom disk partitioning layout, UEFI/SecureBoot mode, root encryption, or other options unavailable through Marketplace image deployment.

Warning

Incorrect disk partitioning or RAID configuration can lead to the loss of fault tolerance, unexpected partition space shortages, and server boot failures.

This guide demonstrates how to install Ubuntu 24.04 in UEFI mode on a BA-i201-H server with four HDDs using a custom ISO image and RAID 10 disk configuration with LVM.

Boot the server from your custom ISO image in UEFI modeBoot the server from your custom ISO image in UEFI mode

To create a BareMetal image from your ISO image and deploy it on the server:

  1. Download the required ISO OS image to your local computer.

  2. Upload the ISO image to Yandex Object Storage and get a link to the uploaded object:

    1. Create an Object Storage bucket:

      Note

      To create a bucket, you need the minimum storage.editor role for the folder.

      Management console
      Yandex Cloud CLI
      1. In the management console, select the folder where you want to create a bucket.

      2. In the list of services, select Object Storage.

      3. At the top right, click Create bucket.

      4. On the bucket creation page:

        1. Enter a name for the bucket as per the naming requirements.
        2. Set a bucket size limit or enable No limit, if required.
        3. Leave all other parameters as they are and click Create bucket.

      If you do not have the Yandex Cloud CLI installed yet, install and initialize it.

      By default, the CLI uses the folder specified when creating the profile. To change the default folder, use the yc config set folder-id <folder_ID> command. You can also set a different folder for any specific command using the --folder-name or --folder-id parameter.

      1. Create a bucket in the default folder:

        yc storage bucket create --name <bucket_name>
        

        Where --name is the name of the bucket. This is a required parameter. For more information, see Bucket naming rules.

        Result:

        name: <bucket_name>
        folder_id: b1gt6g8ht345********
        anonymous_access_flags: {}
        default_storage_class: STANDARD
        versioning: VERSIONING_DISABLED
        created_at: "2025-08-06T07:29:40.418079Z"
        resource_id: e3e9neva43dl********
        

        For more information about the yc storage bucket create command, see the Yandex Cloud CLI reference.

    2. Upload the downloaded image file to the created bucket.

      Management console
      Yandex Cloud CLI

      Note

      You can upload objects of up to 5 GB via the management console (see Quotas and limits in Object Storage). To upload larger objects, use other tools.

      1. In the management console, select Object Storage from the list of services and navigate to the bucket you want to upload your image to.
      2. In the left-hand panel, click Objects and then Upload in the top-right corner.
      3. In the window that opens, select the image file and click Open.
      4. In the object upload window, click Upload and wait for the image to upload.
      5. Refresh the page.
      1. Run this command:

        yc storage s3api put-object \
          --body <local_file_path> \
          --bucket <bucket_name> \
          --key <object_path>
        

        Where:

        • --body: Path to the file you need to upload to the bucket, e.g., ./ubuntu.iso.
        • --bucket: Name of your bucket.
        • --key: Key to use for storing the object in the bucket, e.g., Ubuntu-2404.iso.

        Result:

        etag: '"87740887a5159e2685500c02********"'
        request_id: 300dceee********
        

      For more information about the yc storage s3api put-object command, see the Yandex Cloud CLI reference.

    3. Get a link to the image uploaded to the bucket:

      Management console
      1. In the management console, select your folder.
      2. In the list of services, select Object Storage and then, the required bucket.
      3. Click the name of the object with the uploaded ISO image.
      4. In the top-right corner, click Get link.
      5. Click Get link.
      6. Copy the link.
  3. Create a BareMetal image from the downloaded ISO image:

    Management console
    CLI
    1. In the management console, select a folder where you want to create your image.

    2. In the list of services, select BareMetal.

    3. In the left-hand panel, select Boot images.

    4. Click Upload image.

    5. Specify the image name. The naming requirements are as follows:

      • It must be from 2 to 63 characters long.
      • It can only contain lowercase Latin letters, numbers, and hyphens.
      • It must start with a letter and cannot end with a hyphen.
    6. Optionally, provide a description for the image.

    7. Paste the link to the image file you got from Object Storage in the previous step.

    8. Click Upload.

    1. Run this command:

      yc baremetal boot-image create \
        --name <image_name> \
        --uri "<image_link>"
      

      Where:

      • --name: Image name. Follow these naming requirements:

        • It must be from 2 to 63 characters long.
        • It can only contain lowercase Latin letters, numbers, and hyphens.
        • It must start with a letter and cannot end with a hyphen.
      • --uri: Link to the image file you got from Object Storage in the previous step.

  4. Connect to the server's KVM console.

    Note

    All following steps will be performed in the KVM console.

  5. Click the CD icon or select Media → Virtual Media Wizard... in the top menu of the KVM console window. In the window that opens:

    1. In the CD/DVD Media1 section, click Browse and select the previously uploaded ISO OS image in the user-iso directory.
    2. Click Connect CD/DVD.
    3. Check the Virtual CD 1 device Status section to make sure the Connected To field now shows your selected ISO path, then click Close.

    Depending on your server configuration, you may need to manually select the boot device or enable UEFI mode in BIOS. For instance, on a server with the BA-i201-H configuration, you must boot from a CD drive in UEFI mode for UEFI-based OS installations.

  6. To boot the server from the selected ISO image:

    1. Click Reboot to CD-ROM in the top-right corner of the KVM console.

    2. During server boot, press F11 or Del when the POST screen appears. You will see the following message: Entering Setup....

    3. Wait for the BIOS menu to appear, then navigate to the Save & Exit section using the ← and → keys.

    4. In the Boot Override section, use the ↑ and ↓ keys to select UEFI: AMI Virtual CDROM0 1.00, then press Enter.

      If there is no such option in the Boot Override section, go to Boot settings and add it under UEFI Boot Drive BBS Priorities.

    The server will restart and boot from the virtual CD drive in UEFI mode.

    Warning

    BareMetal servers use optimal BIOS settings by default. We do not recommend changing them.

Configure the basic OS settingsConfigure the basic OS settings

In this step, you will configure the basic settings for the OS installation. Perform all following actions in the KVM console:

  1. In the GRUB bootloader menu, select Try or Install Ubuntu Server and press Enter.

  2. Select the system language:

    01

    Use the ↑ and ↓ keys to navigate the menu.

  3. Choose your keyboard layout, select Done, and press Enter. Depending on the selected layout, you may need to configure a keyboard shortcut for switching input languages.

  4. Select the server installation option, either full or minimal:

    02

  5. Configure network interfaces. The default configuration uses DHCP for all network interfaces:

    03

  6. If needed, configure a proxy and repository mirror address for OS package installation.

    For instance, you can use the following mirror address for Ubuntu systems: http://mirror.yandex.ru/ubuntu. In most cases, though, no configuration changes are needed.

  7. Select the Custom storage layout disk partitioning option. To do this, navigate to this menu item and press Space.

    04

    We recommended against using the default Ubuntu installer option of installing the system on a single drive. Such configuration is not fault tolerant, and the system disk failure will require at minimum a full OS reinstallation.

Partition your disks and create RAID 10 arraysPartition your disks and create RAID 10 arrays

Alert

During disk partitioning, the created partitions will be automatically formatted. This operation will erase all existing data on the disks. Before you proceed, make sure you have backups of all important server files.

Proper disk partitioning is critical for OS installation, affecting disk subsystem performance, data storage reliability, server fault tolerance, and recovery speed in failure scenarios.

At this step, you can create any disk configuration, from basic Marketplace OS installer defaults to advanced LVM with encryption.

Before proceeding with OS installation, create the following partitions:

  • /: Root partition.

  • /boot: Boot partition.

  • swap: Swap partition.

  • /home: User home partition.

  • /srv: Service data partition.

  • ESP: 1 GB UEFI system partition.

    If you boot the server in Legacy mode, the system will create a 300 MB BIOS grub spacer system partition instead of the ESP partition.

    Note

    The ESP and BIOS grub spacer system partitions are created automatically when you select the disk as a primary or secondary boot device during installation.

To create a RAID10 fault-tolerant disk array, you need at least four disks or partitions. If you plan to create a RAID array using disk partitions, first you need to prepare the disks by creating a partition table and defining equally sized partitions on each disk:

  1. If the server has an OS installed and the disks already have partitions, remove all existing partitions. If the server was provisioned without an OS and you have not installed one yet, skip this step and proceed to the next one.

    1. In the AVAILABLE DEVICES section, remove all existing disk partitions and RAID arrays on the server.

      Use the ↑ and ↓ keys to select a partition or RAID, press Enter, then choose DELETE from the menu that appears and confirm the deletion.

      To delete all partitions on a disk, select the line containing this disk’s name, press Enter, then select Reformat and confirm the deletion.

    2. Repeat the previous step for all partitions, disks, and RAID arrays listed under AVAILABLE DEVICES.

      After completing these steps, the AVAILABLE DEVICES section should only show disks with unallocated space, e.g., free space:

      05

  2. Select your boot disks:

    1. Using the ↑ and ↓ keys, select any disk and press Enter.

    2. In the menu that appears on the right, select Use As Boot Device and press Enter.

      06

      To install the bootloader, you must mark at least one disk as bootable. For fault tolerance, we recommend marking at least two disks.

    3. Select another disk, press Enter, and select Add As Another Boot Device.

  3. Create matching partition layouts on all disks, sized according to the expected storage requirements. In this example, we will create three partitions on each disk:

    1. Partition the first disk:

      1. For the first disk in the list, select the free space entry, press Enter, then select Add GPT Partition from the menu that appears.
      2. In the Size: field of the dialog that appears, specify the size of the first partition: 4G.
      3. In the Format: field, select Leave unformatted.
      4. Move the cursor to Create and press Enter.
      5. Repeat the process to create two additional partitions: one 2 GB partition and the other using all remaining available space.
    2. Use the process described above to partition the remaining three disks. The partition layouts on all four disks must be the same.

    07

  4. Build RAID arrays using the partitions created in the previous step:

    1. Navigate to Create software RAID (md) in the menu and press Enter. In the dialog that opens:

      1. In the RAID Level: field, select 10.
      2. Use the Space key to mark 4 GB partitions on each disk.
      3. Move the cursor to Create and press Enter.

      08

    2. Repeat the steps to create the second RAID 10 array using 2-GB partitions and, finally, the third RAID 10 array using the remaining largest partitions.

  5. Create filesystem partitions within your newly configured RAID arrays:

    1. Create the swap partition:

      1. Select the md0 8 GB RAID array, press Enter, and select Format from the menu that appears.
      2. In the dialog that opens, select swap in the Format: field.
      3. Move the cursor to Done and press Enter.
    2. Create the /boot partition:

      1. Select the md1 4 GB RAID array, press Enter, and select Format from the menu that appears.
      2. In the dialog that opens, leave the Format field set to ext4 and select /boot in the Mount: field.
      3. Move the cursor to Done and press Enter.

      09

  6. Use the md2 RAID array composed of your largest partitions to create a vg0 LVM group:

    1. Create an LVM group:

      1. Navigate to Create volume group (LVM) in the menu and press Enter.
      2. In the dialog that opens, navigate to the md2 array in the Devices: field and press Space to select it.
      3. Move the cursor to Create and press Enter.
    2. Create an lv-root logical volume for the root partition:

      10

      1. In the vg0 section under AVAILABLE DEVICES, select free space and press Enter, then select Create Logical Volume from the menu that opens.
      2. In the Name: field, specify lv-root.
      3. In the Size: field, specify the volume size as 100G.
      4. Leave the Format: field set to ext4 and the Mount: field set to /.
      5. Move the cursor to Create and press Enter.

      11

    3. Repeat the steps to create the following logical volumes:

      • lv-home: 512 GB logical volume mounted at /home for user directories.
      • lv-srv: 1 TB logical volume mounted at /srv for service data.

      12

    The remaining unallocated space in the vg0 LVM volume group can be used to expand existing logical volumes or create additional volumes when needed.

Alternative disk partitioning optionsAlternative disk partitioning options

The disk partitioning scheme shown above is just an example. Disk partitioning should always be tailored to the projected server usage patterns. Furthermore, disk partitioning requirements differ between server boot modes: Legacy or UEFI.

Let’s consider some other disk partitioning configurations:

Option 1
Option 2
Option 3

Disk layout identical to that created by the Marketplace BareMetal installer in Legacy boot mode:

13

Disk layout identical to that created by the Marketplace BareMetal installer in UEFI boot mode:

14

Setting up partitioning with the root filesystem in the LVM logical volume, encrypted and hosted on a RAID10 array:

15

Note

Partition encryption can have a number of downsides, such as reduced server performance, the need to enter an encryption key on every restart, and irreversible data loss if the key is lost. To avoid entering an encryption key on every boot, you can configure a [TPM](Trusted Platform Module) on the server. For more details, see https://en.wikipedia.org/wiki/Trusted_Platform_Module.

Installing system filesInstalling system files

Once you completed disk partitioning on your server, you can proceed with system installation.

Alert

Up to this point, no disk modifications have been made yet, so you may safely abort the OS installation without data loss. Proceeding with installation will permanently erase all existing data on the target disks and physically create new partition structures.

  1. To proceed, move the cursor to Done and press Enter.

    In the Confirm destructive action dialog that appears, click Continue to confirm disk formatting.

  2. Specify the hostname, create the primary user account, configure SSH access if needed, and install additional software:

    16

    Wait for the operating system installation to complete.

  3. Disable the virtual CD drive in the KVM console:

    1. Click the CD icon or select Media → Virtual Media Wizard... in the top menu of the KVM console window.
    2. In the window that opens, click Disconnect under CD/DVD Media1.
    3. Click Close.
  4. To boot into the new OS, select Reboot Now and press Enter:

    17

  5. Configure the server to boot in UEFI mode:

    1. While the server is booting, press F11 or Del on the POST screen. You will see the following message: Entering Setup....

    2. Wait for the system BIOS menu to appear, then navigate to the Boot section using the ← and → keys.

    3. Select 1st Boot Device, press Enter, and select UEFI: Built-in EFI Shell.

    4. Select UEFI Boot Drive BBS Priorities and press Enter. In the menu that opens, do the following:

      1. In the 1st Device field, press Enter and select any of the UEFI OS values.
      2. Press Esc to return to the previous menu.
    5. Make sure the value of the 1st Boot Device field has changed to UEFI OS.

    6. Navigate to the Save & Exit section, using the ← and → keys.

    7. Select Save Changes and Reset, press Enter, and confirm the action by pressing Yes.

The server will now boot into the new operating system using UEFI mode.

Was the article helpful?

Previous
Reinstalling the OS from a Marketplace image
Next
Configuring the MC-LAG aggregation group
© 2025 Direct Cursus Technology L.L.C.