Quantcast
Channel: The Ravello Blog
Viewing all articles
Browse latest Browse all 333

How to prepare an NFS shared storage server for an ESXi lab

$
0
0

ESXi

As most of you probably know besides implementing a hypervisor merely capable of running regular VMs, we’ve also implemented a CPU virtualization extensions called VT-I for Intel or SVM for AMD cpus. These extensions, in essence, allow running other hypervisors such as KVM or VMWare’s ESXi in the public cloud on top of Ravello. In this blog I’m going to focus on installing and configuring NFS image template that can be later used as a shared datastore in a VMWare datacenter. Please note that there is already an image for NFS. This blog is optional in case you do not want to use Ravello’s public NFS image.

Prerequisites

If you do not already have an account in Ravello, please first open a trial account.

Overview

This article describes how to build a simple share storage using an NFS server in 10 minutes on top of Ravello. If you care for a fancier NFS server with multiple users, rolles, LDAP integration etc check out the internet for your favorite OS flavour (for example, see here).

Creating your virtual machine

To simplify the process we’ll use one of the preconfigured ubuntu virtual machines delivered by Ravello.

  1. Create an new application in Ravello (well, you can use an existing one if you prefer, no importance here).
  2. Drag a new Ubuntu vanilla VM from the library (at the time this blog was written the latest version is 14.04.1) onto the canvas
  3. Select a key pair or to create a new key pair (in the General tab on the VM properties pane)
  4. Optional:
    1. Set the Name and Hostnames in Ravello UI (General tab) to NFS or any hostname you would like to use in your application.
    2. Change the number of CPUs and Memory size to your need
    3. Change the disk size or add disks if needed (note: this tutorial assumes one hard disk, you can create multiple disks at this stage just make sure you know how to adjust the steps below accordingly )
  5. Publish the application to your favorite cloud. The new VM will be fully started within about 5 minutes.

Install and configure a simple NFS server

SSH into the newly created VM using the DNS name (as appear on the VM summary tab) and your private key.
ssh -i <key> ubuntu@<DNS name>

Once in, do the following:

  1. sudo apt-get update
  2. sudo apt-get install nfs-kernel-server -y
  3. sudo mkdir /nfs
  4. sudo chmod 777 /nfs
  5. add to /etc/exports the following line:
    /nfs *(rw,async,no_subtree_check,no_root_squash)
  6. sudo service nfs-kernel-server restart

Done, your new NFS is ready. The vm is listening to the hostname you defined and the NFS directory is /nfs.

NFS server on AWS

Saving NFS to the library

Once the NFS server is properly installed and configured, you are welcome to finally save it to Ravello’s library for future usage. Read here how to save the NFS VM to Ravello’s library.

The post How to prepare an NFS shared storage server for an ESXi lab appeared first on The Ravello Blog.


Viewing all articles
Browse latest Browse all 333

Trending Articles