Skip to main content

VMWare: Install Ubuntu 24.04

Below is a comprehensive, step‐by‐step guide for performingdeploying a clean installation ofan Ubuntu 24.04 headless server as a headlessvirtual server.machine in VMware vCenter (version 7 or 8). This guidetutorial covers everything from preparationobtaining the ISO and uploading it to post-installationyour configurationdatastore, withoutcreating a desktopnew environment.VM, Note: A clean installation will erase existing data onperforming the targetinstallation, drive.and Becarrying sureout tobasic backpost-deployment configuration.

Important:

  • Ensure you have administrative privileges in vCenter.
  • Back up any important data before proceeding.

    making changes.
  • A headless server does not include a desktop GUI.

1. Pre-InstallationDeployment Preparations

a. Verify System Requirements

  • Processor:vCenter Access: 2VMware GHzvCenter dual-core7/8 orenvironment betterwith rights to create VMs.
  • MemoryHardware (RAM):Resources: MinimumEnsure 4the GBhost/cluster (morehas recommendedenough CPU, RAM, and storage for serveryour workloads)VM.
  • DiskISO Space:Image: Minimum 20 GB (adjust based on your intended server usage)
  • Network: Ethernet or Wi-Fi adapter (wired is preferred for servers)
  • Console Access: Either direct physical access or remote (via IPMI/KVM) since no GUI will be available

b. Backup Your Data

  • Warning: A clean installation will erase all data on the chosen drive. Back up important files and configurations.

