Ubuntu Server 16.4.6 VM install isn't working


Recommended Posts

Hello, I have been following the instructions in this video:

 

https://www.youtube.com/watch?v=QGa3uA7-QOQ

 

to install Ubuntu server as a VM. I have followed everything exactly. I know the video is a few years old, but the process seems like it is the same. The installation process goes all the way through and seems to be fine, but when I reboot the VM after finishing it takes me to the same boot from ISO screen to start the install process over again. It's like the server never actually starts. What am I missing here? TIA

Link to comment

@OneFiveRhema Edit your VM, switch to xml view and change the "boot order" for your vdisk to 1 and for the iso to 2 so it looks something like this

 

    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2' cache='writeback' discard='unmap'/>
      <source file='/mnt/user/VMs/W7_template_seabios/vdisk1.qcow2'/>
      <target dev='hdc' bus='scsi'/>
      <boot order='1'/>
      <address type='drive' controller='0' bus='0' target='0' unit='2'/>
    </disk>
    <disk type='file' device='cdrom'>
      <driver name='qemu' type='raw'/>
      <source file='/mnt/user/isos/Acronis/AcronisMedia.117iso.iso'/>
      <target dev='hda' bus='ide'/>
      <readonly/>
      <boot order='2'/>
      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
    </disk>

 

Link to comment
4 hours ago, bastl said:

@OneFiveRhema Edit your VM, switch to xml view and change the "boot order" for your vdisk to 1 and for the iso to 2 so it looks something like this

 


    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2' cache='writeback' discard='unmap'/>
      <source file='/mnt/user/VMs/W7_template_seabios/vdisk1.qcow2'/>
      <target dev='hdc' bus='scsi'/>
      <boot order='1'/>
      <address type='drive' controller='0' bus='0' target='0' unit='2'/>
    </disk>
    <disk type='file' device='cdrom'>
      <driver name='qemu' type='raw'/>
      <source file='/mnt/user/isos/Acronis/AcronisMedia.117iso.iso'/>
      <target dev='hda' bus='ide'/>
      <readonly/>
      <boot order='2'/>
      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
    </disk>

 

Thank you for the suggestion, I really appreciate you taking the time to help. 

 

Looking at my XML it appears that the boot order is already set correctly. Here is my VM XML:

