You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cloudstack.apache.org by "dahampere (via GitHub)" <gi...@apache.org> on 2026/09/02 01:59:27 UTC

[D] iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM [cloudstack]

GitHub user dahampere created a discussion: iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM

I put together an overlay that makes CloudStack’s existing **Primera** primary-storage path work on **iSCSI-only KVM hosts**.

Repo: https://github.com/dahampere/cloudstack-primera_alletraMP-iscsi  
Release: https://github.com/dahampere/cloudstack-primera_alletraMP-iscsi/releases/tag/v4.22.1.1-1  
License: Apache License 2.0 (derived from ACS `plugins/storage/volume/primera` and `scripts/storage/multipath`)

This is **not** an official Apache CloudStack release and **not** a new storage API.

### The problem

Stock CloudStack already manages HPE Primera, 3PAR, Alletra Storage MP, and Alletra 9000 over **WSAPI v1** as **Provider = Primera**.

The in-tree KVM host scripts only rescan Fibre Channel (`/sys/class/fc_host`). On an iSCSI-only hypervisor that directory is empty, so attach never sees the LUN.

A second issue: one target IQN carries many VLUNs. Logging out of the iSCSI session when a single volume detaches drops every other volume on that target.

ACS **Protocol = iSCSI** (one shared LUN) is the wrong control plane for this. Use **Provider = Primera** (or the optional **AlletraMP** alias below). Path format stays `type=FIBERWWN; address=<WWN>`.

This is **not** Nimble OS (Alletra 5000 / 6000).

### What it does

Two pieces. You can install only the first.

| Piece | Where | What |
| --- | --- | --- |
| iSCSI connect overlay (required) | every KVM host | Debian package that overlays `connectVolume.sh`, `disconnectVolume.sh`, and `multipath-common.sh`. Rescans iSCSI sessions instead of FC. Does **not** log out the target on detach. |
| AlletraMP provider (optional) | every management node | Sidecar JAR next to Linstor/Storpool. Registers the same Primera adapter as **AlletraMP** so Add Primary Storage can show that name. Existing `provider=Primera` pools are left alone. |

Stock Primera stays installed. Do not rewrite `cloudstack-*.jar` and do not SQL-rename existing pools.

If `multipath.conf` uses `user_friendly_names yes` (maps as `mpathX`), the overlay creates `/dev/mapper/3<wwn>` → that device so CloudStack still finds the volume.

### Scope and status

- **Pinned to** Apache CloudStack **4.22.1.1** Debian/Ubuntu packages. Not “any 4.22”. No RPM.
- **Hypervisor:** KVM.
- **Array:** Primera / 3PAR / Alletra Storage MP / Alletra 9000, WSAPI v1, iSCSI.
- **Proven on this package:** deploy, attach, detach, live migrate.
- **Not in the KVM overlay** (stock FC scripts remain): `resizeVolume.sh`, `copyVolume.sh`, `cleanStaleMaps.sh`. Resize / copy / stale-map cleanup on iSCSI is unproven here.

### How to try it