2. Download the Ubuntu 24.04 Server ISO

  1. Visit the Official Ubuntu Website:
    Navigate tofrom Ubuntu Server Downloads.

  2. b. Upload the Ubuntu ISO to a Datastore

    1. Log In to vCenter:
      Open the vSphere Client and log in to your vCenter instance.

    2. Select Ubuntua 24.04 LTS:Datastore:
      ClickNavigate onto Storage and choose the Ubuntudatastore 24.04where LTSyou’d Serverlike downloadto button.store the ISO.

    3. DownloadUpload the ISO:
      Save the ISO file to your computer.

    4. Verify the Download (Optional but Recommended):

      • Right-click the datastore and select OnUpload Linux/macOS:Files.
      • Browse for the downloaded sha256sum path/to/ubuntu-24.04-live-server-amd64.iso
      • file and upload it.
      • On Windows:
        Use a tool such as QuickHash to verifyNote the checksumdatastore providedpath onfor thelater Ubuntu website.use.

    3.2. Create a BootableNew USBVirtual DriveMachine in vCenter

    a. UsingLaunch Rufusthe (Windows)New VM Wizard

    1. DownloadRight-Click Host/Cluster:
      In the vSphere Client inventory, right-click your desired host or cluster and Installselect Rufus:New Virtual Machine
      Visit rufus.ie and download the latest version..

    2. InsertChoose Creation Method:

      • Select Create a USBnew Drive:virtual machine
        Ensure it’and click Next.

    b. Configure VM Settings

    1. Name and Location:

      • Name: Enter a meaningful name (e.g., Ubuntu24-Server).
      • Folder/Resource Pool: Choose the appropriate folder or resource pool.
    2. Select a Compute Resource:

      • Choose the host or cluster where the VM will run.
    3. Select a Storage:

      • Choose the datastore where the VM’s virtual disk will reside.
    4. Compatibility & Guest OS:

      • Compatibility: Use the default or choose one that fits your environment.
      • Guest OS:
        • Family: Linux
        • Version: Ubuntu Linux (64-bit)

        Note: Ubuntu 24.04 may not be explicitly listed; select the closest match (Ubuntu 64-bit).

    5. Configure Virtual Hardware:

      • CPU: Allocate at least 1–2 vCPUs.
      • Memory: Allocate at least 2 GB (allmore dataif your workloads require it).
      • Disk: Create a virtual disk of 20 GB or more (adjust based on theyour USB will be erased)needs).

      • Network:

        OpenAdd Rufusa network adapter (VMXNET3 is recommended) and Configure:ensure it’s connected.

      • CD/DVD Drive:

        • Device: Select yourDatastore USBISO drive.File.
        • BootBrowse selection:to Clickthe “SELECT”location andwhere chooseyou uploaded the Ubuntu 24.04 Server ISO.
        • PartitionCheck scheme:the
          • Chooseoption GPTConnect At Power On for UEFI systems (most modern PCs).
          • Choose MBR if you need BIOS/Legacy support.
        • File System: Typically “FAT32” (default).
      • StartFinish the Process:Wizard:
        ClickReview “START”your settings and confirmclick anyFinish warnings. Rufus will nowto create your bootable USB drive.

    b. Using balenaEtcher (macOS/Linux/Windows)

    1. Download Etcher:
      Go to balenaEtcher and download the version for your OS.VM.

    2. Install and Run Etcher:

      • Select the Ubuntu 24.04 Server ISO.
      • Choose your USB drive.
      • Click “Flash!” and wait for the process to finish.

    c. Using the dd Command (Linux/macOS)

    Warning: The dd command is powerful. Ensure you’ve selected the correct drive to avoid data loss.

    1. Identify the USB Drive:
      lsblk
    2. Write the ISO to the USB:
      Replace /dev/sdX with your USB device (do not include a partition number, e.g., use /dev/sdb instead of /dev/sdb1):
      sudo dd if=/path/to/ubuntu-24.04-live-server-amd64.iso of=/dev/sdX bs=4M status=progress conv=fdatasync

    4.3. Booting and Installing Ubuntu 24.04 Server

    a. Power On the VM and Open the Console

    1. Start the VM:
      Right-click the newly created VM and select Power On.
    2. Launch Console:
      Open the VM console from the USBvSphere DriveClient to interact with the installation.

    b. Boot from the ISO and Begin Installation

    1. Boot

      InsertMenu:

      • The VM should boot from the BootableISO USBautomatically. DriveIf intonot, enter the server hardware.

      • Restart Your Server.

      • EnterVM’s BIOS/UEFI Settings:

        (using
          the
        • Common keys: F2, F12, DEL, or ESC (refer to your hardware’console’s documentation).
        • key
        • Setprompts) and adjust the boot order to prioritize bootingboot from the USBCD/DVD drive.
      • Save and Exit:
        Your server should now boot from the USB drive.


    5. Starting the Ubuntu Server Installation

    1. Boot Menu:
      After booting from the USB, you’ll see a text-based installer menu. Since this is a server installation, there is no graphical “Try” mode.
      • Action: Select “Install Ubuntu Server”: (or
          similar
        • At option)the usingtext-based yourinstaller keyboard’smenu, arrowselect keysInstall Ubuntu Server and press Enter.

    6.

    c. Follow the ServerText-Based Installation Wizard

    1. The installation wizard is text-basedLanguage and will guide you through the setup. Use the keyboard (arrow keys, Tab, and Enter) to navigate the menus.Keyboard:

      a. Select Your Language

      • Screen:Select “Welcome to Ubuntu Server Installer”
      • Action:Language: Choose your preferred languagelanguage.
      • and
      • Keyboard pressLayout: Enter.Confirm or adjust the layout.

      b. Select Your Keyboard Layout

      • Screen: “Keyboard Configuration”
      • Action: Choose your layout (often “English (US)” or your regional setting) and press Enter.

      c. Configure the Network

      • Screen: “Network Connections”
      • Action:Configuration:

        • The installer will attempt to configure networking via DHCP.
        • If usingyou need a static IP or additional network interfaces,IP, follow the prompts to set upit manually.
        • Tip: Ensure your network connection is active so that installation can download updates and packages if needed.
    2. d.

      Storage Configure the Proxy (If Applicable)

      Configuration:

      • Screen:Partitioning “HTTP Proxy”
      • Action: Enter your proxy settings if required, or leave blank if not using one.

      e. Choose a Mirror for Package Updates

      • Screen: “Ubuntu Archive Mirror”
      • Action: Select the appropriate mirror (usually detected automatically) and press Enter.

      f. Storage Configuration

      • Screen: “Partition Disks”
      • Options:
        • Choose Guided – use entire disk:disk Forfor a fully automatic partitioning schemesimplicity (this will erase allany data)data on the virtual disk).
        • Optionally, choose Manual:Manual Forif customyou partitioningwish (forto example,customize creating separate partitions for /, /var, or swap).partitions.
      • Action:EFI Partition: Choose your preferred option, confirm any warnings, and proceed.
        • For UEFIUEFI-based systems,VMs, ensure an EFI System Partition is created (usually around 300–500 MB, formatted as FAT32) is created if not already present.
        • Set up the root partition (/) (at least 10–20 GB recommended).
        • Optionally configure a swap area (or use a swap file post-installation).

      g.

    3. Profile
    4. Setup

      User and SSH Setup:

      • Screen:Profile “Who Are You?”
      • Action:Setup:
        • Enter your full name, a username, and a secure password.
        • Configure
        whether to enable SSH access during installation (highly recommended for headless servers).
      • Tip:SSH Server: Many
          server
        • When installersprompted, offerchoose to install and enable the OpenSSH serverserver. automatically—confirmThis thisis toessential allowfor remote management.management of your headless server.

      h.

    5. Feature
    6. Selection

      Finalizing (Optional)Installation:

      • Screen: “Featured Server Snaps” or “Additional Software”
      • Action:
        • You might have options to install services like LXD, Docker, or other server applications.
        • Select the ones you need, or skip if you plan to install them later.

      i. Finalize the Installation

      • Screen: “Summary”
      • Action: Review your configuration on the summary screen and confirm to begin the installation.
      • The installer will now copy files and configure yourthe system. This process may take several minutes.

      7. Finishing Up

      1. InstallationComplete Complete:Installation:

        • Once the processinstallation is finished,complete, you’ll be prompted to remove the installation media.

        • In

          RestartvCenter, Your Server:

          • Removeedit the USBVM’s settings to disconnect the ISO from the CD/DVD drive.
          • Press Enter to reboot.
        • First Boot:

          • Your server will boot into a command-line login prompt.
          • Log in usingReboot the username and password you created during installation.VM.

      8.4. Post-Installation Configuration

      a. Update the System

      1. Log In viato Your New Server
        • Console or SSH:
          If you enabledUse the SSHVM server,console you can nowor connect remotely.via SSH (if configured during installation) using:
          ssh yourusername@<vm_ip_address>

        b. Update and Upgrade Packages

        1. Update Package Lists and Upgrade Packages:Lists:
          sudo apt update
        2. Upgrade Packages:
          sudo apt upgrade -y

        c. Secure Your Server

        1. CleanDisable UpRoot UnusedSSH Packages:Login (if not already done):
          sudo aptnano autoremove -y

        b. Secure Remote Access

        • SSH Configuration:
          The server installer should have set up SSH, but you can further harden it:
          • Edit /etc/ssh/sshd_config
            • Find the line PermitRootLogin and set it to disableno.
            • root login
            • Save and considerexit changing(Ctrl+X, thethen defaultY, then Enter).
          • Restart SSH port.
          • Restart SSH:Service:
            sudo systemctl restart ssh
    7. d.
    8. Configure the Firewall Setup with UFW:UFW
      1. EnableAllow UFW:SSH Connections:
        sudo ufw allow ssh
        • If you changed the SSH port, allow that port instead (e.g., sudo ufw allow 2222/tcp).
      2. Enable UFW:
        sudo ufw enable
      3. Check Firewall Status:
        sudo ufw status verbose

      c.e. Install Essential Server PackagesTools

      • InstallFor utilitiesbasic andsystem toolsadministration, thatinstall arepackages commonlysuch used:as:
        sudo apt install build-essential curl git vim htop -y
      • Note: Since this is a headless server, you won’t install any desktop environments.

      d. Configure Networking (If Needed)

      • Use commands like ip a or ifconfig to check your network settings.
      • For advanced networking, edit configuration files in /etc/netplan/ (Ubuntu’s default on recent releases) and apply changes using:
        sudo netplan apply

      e. Set Up Automated Backups

      • Consider installing and configuring backup tools (e.g., rsnapshot or borgbackup) to safeguard your server data.
      • Configure a regular backup schedule via cron jobs.

      9.5. Final Thoughts

      • Documentation:Snapshots:
        Use FamiliarizevCenter’s yourselfsnapshot withfeature Ubuntuto Servercreate documentationa forrestore advancedpoint configurationafter andconfiguring troubleshooting.your server.
      • Community:Monitoring & Backups:
        Consider Ubuntu Forums and Ask Ubuntu are excellent resources for support and tips.
      • Monitoring: Setsetting up system monitoring tools (e.g.,and netdata,regular nagios, or prometheus)backups to keepsafeguard anyour eyeVM.
      • Further Customization:
        Explore additional packages and configurations based on serveryour health.server’s intended role.

      Congratulations! Your Ubuntu 24.04 headless server is now installed,deployed updated,on VMware vCenter and configuredready for remotefurther managementcustomization and furtherapplication customization.deployment. Enjoy your new virtual server environment!