<?xml version='1.0' encoding='UTF-8'?>
<domain type='kvm'>
  <name>UbuntuSQLserver</name>
  <uuid>4c58769a-024b-f57a-02c4-9f644a7717fa</uuid>
  <description>sql server</description>
  <metadata>
    <vmtemplate xmlns="unraid" name="Ubuntu" icon="ubuntu.png" os="ubuntu"/>
  </metadata>
  <memory unit='KiB'>4194304</memory>
  <currentMemory unit='KiB'>2097152</currentMemory>
  <memoryBacking>
    <nosharepages/>
  </memoryBacking>
  <vcpu placement='static'>2</vcpu>
  <cputune>
    <vcpupin vcpu='0' cpuset='6'/>
    <vcpupin vcpu='1' cpuset='7'/>
  </cputune>
  <os>
    <type arch='x86_64' machine='pc-q35-3.1'>hvm</type>
    <loader readonly='yes' type='pflash'>/usr/share/qemu/ovmf-x64/OVMF_CODE-pure-efi.fd</loader>
    <nvram>/etc/libvirt/qemu/nvram/4c58769a-024b-f57a-02c4-9f644a7717fa_VARS-pure-efi.fd</nvram>
  </os>
  <features>
    <acpi/>
    <apic/>
  </features>
  <cpu mode='host-passthrough' check='none'>
    <topology sockets='1' cores='2' threads='1'/>
  </cpu>
  <clock offset='utc'>
    <timer name='rtc' tickpolicy='catchup'/>
    <timer name='pit' tickpolicy='delay'/>
    <timer name='hpet' present='no'/>
  </clock>
  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>restart</on_crash>
  <devices>
    <emulator>/usr/local/sbin/qemu</emulator>
    <disk type='file' device='disk'>
      <driver name='qemu' type='raw' cache='writeback'/>
      <source file='/mnt/user/domains/UbuntuSQLserver/vdisk1.img'/>
      <target dev='hdc' bus='virtio'/>
      <boot order='1'/>
      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
    </disk>
    <disk type='file' device='cdrom'>
      <driver name='qemu' type='raw'/>
      <source file='/mnt/user/isos/ubuntu-16.04.6-server-amd64.iso'/>
      <target dev='hda' bus='sata'/>
      <readonly/>
      <boot order='2'/>
      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
    </disk>
    <controller type='usb' index='0' model='ich9-ehci1'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x7'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci1'>
      <master startport='0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x0' multifunction='on'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci2'>
      <master startport='2'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x1'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci3'>
      <master startport='4'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x2'/>
    </controller>
    <controller type='sata' index='0'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
    </controller>
    <controller type='pci' index='0' model='pcie-root'/>
    <controller type='virtio-serial' index='0'>
      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
    </controller>
    <controller type='pci' index='1' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='1' port='0x10'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0' multifunction='on'/>
    </controller>
    <controller type='pci' index='2' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='2' port='0x11'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x1'/>
    </controller>
    <controller type='pci' index='3' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='3' port='0x12'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x2'/>
    </controller>
    <controller type='pci' index='4' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='4' port='0x13'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x3'/>
    </controller>
    <controller type='pci' index='5' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='5' port='0x14'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x4'/>
    </controller>
    <interface type='bridge'>
      <mac address='52:54:00:f0:22:21'/>
      <source bridge='br0'/>
      <model type='virtio'/>
      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
    </interface>
    <serial type='pty'>
      <target type='isa-serial' port='0'>
        <model name='isa-serial'/>
      </target>
    </serial>
    <console type='pty'>
      <target type='serial' port='0'/>
    </console>
    <channel type='unix'>
      <target type='virtio' name='org.qemu.guest_agent.0'/>
      <address type='virtio-serial' controller='0' bus='0' port='1'/>
    </channel>
    <input type='tablet' bus='usb'>
      <address type='usb' bus='0' port='1'/>
    </input>
    <input type='mouse' bus='ps2'/>
    <input type='keyboard' bus='ps2'/>
    <graphics type='vnc' port='-1' autoport='yes' websocket='-1' listen='0.0.0.0' keymap='en-us'>
      <listen type='address' address='0.0.0.0'/>
    </graphics>
    <video>
      <model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1' primary='yes'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0'/>
    </video>
    <memballoon model='virtio'>
      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0'/>
    </memballoon>
  </devices>
</domain>

 

Link to comment
4 minutes ago, bastl said:

@OneFiveRhema What happens if you remove the iso?

If I remove the ISO VNC takes me to a Shell. I still don't seem to have network or the ability to SSH into the server. Ifconfig reveals no IP address set, even though it said DHCP was working during autocofig on setup. I've changed focus at this point and am using the SQL Docker container. It drives me nuts that I can't get this server working, but I've spent a lot of hours troubleshooting it and I don't have more to waste. Thanks again for your help. 

Link to comment

@OneFiveRhema I tried it myself with all the default settings and have the same issue with ubuntu-16.04.6-server-amd64. During the install process you'll be asked if you wanna force the installation into UEFI mode. The default is set to "no" and will end up in an unbootable installation.

 

Either you choose "yes" on the following screen

 

ubuntu.png.e71787a2ab149143e9ed6988c87f0270.png

 

or when setting up the VM in Unraid the first time, switch the BIOS setting to "SeaBIOS". Default in the Ubuntu template is OVMF/UEFI.

 

BIOS.png.5a3ed80fb78b8ad9bfaa9abdb40660e1.png

 

Link to comment
11 hours ago, bastl said:

@OneFiveRhema I tried it myself with all the default settings and have the same issue with ubuntu-16.04.6-server-amd64. During the install process you'll be asked if you wanna force the installation into UEFI mode. The default is set to "no" and will end up in an unbootable installation.

 

Either you choose "yes" on the following screen

 

ubuntu.png.e71787a2ab149143e9ed6988c87f0270.png

 

or when setting up the VM in Unraid the first time, switch the BIOS setting to "SeaBIOS". Default in the Ubuntu template is OVMF/UEFI.

 

BIOS.png.5a3ed80fb78b8ad9bfaa9abdb40660e1.png

 

That totally worked! I thought I had tried every possible option during install, but I guess I forgot that one. Thanks again for your help!

  • Like 1
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.