Tag Archives: Freenas

FreeNAS – Upgrades and a corrupted USB stick

FreeNAS – Upgrades and a corrupted USB stick

Last week I decided it was probably time to finally upgrade my FreeNAS server from 11.2 U2 to 11.2 U7 as it was giving me rrdcache errors on shutdown and also ground to a halt when I was doing a large clonezilla backup of my machine.

Continue reading FreeNAS – Upgrades and a corrupted USB stick

FreeNAS – Speeding Up My NFS Datastore For XenServer

FreeNAS – Speeding up my NFS Datastore for XenServer

While using a nested XenServer 7.1 on VMware ESXi 6.5 to test something unrelated I noticed that running sdelete on one of my Gold Image VMs was painfully slow.  Looking on the XenServer performance I could see that the write latency was nearly 100ms to the NFS SR which would explain it being painfully slow on a VM.

Continue reading FreeNAS – Speeding Up My NFS Datastore For XenServer

FreeNAS 8.0 Dhcpd – Introduction And Pre-Requisites

FreeNAS 8.0 Dhcpd – Introduction And Pre-Requisites

Introduction And Pre-Requisites

FreeNAS is an open source FreeBSD based NAS solution which supports various ways of sharing storage on a network including CIFS (Windows shares), NFS, and iSCSI.

In order to provide an iSCSI Diskless boot environment it is recommended that the iSCSI network cards are on a separate network and one of the requirements of this is a DHCP server to present the LUNs to the clients.

In a small lab environment the DHCP Server can be installed on to a FreeNAS Server which is providing the iSCSI Disks and the following articles explain how to install and configure an ISC DHCP Server on a FreeNAS Version 8.0 RELEASE server.

The configuration of an ISC DHCP Server on a FreeNAS Version 8.0 RELEASE server can be split down in to the following sections :-

  • Installing the ISC DHCP Server
  • Configuriing the ISC DHCP Server
  • Making the changes permanent

Pre-Requisites

In order to configure the ISC DHCP Server on a FreeNAS Version 8.0 RELEASE server the following pre-requisites must be met :-

  • A FreeNAS Version 8.0 RELEASE installation
  • Access to the internet
  • SSH access enabled on the FreeNAS Server

Hardware Used

The hardware used for these articles was a Virtual Machine running on a VMware ESXi 4.0 host.

Details of the The FreeNAS Virtual Machine hardware used can be foundhere. The server has also had the following additional hardware added :-

  • An additional Network Interface connected to an iSCSI only Network
  • An additional Hard Drive 40Gb for iSCSI Deployment

FreeNAS 8.0 iSCSI 4 – Starting The ISCSI Service

FreeNAS 8.0 iSCSI 4 – Starting The ISCSI Service

Starting The iSCSI Service

The final part of the configuration of iSCSI on a FreeNAS Version 8.0 RELEASE server is to start the iSCSI Service.  To start the iSCSI service perform the following steps :-

  • Logon to the FreeNAS Web Console as an administrative account
  • Expand Services in the left hand pane
  • Click on Control Services
  • The iSCSI Service will be showing as Off (Red)
  • Click on the Off box to start the iSCSI service
  • The iSCSI Service will now be showing as On (Blue)

FreeNAS 8.0 iSCSI 3 – Configuring Targets And Extents

FreeNAS 8.0 iSCSI 3 – Configuring Targets And Extents

Configuring Targets And Extents

The final step in configuring iSCSI on a FreeNAS Version 8.0 RELEASE server is to configure the Targets and Extents.  For this article we will be configuring an iSCSI Disk Target.  An iSCSI Disk Target effectively takes one of the disks in the server and deploys it to the Initiators (Clients) as a Raw block device.  The presented iSCSI Disk will be just like a new hard disk in the Initiator (Client) machine and will require partitioning and formatting before use.

Configuring iSCSI Disk Targets

The first part of the configuration is to configure the Target required.  To configure the Target perfom the following steps :-

  • Logon to the FreeNAS Web Console as an administrative account
  • Expand Services in the left hand pane and then expand iSCSI
  • Expand the Targets branch and click on Add Target
  • Configure the Target Name to the desired name
  • Configure the Type as Disk
  • Configure the Portal Group ID as 1 (The Portal set up in the first article)
  • Configure the Initiator Group ID as 1 (The Initiator Group set up in the first article)
  • Click on OK to create the new Target

Configuring Device Extents

The next part of the configuration is to configure the Extent required on the server for our iSCSI Disk Target which is a Device Extent.  To configure the Device Extent perform the following steps :-

  • Logon to the FreeNAS Web Console as an administrative account
  • Expand Services in the left hand pane and then expand iSCSI
  • Expand the Device Extents branch and click on Add Extent
  • Configure the Extent Name to desired name
  • From the Disk Device drop down box select the disk ID required

N.B. Ensure you select the correct Disk Device ID

  • Click on OK to create the new Device Extent

Associating The Target And Extent

The final part of the configuration is to associate the Target with the Extent on the server.  To associate the Target with the Extent perform the following steps :-

  • Logon to the FreeNAS Web Console as an administrative account
  • Expand Services in the left hand pane and then expand iSCSI
  • Expand the Target / Extents branch and click on Add Target / Extent
  • From the Target drop down box select the iSCSI Disk Target required
  • From the Extent drop down box select the Device Extent required
  • Click on OK to create the new Association

FreeNAS 8.0 iSCSI 2 – Configuring The Target Global Configuration

FreeNAS 8.0 iSCSI 2 – Configuring The Target Global Configuration

