×
Community Blog Deploying FreeNAS in Alibaba Cloud ECS

Deploying FreeNAS in Alibaba Cloud ECS

In this article, we will install and configure FreeNAS on an Alibaba Cloud ECS instance.

By Anish Nath, Alibaba Cloud Tech Share Author. Tech Share is Alibaba Cloud's incentive program to encourage the sharing of technical knowledge and best practices within the cloud community.

FreeNAS is an open source network attached storage that is based on the FreeBSD and the OpenZFS file system. According to the official website, FreeNAS is an operating system that can be installed on virtually any hardware platform to share data over a network.

FreeNAS installation in Alibaba Cloud is an advanced level task and should be performed carefully. To begin with installation, there are several high-level steps needed to install and setting it up the FreeNAS on an Alibaba Cloud Elastic Compute Service (ECS) instance.

  1. Download FreeNAS ISO.
  2. Upload FreeNAS ISO in Alibaba Cloud OSS.
  3. Grant ECS to use OSS.
  4. Create Custom FreeNAS ISO Image in Alibaba Cloud.
  5. Launch Instance using FreeNAS Custom Image.
  6. Create FreeNAS disk.
  7. Perform FreeNAS Installation.
  8. Unmount Disk from the ECS instance.
  9. Release FreeNAS Instance.
  10. FreeNAS Disk Is ready in Alibaba Cloud
  11. Convert Disk to Snapshot
  12. Convert Snapshot to Image
  13. Launch ECS instance using the image.

Before You Begin

Make sure you have a valid Alibaba Cloud account to try out this experiment. You'll also need an Alibaba Cloud ECS instance to install FreeNAS. FreeNAS 11.1 requires a 64-bit CPU and a minimum of 8GB RAM.

About FreeNAS

FreeNAS is an operating system that can be installed on virtually any hardware platform to share data over a network.

FreeNAS is the simplest way to create a centralized and easily accessible place for your data. Use FreeNAS with ZFS to protect, store, backup, all of your data. FreeNAS is used everywhere, for the home, small business, and the enterprise.

Download FreeNAS ISO

FreeNAS 11.1 requires a 64-bit CPU and a minimum of 8GB RAM, this version can be download from here.

Create an OSS Bucket

  1. Go to OSS console.
  2. Click Create Bucket to open the Create Bucket dialog box and then create your freenas bucket where you can upload the ISO image which is downloaded from FreeNAS website.

    1

  3. Upload the freeNAS-11.1-U6.iso image to the bucket

    2

  4. Confirm the file is uploaded in the bucket

    3

  5. Grab the Object URL
    Click the name of the target file. The Preview page is displayed and then Copy File URL as shown on the diagram below. This URL will be used for created custom free NAS image.

    4

Create FreeNAS Custom IMAGE

FreeNAS Custom Image Creation: In order to boot the FreeNAS, we need to create a custom image from the ISO file, this image will be used to install the FreeNAS in a disk. To create custom image, perform these steps

Go to the ECS console -> Images link and then click on Import Image, as shown in the diagram.

5

A popup will appear, this step require attention, we need to give permission to ECS to use OSS

6

Click on Confirm Address it will present you below screen and then Confirm both Authorization policy as shown below.

7

Once this step is performed successfully, go back to the ECS console -> Images link and then click on Import Image again from here you need to pay close attention to the following attribute which is highlighted in red.

  1. OSS Object Address: This will be the OSS object URL which is performed in previous section.
  2. Platform: This will be FreeBSD.
  3. Image Format: RAW

8

Click on OK and wait for this Custom Image to be available as shown in below.

9

Launch FreeNAS Custom IMAGE

So far, we have created a FreeNAS custom image, now let's launch this custom image through ECS console. The demo is created under the BillingMethod Pay As you Go, end user can select the billing method as per their needs.

Note: The End goal of this step is to release this Instance, as we are going to create a bootable disk once the FreeNAS installation is done and this bootable disk image will serve as FreeNAS service.

10

Under the Image Tab, select the custom Image tab and choose the image name from the drop down, which is uploaded in the previous step.

11

You don't need a public IP, make sure Assign public IP is unchecked in the Networking Page.

12

Under the System Configuration, skip the Log On credentials, this step will be executed when FreeNAS installation is in place.

13

Finally Review the Configuration and Launch the Installation

14

Once Everything goes well, your ECS instance should be up and running as shown in the below.

15

Next step is Very important, and we are going to create a disk and then mount this disk to this instance.

Create FreeNAS Disk in Alibaba Cloud

This disk will hold the installer data of the FreeNAS installation, to create boot disk, go to the ECS console -> Block Storage -> Disks -> Create Disk,

After the disk is created, it will be unmounted state.

16

Mount this disk to ECS Free NAS VM

17

Start FreeNAS Installation

Make sure you have performed all the steps above before executing this one. The installation of FreeNAS will be done using VNC console.

Go to your ECS instance ID and click connect

18

First Alibaba Cloud it will setup your VNC password, once this is done,

19

You will be able to connect to VNC console screen, and presented with FreeNAS installation screen

20

Select option#1, Install/Upgrade of FreeNAS Installation.

21

Choose the destination Media. This is the disk which we have setup in the previous step, select this disk where the installation files will hold and then click on OK.

22

On the Next step, you will be prompted to select the root password for the FreeNAS UI login,

23

Once Everything goes well, finally you will be prompted with the message, Installation went successful, this is the time when we release the ECS instance ID, unmount and preserver the Disk.

24

Release Instance & Unmount Disk

First Unmount the Disk from the ECS instance ID, to do this perform this step

ECS Console -> Block Storage-> Disk -> (Select Disk ID) -> More -> Unmount

25

And Finally release the ECS Instance ID

26

27

Create Custom Image from FreeNAS Disk

This is the final step of creating FreeNAS custom image from the Disk, which will serve as FreeNAS service and instance launch from this image will have FreeNAS service.

At first create a snapshot from the Disk, to do this perform the below step

ECS->Block Storage-> Disks -> (Select Instance ID) - > Create Snapshot

28

Once snapshot is created create a custom image from her, to perform this

ECS->Snapshots and Images -> Snapshots -> (Select snapshot) - > Create Custom Image

29

Verify the Image Status

30

From here onward, any ECS instance launched using this image will have FreeNAS server ready.

0 0 0
Share on

Alibaba Clouder

1,408 posts | 218 followers

You may also like

Comments