Full steps: [docs/INSTALL.md](https://github.com/dahampere/cloudstack-primera_alletraMP-iscsi/blob/main/docs/INSTALL.md)

Short version:

1. On the array: host object per KVM hypervisor (name = CloudStack hostname), register each host IQN, put hosts in one host-set, note CPG + WSAPI URL.
2. On every KVM host: `open-iscsi` + `multipath-tools`, discover/login to **this array’s target IQN only**, `node.startup = automatic`. Do not log that target out.
3. Install the host overlay:

```bash
sudo apt-get install ./cloudstack-alletra-mp-kvm_4.22.1.1-1_all.deb
grep -c mp_scan_lun /usr/share/cloudstack-common/scripts/storage/multipath/connectVolume.sh
# expect 1

GitHub link: https://github.com/apache/cloudstack/discussions/14032

----
This is an automatically sent email for users@cloudstack.apache.org.
To unsubscribe, please send an email to: users-unsubscribe@cloudstack.apache.org


Re: [D] iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM [cloudstack]

Posted by "dahampere (via GitHub)" <gi...@apache.org>.
GitHub user dahampere added a comment to the discussion: iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM

@nickaccuweb  Thank you very much, for your response and time to evaluate this, which I greatly appreciate. While everything works as expected and now in production, if this could be included into the main-stream, after proper vetting; Makes life easy, for everyone, when it comes to patching and upgrades.

 - CloudStack 4.22.1.1
 - Ubuntu 24.04 LTS
 - HPE Alletra MP10100 (block)
 - The KVM hosts have iSCSI and NFS as primary storage (I've successfully migrated all disks from NFS into the alletra-array using the new driver, with no issues)
 - `{
  "count": 1,
  "storagepool": [
    {
      "allocatediops": 0,
      "capacitybytes": 43980465111040,
      "clusterid": "efa014f3-4b97-41c7-8613-149649499bb9",
      "clustername": "kvm-cluster",
      "created": "2026-08-29T17:15:43+1000",
      "details": {
        "ALLOW_MIGRATE_OTHER_POOLS": "true",
        "HARDWARE_ACCELERATION": "true",
        "api_password": "[removed]",
        "api_url": "https://[removed]:443/api/v1?cpg=SSD_r6&hostset=cs-nodes&api_skiptlsvalidation=true&acs_pool=v2",
        "api_username": "[removed]",
        "capacityBytes": "43980465111040"
      },
      "disksizeallocated": 18767539996160,
      "disksizetotal": 43980465111040,
      "disksizeused": 18767539996160,
      "hasannotations": false,
      "hypervisor": "KVM",
      "id": "ed4dde28-390f-4494-8723-9148aa15cf85",
      "ipaddress": "[removed]",
      "istagarule": false,
      "managed": true,
      "name": "alletra-mp10100-v2",
      "overprovisionfactor": "2.0",
      "path": "/api/v1?cpg=SSD_r6&hostset=cs-nodes&api_skiptlsvalidation=true&acs_pool=v2",
      "podid": "d24542f9-2f73-4645-8801-b27b5a9fa52f",
      "podname": "pod-1",
      "provider": "AlletraMP",
      "scope": "CLUSTER",
      "state": "Up",
      "storagecapabilities": {
        "CAN_CREATE_VOLUME_FROM_SNAPSHOT": "true",
        "CAN_CREATE_VOLUME_FROM_VOLUME": "true",
        "CAN_DIRECT_ATTACH_SNAPSHOT": "true",
        "CAN_REVERT_VOLUME_TO_SNAPSHOT": "true",
        "STORAGE_SYSTEM_SNAPSHOT": "true"
      },
      "tags": "iscsi,alletramp",
      "type": "FiberChannel",
      "zoneid": "542cf258-4a24-4daf-bcc2-b8816236fe7e",
      "zonename": "zone-1"
    }
  ]
}
`
- No errors or complains. Works like a charm. Screenshots below.

Primary Storage Configuration
<img width="2310" height="1156" alt="image" src="https://github.com/user-attachments/assets/a8a5a82b-5a6c-4cdf-8177-3f52d5023c10" />

VM Volumes Using the Primary Storage
<img width="1626" height="779" alt="image" src="https://github.com/user-attachments/assets/a1e2a362-ad1d-4b40-bd58-93de30e55c49" />

Backup Configuration
<img width="2295" height="587" alt="image" src="https://github.com/user-attachments/assets/a14848e5-675c-44b7-8fd7-90c822de0ab2" />

VM Backups
<img width="1633" height="751" alt="image" src="https://github.com/user-attachments/assets/3f3337b4-9d68-4cc7-be85-dc2f1d0dae6e" />

VM Backup Schedule
<img width="1633" height="751" alt="image" src="https://github.com/user-attachments/assets/af242f4e-c235-4d3b-969d-fececf6b0487" />

VM Backup Restoration ("Restore Instance Backup", "Restore and attach backup volume", "Create new instance from backup"), all working.
<img width="2297" height="1065" alt="image" src="https://github.com/user-attachments/assets/a85a15a3-d60a-4bcf-ba8c-f6f3ed9ee489" />


GitHub link: https://github.com/apache/cloudstack/discussions/14032#discussioncomment-18649461

----
This is an automatically sent email for users@cloudstack.apache.org.
To unsubscribe, please send an email to: users-unsubscribe@cloudstack.apache.org


Re: [D] iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM [cloudstack]

Posted by "dahampere (via GitHub)" <gi...@apache.org>.
GitHub user dahampere added a comment to the discussion: iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM

For anyone interested, I've also built a backup module for this.

https://github.com/dahampere/cloudstack-primera_alletraMP-backup

We have been using it in production with no issues. Please read the notes to understand what is and what isn't covered by this backup, before implementation.

GitHub link: https://github.com/apache/cloudstack/discussions/14032#discussioncomment-18544954

----
This is an automatically sent email for users@cloudstack.apache.org.
To unsubscribe, please send an email to: users-unsubscribe@cloudstack.apache.org


Re: [D] iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM [cloudstack]

Posted by "dahampere (via GitHub)" <gi...@apache.org>.
GitHub user dahampere added a comment to the discussion: iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM

Thank you for the confirmation @nickaccuweb . Appreciate your time..!

GitHub link: https://github.com/apache/cloudstack/discussions/14032#discussioncomment-18669191

----
This is an automatically sent email for users@cloudstack.apache.org.
To unsubscribe, please send an email to: users-unsubscribe@cloudstack.apache.org


Re: [D] iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM [cloudstack]

Posted by Paketix <pa...@bluewin.ch>.
Hi
Just out of curiosity ...
Is it possible to use the 3PAR/Primera/Alletra volume (VV) as shared storage for Cloudstack without cluster filesystem (eg. OCFS2)?
Currently reviewing CEPH as an alternative because OCFS2 (from Oracle) seems a bit too exotic to me.
Kind regards, Pat

On 9/25/26 08:17, nickaccuweb (via GitHub) wrote:
> GitHub user nickaccuweb added a comment to the discussion: iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM
>
> @dahampere
>
> Thank you for sharing the details.
>
> I reviewed the overlay, and it appears relevant for CloudStack environments where Primera / Alletra storage is connected to KVM hosts through iSCSI instead of Fibre Channel.
>
> The issue is that the default KVM storage scripts mainly rescan Fibre Channel paths, so an iSCSI-presented LUN may not be detected correctly. The overlay changes the discovery process to use the existing iSCSI sessions and also avoids disconnecting the shared iSCSI target during volume detach.
>
> Since this is a third-party overlay and not an official CloudStack release, I recommend testing it first before applying it in production.
>
> Please share the following so we can confirm whether it matches your environment:
>
> - Exact CloudStack version
> - KVM host OS
> - Storage model
> - Whether the hosts are using iSCSI only
> - Current primary storage provider configuration
> - Related management-server and KVM agent errors
>
> Once I have these details, I can review the safest next step.
>
> GitHub link: https://github.com/apache/cloudstack/discussions/14032#discussioncomment-18593918
>
> ----
> This is an automatically sent email for users@cloudstack.apache.org.
> To unsubscribe, please send an email to: users-unsubscribe@cloudstack.apache.org

Re: [D] iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM [cloudstack]

Posted by "nickaccuweb (via GitHub)" <gi...@apache.org>.
GitHub user nickaccuweb added a comment to the discussion: iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM

@dahampere 

Thank you for sharing the details.

I reviewed the overlay, and it appears relevant for CloudStack environments where Primera / Alletra storage is connected to KVM hosts through iSCSI instead of Fibre Channel.

The issue is that the default KVM storage scripts mainly rescan Fibre Channel paths, so an iSCSI-presented LUN may not be detected correctly. The overlay changes the discovery process to use the existing iSCSI sessions and also avoids disconnecting the shared iSCSI target during volume detach.

Since this is a third-party overlay and not an official CloudStack release, I recommend testing it first before applying it in production.

Please share the following so we can confirm whether it matches your environment:

- Exact CloudStack version
- KVM host OS
- Storage model
- Whether the hosts are using iSCSI only
- Current primary storage provider configuration
- Related management-server and KVM agent errors

Once I have these details, I can review the safest next step.

GitHub link: https://github.com/apache/cloudstack/discussions/14032#discussioncomment-18593918

----
This is an automatically sent email for users@cloudstack.apache.org.
To unsubscribe, please send an email to: users-unsubscribe@cloudstack.apache.org


Re: [D] iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM [cloudstack]

Posted by "nickaccuweb (via GitHub)" <gi...@apache.org>.
GitHub user nickaccuweb added a comment to the discussion: iSCSI overlay for Primera / Alletra Storage MP on CloudStack 4.22.1.1 KVM

@dahampere,

Thank you for sharing the details and screenshots.

I have reviewed the setup, and it looks good. The Alletra MP storage is working properly with CloudStack 4.22.1.1, and the disk migration and backup operations are also completing successfully.

I agree that having this included in the main CloudStack code would make future upgrades and patching easier. For now, I recommend keeping the current tested setup and revalidating the overlay before any CloudStack upgrade.

GitHub link: https://github.com/apache/cloudstack/discussions/14032#discussioncomment-18660509

----
This is an automatically sent email for users@cloudstack.apache.org.
To unsubscribe, please send an email to: users-unsubscribe@cloudstack.apache.org