The next step in configuring iSCSI on a FreeNAS Version 8.0 RELEASE server is to configure the Target Global Configuration.  To configure the Target Global Configuration perform the following steps :-

  • Logon to the FreeNAS Web Console as an administrative account
  • Expand Services in the left hand pane and then expand iSCSI
  • Expand the Target Global Configuration branch
  • Either configure the Base Name to something more meaningful for your environment or leave it set as the suggested value
  • Leave Discovery Auth Method and Discovery Auth Group as None.  This allows anonymous discovery of the iSCSI Target from all initiators.
  • Tick the Enable LUC (Logical Unit Controller) checkbox
  • Configure the Controller IP Address as 127.0.0.1
  • Configure the Controller TCP Port as 3261
  • Configure the Controller Authorised Netmask as 255.255.255.0
  • Configure the Controller Auth Method as CHAP
  • Configure the Controller Auth Group as 1 (The Authorised Access Group setup in the previous article)
  • Click on OK to save the Target Global Configuration

FreeNAS 8.0 iSCSI 1 – Configuring Authorised Access

FreeNAS 8.0 iSCSI 1 – Configuring Authorised Access

Configuring Access

The first step in the configuration is to set up the Access for iSCSI by configuring the Authorised Access, Authorised Initiators, and setting up an iSCSI Portal.

Configuring Authorised Access

The first step in configuring access is to setup Authorised Access.  To configure Authorised Access for iSCSI perform the following steps :-

  • Logon to the FreeNAS Web Console as an administrative account
  • Expand Services in the left hand pane and then expand iSCSI
  • Expand the Authorized Access branch and then click on Add Authorized Access
  • In the Add Authorized Access screen leave the Group ID as 1
  • For the User field enter in the CHAP Username you wish to use
  • For the Secret field enter in the CHAP Password you wish to use and confirn it in the Secret (Confirm)  setting
  • Click on OK to create the new Authorized Access Group

Configuring Authorised Initiators

The next step in configuring access is to setup the initiators which are authorised to access iSCSI and from which network(s).

To configure Authorised Initiators for iSCSI perform the following steps :-

  • Logon to the FreeNAS Web Console as an administrative account
  • Expand Services in the left hand pane and then expand iSCSI
  • Expand the Initiators branch and then click on Add Initiator
  • In the Add Initiator screen leave the Initiators as ALL
  • For the Authorized Network setting leave it also as ALL
  • Enter a Comment for the Authorized Initiators 
  • Click on OK to create the new Authorized Initiators Group

The Authorised Initiators setup above is a very basic configuration which allows access to iSCSI from all Initiators (Clients) on all networks.  Further locking down of this can be done to allow different access from different networks for named initiators and will be explained later in an advanced article.

Configuring An iSCSI Portal

The next step in configuring access is to setup an iSCSI Portal which controls which networks iSCSI will listen on.  To configure an iSCSI Portal perform the following steps :-

  • Logon to the FreeNAS Web Console as an administrative account
  • Expand Services in the left hand pane and then expand iSCSI
  • Expand the Portals branch and then click on Add Portal
  • In the Add Portal screen leave the Portal as 0.0.0.0:3260
  • Enter a Comment for the Portal 
  • Click on OK to create the new iSCSI Portal

The iSCSI Portal seup above is again a very basic configuration which sets iSCSI up to listen on all IP Addresses on the server.  Further locking down of this can be done to configure iSCSI to listen on different IP Addresses and will be explained later in an advanced article.

FreeNAS 8.0 iSCSI – Introduction And Pre-Requisites

FreeNAS 8.0 iSCSI – Introduction And Pre-Requisites

Introduction

FreeNAS is an open source FreeBSD based NAS solution which supports various ways of sharing storage on a network including CIFS (Windows shares), NFS, and iSCSI.

iSCSI (Internet Small Computer System Interface) is an inexpensive method of providing storage over IP across LAN’s and WAN’s as an alternative to Fibre SAN attached storage.

The following articles explain how to configure iSCSI on a FreeNAS Version 8.0 RELEASE server.

For these articles iSCSI was configured to deploy disk devices to a Windows 2008 R2 Failover Cluster.

The configuration of iSCSI on a FreeNAS Version 8.0 RELEASE server can be split down in to the following sections :-

  • Configuring Access
  • Configuriing the Target Global Configuration
  • Configuring Targets and Extents

Pre-Requisites

In order to configure iSCSI on a FreeNAS Version 8.0 RELEASE server the following pre-requisites must be met :-

  • A FreeNAS Version 8.0 RELEASE installation
  • Free Hard Disks for deploying as iSCSI Disk Devices
  • At least one Network Connection

Where as iSCSI can be used to deploy disks across any network connection it is recommended if possible to have a seperate dedicated iSCSI network so that production LAN performance is not impacted.

Hardware Used

The hardware used for these articles was all Virtual Machines running on a CentOS 5.5 64-Bit VMware Server Version 1.0.8 host.

FreeNAS Server

The FreeNAS Virtual Machine hardware was configured as shown here. The server has also had the following additional hardware added :-

  • An additional Network Interface connected to an iSCSI only Network
  • Three additional Hard Drives for iSCSI Deployment

Windows 2008 R2 Servers

The Windows 2008 R2 Cluster Node servers Virtual Machine hardware was configured using the Windows 2003 64-Bit Enterprise template with the following additional hardware added :-

  • An additional Network Interface connected to an iSCSI only Network
  • An additional Network Interface connected for Cluster Heartbeat

 The installation and configuration of the Windows 2008 R2 Failover Cluster and nodes is outside the scope of these articles but are mentioned here as a reference.