an iSCSI share on a FreeNAS server which will be available in the Proxmox VE server.
Which can be used as vm storage or backup of your vm's for example.
Which can be used as vm storage or backup of your vm's for example.
Tested configuration
Server 1: FreeNAS 8.3.0 with hard drives and a usb stick.
Server 2: Proxmox VE 2.2 installed and running.
Server 2: Proxmox VE 2.2 installed and running.
Installation
Server 1: FreeNAS
Install FreeNAS on this server with default settings on the usb stick or seperate storage.
When the installation is finished log into your FreeNAS web interface.
Change your default admin password.
- "Account" - "Admin account" - "Change Password"-
Let's make a disk volume.
- "Storage" - "Volumes" - "Volume Manager"
Volume name: data (for example)
Choose the "hard drives" you want to add to this volume.
Select "ZFS" as the filesystem.
Next to make a ZFS Dataset to keep everything tidy when you want to create for example seperate datasets,
for example one for backup and the other one storage. This way you can assign different rights to it and keep it seperated.
- "Storage" - "Volumes" - "data" (or other name you gave to your disk volume) - "Create ZFS Dataset
Dataset Name: vm-storage (for example)
Now we will adjust the permissions of this Dataset.
In this how-to we will give everyone access and modify permissions to this Dataset including guests.
- "Storage" - "Volumes" - "data" - "vm-storage" - "Change permissions"
Check all settings in Mode.
Time to configure the iSCSI part.
- "Services" - "iSCSI" - "Portals" - "Add portal"
Choose "0.0.0.0" from the dropdown list and press "OK".
- "Services" - "iSCSI" - "Initiator" - "Add initiator"
Press "OK".
- "Services" - "iSCSI" - "File extent" - "Add file extent"
Extend name: vm-storage
Choose the created volume: "data" and type behind it: "/vmpool" (vmpool is an example)
Extent size: desired size
Press "OK"
- "Services" - "iSCSI" - "Targets" - "Add targets"
Target Name: Proxmox
Portal Group ID: 1
Initiator Group ID: 1
Press "OK".
- "Services" - "iSCSI" - "Targets / Extents" - "Add Targets / Extents"
Target: "Proxmox"
Extent: "vm-storage"
Press "OK".
Let's start the iSCSI services.
- Click in the top on the "Services" icon
- start "iSCSI"
Server 2: Proxmox VE
Let's add your additional storage in the proxmox web interface.
- Click on the folder icon "Datacenter"
- Click on the tab "Storage"
- Click on "Add"
- Click on "iSCSI target"
Now in the new screen that appears fill in the following values.
ID number: iSCSI-Volume
Portal: ip-adsress-of-server1
Target: "iSCSI volume"
The iSCSI volume has now been added.
This volume doesn't have a filesystem / partition on it.
This has to be created as well. This will automaticly happen when we add it as a LVM group.
- Click on the folder icon "Datacenter"
- Click on the tab "Storage"
- Click on "Add"
- Click on "LVM Group"
Now in the new screen that appears fill in the following values.
ID: vm-storage
Base storage: "iSCSI target"
Base volume: "iSCSI volume"
Volume group: vm-storage (for example)
Enabled: "checked"
The iSCSI had now been added to your proxmox server and is ready for use.
Install FreeNAS on this server with default settings on the usb stick or seperate storage.
When the installation is finished log into your FreeNAS web interface.
Change your default admin password.
- "Account" - "Admin account" - "Change Password"-
Let's make a disk volume.
- "Storage" - "Volumes" - "Volume Manager"
Volume name: data (for example)
Choose the "hard drives" you want to add to this volume.
Select "ZFS" as the filesystem.
Next to make a ZFS Dataset to keep everything tidy when you want to create for example seperate datasets,
for example one for backup and the other one storage. This way you can assign different rights to it and keep it seperated.
- "Storage" - "Volumes" - "data" (or other name you gave to your disk volume) - "Create ZFS Dataset
Dataset Name: vm-storage (for example)
Now we will adjust the permissions of this Dataset.
In this how-to we will give everyone access and modify permissions to this Dataset including guests.
- "Storage" - "Volumes" - "data" - "vm-storage" - "Change permissions"
Check all settings in Mode.
Time to configure the iSCSI part.
- "Services" - "iSCSI" - "Portals" - "Add portal"
Choose "0.0.0.0" from the dropdown list and press "OK".
- "Services" - "iSCSI" - "Initiator" - "Add initiator"
Press "OK".
- "Services" - "iSCSI" - "File extent" - "Add file extent"
Extend name: vm-storage
Choose the created volume: "data" and type behind it: "/vmpool" (vmpool is an example)
Extent size: desired size
Press "OK"
- "Services" - "iSCSI" - "Targets" - "Add targets"
Target Name: Proxmox
Portal Group ID: 1
Initiator Group ID: 1
Press "OK".
- "Services" - "iSCSI" - "Targets / Extents" - "Add Targets / Extents"
Target: "Proxmox"
Extent: "vm-storage"
Press "OK".
Let's start the iSCSI services.
- Click in the top on the "Services" icon
- start "iSCSI"
Server 2: Proxmox VE
Let's add your additional storage in the proxmox web interface.
- Click on the folder icon "Datacenter"
- Click on the tab "Storage"
- Click on "Add"
- Click on "iSCSI target"
Now in the new screen that appears fill in the following values.
ID number: iSCSI-Volume
Portal: ip-adsress-of-server1
Target: "iSCSI volume"
The iSCSI volume has now been added.
This volume doesn't have a filesystem / partition on it.
This has to be created as well. This will automaticly happen when we add it as a LVM group.
- Click on the folder icon "Datacenter"
- Click on the tab "Storage"
- Click on "Add"
- Click on "LVM Group"
Now in the new screen that appears fill in the following values.
ID: vm-storage
Base storage: "iSCSI target"
Base volume: "iSCSI volume"
Volume group: vm-storage (for example)
Enabled: "checked"
The iSCSI had now been added to your proxmox server and is ready for use.