Nutanix Acropolis – create RHEL 7.0 VM from qcow2 image

Shares

Nutanix Acropolis supports many different operating systems from both Windows and Linux world. The easiest way to deploy either Windows or Linux box on Nutanix Acropolis is to use image (template). Nutanix Acropolis has build in image service which supports different type of disks formats such as vmdk, vdi, vhd, iso, qcow2. Im this blog post I will show how to deploy Red Had 7 form qcow2 image.

  • Download qcow2 RHEL 7.0 image from Red Hat and upload to Linux system where  guestfish tools are installed. I will use guestfish tools to enable root user and set password for it, as by default root user is disabled in qcow2 images downloaded from Red Hat.
  • Mount image
    [root@kvn01 tmp]# guestfish --rw -a ./rhel-guest-image-7.0-20140618.1.x86_64.qcow2
    
    Welcome to guestfish, the libguestfs filesystem interactive shell for
    editing virtual machine filesystems.
    
    Type: 'help' for help on commands
          'man' to read the manual
          'quit' to quit the shell
    
    ><fs> run
    ><fs> list-filesystems
    /dev/sda1: xfs
    ><fs> mount /dev/sda1 /
    ><fs> vi /etc/shadow
    

    [box type=”info”] Do not exit from vi, you have to paste encrypted password for user root first.[/box]

  • On second terminal run command openssl command to generate hashtag for new root password
    [root@kvn01 ~]# openssl passwd -1 nutanix/4u
    $1$A51GS.na$.nR2Y.WlYJILFkdlJ2NZh1
    [root@kvn01 ~]#
  • Paste root password hashtag into /etc/shadows
  • save file and exit from guesfish tools
  • Create new image in Nutanix Acropolis, use modified qcow2 image as disk
  • Deploy RHEL 7.0 VM from new image onto Nutanix Acropolis
  • Launch console and log in to VM with root password

As you can see and watch (video below) there is no need to convert qcow to RAW format as image services takes care of everything for you 🙂

0 0 votes
Article Rating

Artur Krzywdzinski

Artur is Consulting Architect at Nutanix. He has been using, designing and deploying VMware based solutions since 2005 and Microsoft since 2012. He specialize in designing and implementing private and hybrid cloud solution based on VMware and Microsoft software stacks, datacenter migrations and transformation, disaster avoidance. Artur holds VMware Certified Design Expert certification (VCDX #077).

You may also like...

Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x

FOR FREE. Download Nutanix port diagrams

Join our mailing list to receive an email with instructions on how to download 19 port diagrams in MS Visio format.

NOTE: if you do not get an email within 1h, check your SPAM filters

You have Successfully Subscribed!

Pin It on Pinterest