Hitachi Quick Reference Guide
Hitachi Quick Reference Guide
Version 3.16.1
MK-92ADPTR142-22
October 2025
© 2024, 2025 Hitachi Vantara, Ltd. All rights reserved.
No part of this publication may be reproduced or transmitted in any form or by any means, electronic or mechanical, including copying and recording,
or stored in a database or retrieval system for commercial purposes without the express written permission of Hitachi, Ltd., Hitachi Vantara, Ltd., or
Hitachi Vantara LLC (collectively “Hitachi”). Licensee may make copies of the Materials provided that any such copy is: (i) created as an essential step
in utilization of the Software as licensed and is used in no other manner; or (ii) used for archival purposes. Licensee may not make any other copies of
the Materials. “Materials” mean text, data, photographs, graphics, audio, video and documents.
Hitachi reserves the right to make changes to this Material at any time without notice and assumes no responsibility for its use. The Materials contain
the most current information available at the time of publication.
Some of the features described in the Materials might not be currently available. Refer to the most recent product announcement for information about
feature and product availability, or contact Hitachi Vantara LLC at [Link]
Notice: Hitachi products and services can be ordered only under the terms and conditions of the applicable Hitachi agreements. The use of Hitachi
products is governed by the terms of your agreements with Hitachi Vantara LLC.
By using this software, you agree that you are responsible for:
1. Acquiring the relevant consents as may be required under local privacy laws or otherwise from authorized employees and other individuals; and
2. Verifying that your data continues to be held, retrieved, deleted, or otherwise processed in accordance with relevant laws.
Notice on Export Controls. The technical data and technology inherent in this Document may be subject to U.S. export control laws, including the
U.S. Export Administration Act and its associated regulations, and may be subject to export or import regulations in other countries. Reader agrees to
comply strictly with all such regulations and acknowledges that Reader has the responsibility to obtain licenses to export, re-export, or import the
Document and any Compliant Products.
Hitachi and Lumada are trademarks or registered trademarks of Hitachi, Ltd., in the United States and other countries.
AIX, DB2, DS6000, DS8000, Enterprise Storage Server, eServer, FICON, FlashCopy, GDPS, HyperSwap, IBM, OS/390, PowerHA, PowerPC, S/390,
System z9, System z10, Tivoli, z/OS, z9, z10, z13, z14, z15, z16, z/VM, and z/VSE are registered trademarks or trademarks of International Business
Machines Corporation.
Active Directory, ActiveX, Bing, Excel, Hyper-V, Internet Explorer, the Internet Explorer logo, Microsoft, Microsoft Edge, the Microsoft corporate logo,
the Microsoft Edge logo, MS-DOS, Outlook, PowerPoint, SharePoint, Silverlight, SmartScreen, SQL Server, Visual Basic, Visual C++, Visual Studio,
Windows, the Windows logo, Windows Azure, Windows PowerShell, Windows Server, the Windows start button, and Windows Vista are registered
trademarks or trademarks of Microsoft Corporation. Microsoft product screen shots are reprinted with permission from Microsoft Corporation.
All other trademarks, service marks, and company names in this document or website are properties of their respective owners.
The open source content used in Hitachi Vantara products may be found within the Product documentation or you may request a copy of such
information (including source code and/or modifications to the extent the license for any open source requires Hitachi make it available) by sending an
email to OSS_licensing@[Link].
Preface......................................................................................................6
Product version....................................................................................................6
Release notes......................................................................................................6
Conventions for capacity values.......................................................................... 6
Storage model abbreviations............................................................................... 7
Accessing product documentation.......................................................................9
Getting help..........................................................................................................9
Comments..........................................................................................................10
Chapter 1: Overview................................................................................11
About Hitachi Storage Plug-in for Containers.................................................... 11
About the environment setup tasks................................................................... 12
Requirements.....................................................................................................12
Container orchestrators to be supported......................................................13
Server requirements.....................................................................................13
Storage requirements...................................................................................13
Network requirements.................................................................................. 15
Pre-installation tasks..........................................................................................15
Server pre-installation...................................................................................15
Device Mapper Multipath settings........................................................... 19
Native NVMe Multipath settings.............................................................. 21
Storage pre-installation for VSP family and VSP One Block........................ 22
Host group and iSCSI target naming rules............................................. 24
Storage pre-installation for VSP One SDS Block......................................... 25
Multitenancy functionality settings.......................................................... 25
Chapter 2: Installation............................................................................. 27
Installation on OpenShift....................................................................................27
Installation on Kubernetes................................................................................. 28
Configuration of Storage Plug-in for Containers instance..................................29
Environment variables....................................................................................... 31
Chapter 3: Usage....................................................................................33
Secret settings................................................................................................... 33
StorageClass settings........................................................................................34
Contents
Hitachi Storage Plug-in for Containers Quick Reference Guide 3
PersistentVolumeClaim settings........................................................................ 38
Pod settings....................................................................................................... 39
Command examples..........................................................................................40
Raw block volume..............................................................................................43
ReadWriteMany................................................................................................. 45
ReadOnlyMany.................................................................................................. 45
Resource partitioning.........................................................................................46
Static provisioning..............................................................................................51
Requirements for using static provisioning...................................................51
Creating Secret and StorageClass...............................................................52
Creating a PV............................................................................................... 52
Creating a PVC.............................................................................................60
Cloning a PVC..............................................................................................62
Creating a snapshot for a PVC.....................................................................63
Expanding storage volume for a PVC.......................................................... 66
Troubleshooting when using static provisioning........................................... 67
Stretched PVC................................................................................................... 69
Requirements for using the Stretched PVC feature..................................... 69
Creating a Stretched PVC............................................................................ 73
Checking information on Stretched PVCs.................................................... 75
Creating a Stretched PVC with Adaptive Data Reduction (ADR)................. 75
Expanding storage volumes for a Stretched PVC........................................ 76
Creating snapshots for a Stretched PVC..................................................... 77
Creating a clone from a Stretched PVC....................................................... 77
Connecting a Stretched PVC to a Pod......................................................... 78
Deleting a Stretched PVC............................................................................ 79
Forcibly deleting a Stretched PVC............................................................... 79
Failover.........................................................................................................79
Troubleshooting............................................................................................80
Chapter 4: Upgrade.................................................................................81
Upgrade on OpenShift....................................................................................... 81
Upgrade on Kubernetes.....................................................................................81
Chapter 5: Re-creation............................................................................83
Deleting Storage Plug-in for Containers............................................................ 83
Re-creating Storage Plug-in for Containers....................................................... 83
Chapter 6: Uninstallation.........................................................................84
Uninstallation on OpenShift............................................................................... 84
Uninstallation on Kubernetes.............................................................................84
Contents
Hitachi Storage Plug-in for Containers Quick Reference Guide 4
Chapter 7: Troubleshooting.....................................................................85
Collecting information for troubleshooting......................................................... 85
Information needed when contacting support.............................................. 85
Collecting logs for Storage Plug-in for Containers....................................... 86
Collecting storage system information for VSP family and VSP One
Block.............................................................................................................87
Collecting storage system information for VSP One SDS Block.................. 87
Viewing the volume properties of PersistentVolume..........................................88
Notes on forcibly deleting a Pod........................................................................ 88
Creating and deleting PersistentVolumeClaim simultaneously .........................89
Host group settings............................................................................................89
Timeout errors when creating or deleting Pods................................................. 90
Unable to schedule or create a Kubernetes pod............................................... 90
Contents
Hitachi Storage Plug-in for Containers Quick Reference Guide 5
Preface
Hitachi Storage Plug-in for Containers lets you create containers and run stateful applications
inside those containers by using the Hitachi storage volumes as dynamically provisioned
persistent volumes. This Quick Reference Guide provides an implementation overview and
describes the usage requirements, installation, and configuration of Storage Plug-in for
Containers.
Please read this document carefully to understand how to install and use the plug-in, and
maintain a copy for your reference.
Product version
This document applies to Hitachi Storage Plug-in for Containers version 3.16.0.
Release notes
Read the release notes before installing and using this product. They may contain
requirements or restrictions that are not fully described in this document or updates or
corrections to this document. Release notes are available on the Hitachi Vantara
documentation website: [Link]
Preface
Hitachi Storage Plug-in for Containers Quick Reference Guide 6
Storage model abbreviations
■ VSP F1500
■ VSP G1000
■ VSP G1500
Preface
Hitachi Storage Plug-in for Containers Quick Reference Guide 7
Storage model abbreviations
Preface
Hitachi Storage Plug-in for Containers Quick Reference Guide 8
Accessing product documentation
VSP One SDS Block Hitachi Virtual Storage Platform One SDS Block
Getting help
The Hitachi Vantara Support Website is the destination for technical support of products and
solutions sold by Hitachi Vantara. To contact technical support, log on to the Hitachi Vantara
Support Website. For additional contact methods, go to [Link]
[Link].
Hitachi Vantara Community is a global online community for Hitachi Vantara customers,
partners, independent software vendors, employees, and prospects. It is the destination to
get answers, discover insights, and make connections. Join the conversation today! Go to
[Link], register, and complete your profile.
Preface
Hitachi Storage Plug-in for Containers Quick Reference Guide 9
Comments
Comments
Please send comments to [Link]@[Link]. Include the document title and
number, including the revision level (for example, -07), and refer to specific sections and
paragraphs whenever possible. All comments become the property of Hitachi Vantara LLC.
Thank you!
Preface
Hitachi Storage Plug-in for Containers Quick Reference Guide 10
Chapter 1: Overview
Storage Plug-in for Containers is software for creating and managing persistent volumes for
Hitachi storage systems in a Kubernetes environment. By using Storage Plug-in for
Containers, you can use Hitachi storage volumes from stateful applications running on
Kubernetes. For persistent volumes, in addition to creation and deletion, operations such as
snapshots and clones are supported.
The following table lists and describes the components of Storage Plug-in for Containers.
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 11
About the environment setup tasks
Component Purpose
Procedure
1. Check and apply the requirements for the server (where you plan to install Storage Plug-
in for Containers, Kubernetes, and OpenShift), Hitachi storage systems, Kubernetes,
OpenShift, Rancher Kubernetes Engine 2, and Amazon EKS.
2. Set up the Kubernetes or the OpenShift environment.
3. Configure the supported storage systems using the appropriate protocol to enable
communication with Kubernetes or Open Shift.
4. Install Storage Plug-in for Containers.
Requirements
Before you install Storage Plug-in for Containers, check that the system requirements meet
the following minimum requirements.
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 12
Container orchestrators to be supported
Rancher Kubernetes Engine 1.30, 1.31, 1.32, and 1.33 If you use RKE2, any
2 (RKE2) mention of Kubernetes in
this guide must be referred
to as RKE2.
Amazon Elastic Kubernetes 1.30, 1.31, 1.32, and 1.33 If you use EKS, any mention
Service (EKS) of Kubernetes in this guide
must be referred to as EKS.
Server requirements
Component Requirement
CPU x86_64
Storage requirements
Storage requirements for VSP family and VSP One Block.
Component Requirement
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 13
Storage requirements
Component Requirement
Component Requirement
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 14
Network requirements
Component Requirement
Network requirements
The network requirements for Storage Plug-in for Containers are as follows:
■ Storage Plug-in for Containers uses the following ports. Use this information for reference
when configuring the firewall.
■ Storage Plug-in for Containers does not support IPv6. Use IPv4.
Pre-installation tasks
Before you install Storage Plug-in for Containers, review and apply the server and storage
pre-installation requirements.
Server pre-installation
The following table outlines the pre-installation tasks for each server component.
If you are using VSP One SDS Block, for information on the server settings, see the VSP
One SDS Block manual.
Component Tasks
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 15
Server pre-installation
Component Tasks
Note:
Storage Plug-in for Containers does
not support IQNs that include
uppercase alphabetic characters.
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 16
Server pre-installation
Component Tasks
NVMe over FC connection. The method for
specifying settings differs depending on the OS.
■ Ubuntu
Using the following command, install the nvme-
cli tool:
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 17
Server pre-installation
Component Tasks
Note:
■ Do not change a host NQN while
the host is running. However, if a
change while the host is running is
necessary, perform the drain
operation on the relevant node, and
then change the host NQN. After
changing the host NQN, restart the
host.
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 18
Device Mapper Multipath settings
Component Tasks
Note:
■ Do not change a host NQN while
the host is running. However, if a
change while the host is running is
necessary, perform the drain
operation on the relevant node, and
then change the host NQN. After
changing the host NQN, restart the
host.
Multipath function For Fibre Channel and iSCSI, use Device Mapper
Multipath. For NVMe over FC and NVMe/TCP, use
Native NVMe Multipath.
For details on multipath function settings, see
Device Mapper Multipath settings (on page 19) or
Native NVMe Multipath settings (on page 21).
defaults {
user_friendly_names yes
find_multipaths yes
}
blacklist {
}
If you are using VSP One SDS Block, for information on settings specific to VSP One SDS
Block, see the VSP One SDS Block manual, and check the sections describing the operating
environment settings and the ALUA settings.
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 19
Device Mapper Multipath settings
Note: The setting values might differ depending on the environment. Also see the
documentation for your OS.
■ Red Hat Enterprise Linux 7: [Link]
red_hat_enterprise_linux/7/html/dm_multipath/mpio_setup
■ Red Hat Enterprise Linux 8: [Link]
red_hat_enterprise_linux/8/html/configuring_device_mapper_multipath/
configuring-dm-multipath_configuring-device-mapper-multipath
■ Red Hat Enterprise Linux 9: [Link]
red_hat_enterprise_linux/9/html/configuring_device_mapper_multipath/
configuring-dm-multipath_configuring-device-mapper-multipath
■ Ubuntu: [Link]
introduction
For OpenShift, you will need to use the MachineConfig YAML file. For details, see the official
documentation: [Link]
[Link]
For OpenShift, the following is an example of the procedure:
Procedure
1. Obtain [Link] from the provided sample files.
defaults {
user_friendly_names yes
find_multipaths yes
}
blacklist {
}
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 20
Native NVMe Multipath settings
apiVersion: [Link]/v1
kind: MachineConfig
metadata:
name: multipath-machineconfig-sample
labels:
[Link]/role: worker
spec:
config:
ignition:
version: 3.2.0
storage:
files:
- contents:
source: data:text/plain;charset=utf-8;base64,
ZGVmYXVsdHMgewp1c2VyX2ZyaWVuZGx5X25hbWVzIHllcwpmaW5kX211bHRpcGF0aHMgeWVzCn0K
YmxhY2tsaXN0IHsKfQo=
verification: {}
filesystem: root
mode: 400
path: /etc/[Link]
# oc apply -f [Link]
4. On each compute node, open /etc/[Link] and verify that the settings
have been applied.
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 21
Storage pre-installation for VSP family and VSP One Block
If you are using VSP One SDS Block, for information on settings specific to VSP One SDS
Block, see the VSP One SDS Block manual, and check the sections describing the operating
environment settings.
Component Task
Fibre Channel Use a Fibre Channel switch for communication between the
connection storage and servers. Set the following parameters for storage ports
using Element Manager for Block 20:
■ Connection Type: P-to-P
■ Fabric: ON
■ Security: Enabled
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 22
Storage pre-installation for VSP family and VSP One Block
Component Task
Storage Plug-in for Containers automatically performs the following
actions:
■ Creates host groups for each host if there is no host group.
If you want to use existing host groups, rename them according
to the naming rule (see Host group and iSCSI target naming
rules (on page 24)).
■ Adds the WWNs for all of the HBA ports in each host to the host
group created for each host.
NVMe over FC Create an NVM subsystem to manage the path between the host
connection and storage system.
The NVM subsystem must be dedicated to Storage Plug-in for
Containers. Do not use the NVM subsystem used for Storage Plug-
in for Containers for any purpose other than Storage Plug-in for
Containers.
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 23
Host group and iSCSI target naming rules
Component Task
1. Create the NVM subsystem for the storage system. Enable
the namespace security, and specify Linux as the host mode.
2. Set the operation mode of the Fibre Channel port to NVMe
mode.
3. Disable LUN security on the Fibre Channel port.
4. Set an NVM subsystem port.
For details about each of the above steps, see the Provisioning
Guide for Open Systems or Provisioning Guide.
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 24
Storage pre-installation for VSP One SDS Block
Component Task
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 25
Multitenancy functionality settings
Component Task
Chapter 1: Overview
Hitachi Storage Plug-in for Containers Quick Reference Guide 26
Chapter 2: Installation
This chapter describes how to install Storage Plug-in for Containers. The installation method
depends on whether your environment is OpenShift or Kubernetes.
Installation on OpenShift
Storage Plug-in for Containers is easily deployed to OpenShift using the Operator, which can
be installed from OperatorHub. To install Storage Plug-in for Containers, follow the steps
below.
Note:
■ If there is a previous version of Storage Plug-in for Containers, remove it
before performing the installation procedure.
■ If you want to install Storage Plug-in for Containers in an OpenShift Container
Platform environment that does not have access to the internet, mirror the
certified-operators catalog in advance. For details on the procedure, see
[Link]
[Link]#olm-mirror-catalog_installing-
mirroring-installation-images.
For example, for OpenShift Container Platform version 4.10, the index image
of the certified-operators catalog is [Link]/redhat/certified-operator-
index:v4.10. For details, see [Link]
latest/operators/understanding/[Link].
Procedure
1. Access OperatorHub from the OpenShift web console.
2. Search Hitachi Storage Plug-in for Containers and install the Operator.
Chapter 2: Installation
Hitachi Storage Plug-in for Containers Quick Reference Guide 27
Installation on Kubernetes
Installation on Kubernetes
For Kubernetes, you can install Storage Plug-in for Containers using Operator. To install
Storage Plug-in for Containers, perform the following procedure.
Procedure
1. Create a clone of [Link] and then move
to the target Storage Plug-in for Containers version.
2. Create the namespace for the Operator, confirm that the namespace was created
succesfully for the Operator:
Note: Verify that the namespace is used in all plugin configurations and
operations.
4. If you want to change the Storage Plug-in for Containers settings, edit
hspc_v1_hspc.yaml.
On the namespace specified in hspc_v1_hspc.yaml, Storage Plug-in for Containers
is created. Change the settings as necessary.
If you want to make an advanced configuration, refer to Configuration of Storage Plug-in
for Containers instance (on page 29).
Chapter 2: Installation
Hitachi Storage Plug-in for Containers Quick Reference Guide 28
Configuration of Storage Plug-in for Containers instance
5. Create a Storage Plug-in for Containers instance, and confirm that READY is true.
Parameter Description
Chapter 2: Installation
Hitachi Storage Plug-in for Containers Quick Reference Guide 29
Configuration of Storage Plug-in for Containers instance
Parameter Description
Chapter 2: Installation
Hitachi Storage Plug-in for Containers Quick Reference Guide 30
Environment variables
Parameter Description
Environment variables
The following is the environment variable of hspc-csi-driver on hpsc-csi-
controller:
Chapter 2: Installation
Hitachi Storage Plug-in for Containers Quick Reference Guide 31
Environment variables
apiVersion: [Link]/v1
kind: HSPC
metadata:
name: hspc
namespace: <Storage-Plug-in-for-Containers-namespace>
spec:
controller:
containers:
- name: hspc-csi-driver
env:
- name: SPC_VERIFY_CERTIFICATE
value: "true"
3. Uninstall and reinstall Storage Plug-in for Containers. For more information on how to
uninstall and reinstall Storage Plug-in for Containers, see Installation (on page 27) and
Uninstallation (on page 84).
4. Check the changes.
Chapter 2: Installation
Hitachi Storage Plug-in for Containers Quick Reference Guide 32
Chapter 3: Usage
This chapter describes the settings and command examples for each component used in
Storage Plug-in for Containers.
The procedures that follow are performed by using sample files.
Secret settings
The Secret file contains the storage URL, user name, password, and host mode settings that
are necessary for Storage Plug-in for Containers to work with your environment. The
following sample provides information about the required parameters.
apiVersion: v1
kind: Secret
metadata:
name: secret-sample #(1)
type: Opaque
data:
url: aHR0cDovLzE3Mi4xNi4xLjE= #(2)
user: VXNlcjAx #(3)
password: UGFzc3dvcmQwMQ== #(4)
hostModeOptions: ODgsODENCg== #(5)
Legend:
(1) Secret name
(2) base64-encoded storage URL
Use the IP address of the SVP for the following: VSP 5000 series, VSP F400, F600, F800,
VSP F1500, VSP G200, G400, G600, G800, VSP G1000, VSP G1500, and VSP N400,
N600, N800.
Use the IP address of the storage controller for the following: VSP E series, VSP F350, F370,
F700, F900, and VSP G350, G370, G700, G900.
Use the service IP address for the following: VSP One B20.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 33
StorageClass settings
Example:
Note: By default, the host mode options are set to 2, 22, 25, 68, and 91. If you
need to add additional host mode options, you must specify them in the
hostModeOptions parameter in the [Link] file. You must delete and
recreate the pod to apply the user-defined host mode options.
StorageClass settings
The StorageClass file contains storage settings that are necessary for Storage Plug-in for
Containers to work with your environment. The following sample provides information about
the required parameters.
Note: After creating a StorageClass and PVC, re-creating StorageClass will not
affect the existing PVCs.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 34
StorageClass settings
apiVersion: [Link]/v1
kind: StorageClass
metadata:
name: sc-sample #(1)
annotations:
[Link]/description: Hitachi Storage Plug-in for Containers
provisioner: [Link]
reclaimPolicy: Delete
volumeBindingMode: Immediate
allowVolumeExpansion: true
parameters:
serialNumber: "54321" #(2)
poolID: "1" #(3)
portID : CL1-A,CL2-A #(4)
connectionType: fc #(5)
storageEfficiency: "CompressionDeduplication" #(6)
storageEfficiencyMode: "PostProcess" #(7)
[Link]/fstype: ext4 #(8)
[Link]/node-publish-secret-name: "secret-sample" #(9)
[Link]/node-publish-secret-namespace: "default" #(10)
[Link]/provisioner-secret-name: "secret-sample" #(9)
[Link]/provisioner-secret-namespace: "default" #(10)
[Link]/controller-publish-secret-name: "secret-sample" #(9)
[Link]/controller-publish-secret-namespace: "default" #(10)
[Link]/node-stage-secret-name: "secret-sample" #(9)
[Link]/node-stage-secret-namespace: "default" #(10)
[Link]/controller-expand-secret-name: "secret-sample" #(9)
[Link]/controller-expand-secret-namespace: "default" #(10)
Legend:
(1) StorageClass name
(2) Storage serial number
(3) HDP pool ID
(4) Port ID. Use a comma separator for multipath. If an NVMe over FC connection is used,
this specification is unnecessary.
(5) Connection type between storage and nodes. fc, iscsi, and nvme-fc are supported. If
connectionType is not specified, fc is set.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 35
StorageClass settings
Note: For VSP One B20, "Disabled" is not supported. The default is
"CompressionDeduplication".
(7) Execution mode of adaptive data reduction. You can specify this parameter when
storageEfficiency is "Compression" or "CompressionDeduplication", and
"Inline" and "PostProcess" are supported for the parameter. If
storageEfficiencyMode is not specified, adaptive data reduction runs in the default
execution mode, which depends on the storage system model. For details on the parameter,
see the description of adaptive data reduction in the Provisioning Guide for Open Systems or
Provisioning Guide.
Caution:
■ If the LDEV was created with Storage Plug-in for Containers, do not change
the parameters related to adaptive data reduction.
(8) Filesystem type. ext4 and xfs are supported. If [Link]/fstype is not
specified, ext4 is set.
(9) Secret name
(10) Secret namespace
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 36
StorageClass settings
apiVersion: [Link]/v1
kind: StorageClass
metadata:
name: sc-sample-vsp-one-sds-block #(1)
annotations:
[Link]/description: Hitachi Storage Plug-in for Containers
provisioner: [Link]
reclaimPolicy: Delete
volumeBindingMode: Immediate
allowVolumeExpansion: true
parameters:
storageType: vsp-one-sds-block #(2)
connectionType: fc #(3)
storageEfficiency: Disabled #(4)
[Link]/fstype: ext4 #(5)
[Link]/node-publish-secret-name: "secret-sample" #(6)
[Link]/node-publish-secret-namespace: "default" #(7)
[Link]/provisioner-secret-name: "secret-sample" #(6)
[Link]/provisioner-secret-namespace: "default" #(7)
[Link]/controller-publish-secret-name: "secret-sample" #(6)
[Link]/controller-publish-secret-namespace: "default" #(7)
[Link]/node-stage-secret-name: "secret-sample" #(6)
[Link]/node-stage-secret-namespace: "default" #(7)
[Link]/controller-expand-secret-name: "secret-sample" #(6)
[Link]/controller-expand-secret-namespace: "default" #(7)
Legend:
(1) StorageClass name
(2) Storage type. This parameter must be set to vsp-one-sds-block when using VSP One
SDS Block.
(3) Connection type between storage and nodes. fc, iscsi, and nvme-tcp are supported.
If connectionType is not specified, fc is set.
(4) The setting of the data reduction function for volumes. Compression and Disabled are
supported. The default is Disabled, and if Disabled is specified, the data reduction
function is disabled. If you are using the multitenancy functionality, you cannot set this
parameter. For multitenancy functionality, the data reduction function settings for volumes
comply with the VPS settings.
(5) Filesystem type. ext4 and xfs are supported. If [Link]/fstype is not
specified, ext4 is set.
(6) Secret name
(7) Secret namespace
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 37
PersistentVolumeClaim settings
PersistentVolumeClaim settings
In this section, you will configure PersistentVolumeClaim settings, which are required by
Storage Plug-in for Containers to dynamically create a new volume for a storage system.
The PersistentVolumeClaim file contains volume information that is used by Storage Plug-in
for Containers to create PersistentVolumes. The following sample provides information about
the required parameters.
Note:
■ If you want to use the existing volume of the storage system as
PersistentVolumeClaim, see Static provisioning (on page 51).
■ If you use PersistentVolumeClaim to be configured in this section and the
static provisioning function at the same time, a static PV created by following
the procedure described in Creating a PV (on page 52) must be properly
associated with a PVC by performing the procedure described in Creating a
PVC (on page 60). If you have not performed the procedure described in
Creating a PVC (on page 60), perform the following procedure before
configuring the PersistentVolumeClaim settings in this section.
1. Check PVs for which association has not been completed.
kubectl get pv
2. For PVs for which association has not been completed, check whether
claimRef is specified.
3. If there are any PVs for which claimRef is not specified, perform either
of the following procedures for each PV.
■ Re-create the static PV, specify claimRef, and then perform the
procedure described in Creating a PVC (on page 60).
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 38
Pod settings
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: pvc-sample #(1)
spec:
accessModes:
- ReadWriteOnce #(2)
resources:
requests:
storage: 1Gi #(3)
storageClassName: sc-sample #(4)
Legend:
(1) PersistentVolumeClaim name
(2) Specify ReadWriteOnce or ReadOnlyMany, or ReadWriteMany. To use
ReadOnlyMany, see ReadOnlyMany (on page 45). To use ReadWriteOnce or
ReadWriteMany, see Raw block volume (on page 43).
(3) Volume size
(4) StorageClass name
Usage restrictions for a PersistentVolumeClaim
■ If a failure occurs when creating a PersistentVolumeClaim, a PersistentVolumeClaim
object will be created without the PersistentVolume. In this case, delete the
PersistentVolumeClaim object using the kubectl delete pvc <PVC-name>
command.
■ If a failure occurs when deleting a PersistentVolumeClaim, a PersistentVolumeClaim
object will be deleted but the PersistentVolume object will remain and any storage asset
associated with the PersistentVolume object may also remain. In this case, see Viewing
the volume properties of PersistentVolume (on page 88) and obtain the volume ID of the
storage. Delete the PersistentVolume using the kubectl delete pv <PV-name>
command. Also, delete the storage asset (LDEV). For details, see the user guide for the
storage system in your environment.
Pod settings
The Pod file contains volume information. Storage Plug-in for Containers mount volumes
based on this information.
apiVersion: v1
kind: Pod
metadata:
name: pod-sample #(1)
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 39
Command examples
spec:
containers:
- name: my-busybox
image: busybox
volumeMounts:
- mountPath: "/data" #(2)
name: sample-volume
command: ["sleep", "1000000"]
imagePullPolicy: IfNotPresent
volumes:
- name: sample-volume
persistentVolumeClaim:
claimName: pvc-sample #(3)
Legend:
(1) Pod name
(2) Path (path where the volume is mounted inside a container)
(3) PersistentVolumeClaim name
Command examples
Following are examples of creating and deleting a Secret, StorageClass,
PersistentVolumeClaim, and Pod using commands in practice.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 40
Command examples
# kubectl get sc
NAME PROVISIONER AGE
sc-sample [Link] 21s
Caution: If the LDEV was created with Storage Plug-in for Containers, do not
change the nickname.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 41
Command examples
# kubectl get pv
NAME CAPACITY ACCESS MODES RECLAIM
POLICY STATUS CLAIM STORAGECLASS REASON AGE
pvc-3796f902-ed64-4636-9d25-e73e28e556f2 1Gi RWO
Delete Bound default/pvc-sample sc-sample 19h
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 42
Raw block volume
# kubectl get sc
NAME PROVISIONER AGE
sc-sample [Link] 53s
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: pvc-sample-block #(1)
spec:
accessModes:
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 43
Raw block volume
- ReadWriteOnce #(2)
volumeMode: Block
resources:
requests:
storage: 1Gi #(3)
storageClassName: sc-sample #(4)
Legend:
(1) PersistentVolumeClaim name
(2) Specify ReadWriteOnce or ReadWriteMany.
(3) Volume size
(4) StorageClass name
apiVersion: v1
kind: Pod
metadata:
name: pod-sample-block #(1)
spec:
containers:
- name: my-busybox
image: busybox
volumeDevices:
- devicePath: "/block" #(2)
name: sample-volume
command: ["sleep", "1000000"]
imagePullPolicy: IfNotPresent
volumes:
- name: sample-volume
persistentVolumeClaim:
claimName: pvc-sample-block #(3)
Legend:
(1) Pod name
(2) Path (path where the volume is mounted in the container)
(3) PersistentVolumeClaim name
Command examples
■ Create a PersistentVolumeClaim for a raw block volume:
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 44
ReadWriteMany
ReadWriteMany
You can mount a volume on one or many nodes in your Kubernetes cluster and perform read-
write operations.
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: pvc-sample-block #(1)
spec:
accessModes:
- ReadWriteMany #(2)
volumeMode: Block
resources:
requests:
storage: 7Gi #(3)
storageClassName: sc-sample #(4)
Legend:
(1) PersistentVolumeClaim name
(2) Specify ReadWriteMany.
(3) Volume size
(4) StorageClass name
ReadOnlyMany
You can mount a volume on one or many nodes in your Kubernetes cluster and perform read-
only operations.
To create a PersistentVolumeClaim with ReadOnlyMany, you must create the
PersistentVolumeClaim from an existing PVC.
Note: Use the PersistentVolumeClaim manifest file used in the Cloning a PVC
(on page 62) section and specify ReadOnlyMany, as shown in the following
example.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 45
Resource partitioning
Note: This feature is not supported in VSP One B20 and VSP One SDS Block.
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: pvc-rox-sample
spec:
dataSource:
name: pvc-sample
kind: PersistentVolumeClaim
apiGroup: ""
accessModes:
- ReadOnlyMany # Specify "ReadOnlyMany" here.
resources:
requests:
storage: 1Gi
storageClassName: sc-sample
Resource partitioning
By using this function, you can partition storage system resources for each Kubernetes
cluster.
The following are examples of resource partitioning:
■ You can restrict the range of LDEV IDs added to a resource group for a specific
Kubernetes cluster.
■ You can isolate the impacts between Kubernetes clusters.
Note: Resource partitioning is not supported for VSP One SDS Block.
Before you use the resource partitioning, the storage system settings, Secret and
StorageClass settings, are required.
Supported configurations
The following are examples of configurations in which storage system resources can be
partitioned.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 46
Resource partitioning
Unsupported configurations
The following are examples of configurations that are not supported.
Example 1
You cannot include both the following configurations in the same Kubernetes cluster.
■ StorageClass and Secret are configured for a resource group.
■ StorageClass and Secret are temporarily configured for use with meta resource.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 47
Resource partitioning
Example 2
If multiple resource groups are configured for a single storage system, each of those
resource groups cannot correspond to a resource group in the same Kubernetes
cluster.
Only one resource group (containing storageClass and Secret) per storage system
can be configured for a Kubernetes cluster.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 48
Resource partitioning
Resource group You cannot use multiple resource groups for a single
Kubernetes cluster.
Storage system user group and Storage system users must have access only to the
Storage system user resource group that you created. The storage system
user must not have access to other resource groups.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 49
Resource partitioning
Secret settings
Specify the resource group ID of the storage system.
Example of Secret settings:
apiVersion: v1
kind: Secret
metadata:
name: secret-sample
type: Opaque
data:
url: aHR0cDovLzE3Mi4xNi4xLjE=
user: VXNlcjAx
password: UGFzc3dvcmQwMQ==
stringData:
resourceGroupID: "1" # Specify resource group ID
StorageClass settings
If you use iSCSI as a storage system connection, specify the port IP address in number
order. If you use Fibre Channel or NVMe over FC as a storage system connection, no
additional setting is required for StorageClass.
Examples of StorageClass settings:
apiVersion: [Link]/v1
kind: StorageClass
metadata:
name: sc-sample
provisioner: [Link]
reclaimPolicy: Delete
volumeBindingMode: Immediate
allowVolumeExpansion: true
parameters:
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 50
Static provisioning
serialNumber: "54321"
poolID: "1"
portID : CL1-A,CL2-A
connectionType: iscsi
portIP: "[Link], [Link]" # Specify iSCSI Port IP Addresses.
<...>
Static provisioning
This function allows existing volumes in a storage system to be used as PVCs by a container
orchestrator. By using this function, you can perform operations on existing volumes in the
same way as PVCs dynamically provisioned by using Storage Plug-in for Containers.
Tip: The DRS attribute indicates the data reduction shared volume.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 51
Creating Secret and StorageClass
■ volumeType is Normal.
■ name and nickname have the same value, and their format is spc-<10-digit-
hexadecimal-number>.
You can also use a command to generate a unique character string for name. The
following is an example command:
Creating a PV
Create a PV to be associated with a PVC.
Note:
■ You can create only one PV for one volume.
If you create more than one PV for one volume, the functions supported by
Storage Plug-in for Containers might not work properly.
■ If values specified for the parameters of the PV are incorrect, an unexpected
error message might be displayed.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 52
Creating a PV
Procedure
1. Create a YAML file.
For the parameters of the PV, specify values based on the status of the target volume
and the settings of the created StorageClass. If the values specified for the parameters
do not match the actual volume status, the functions supported by Storage Plug-in for
Containers might not work properly.
Example of the YAML file for VSP family and VSP One Block:
apiVersion: v1
kind: PersistentVolume
metadata:
name: static-pv
annotations:
[Link]/provisioned-by: [Link]
spec:
persistentVolumeReclaimPolicy: Delete
accessModes:
- ReadWriteOnce
capacity:
storage: 1Gi
volumeMode: Filesystem
csi:
fsType: ext4
volumeAttributes:
connectionType: fc
ports: CL1-A, CL2-A
volumeHandle: 01--scsi--900000070010--50000--spc-c3d46c5a71
driver: [Link]
controllerExpandSecretRef:
name: secret-sample
namespace: default
controllerPublishSecretRef:
name: secret-sample
namespace: default
storageClassName: sc-sample
claimRef:
name: static-pvc
namespace: default
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 53
Creating a PV
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 54
Creating a PV
01--<IO-protocol>--<storage-
device-ID>--<LDEV-ID>--<LDEV-
nickname>
<IO-protocol>
Specify the value as follows:
■ If fc or iscsi is
specified for
connectionType: scsi
■ If nvme-fc is specified
for connectionType:
nvme
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 55
Creating a PV
<LDEV-ID>
Check these values by using
the storage system
management software.
<LDEV-nickname>
Check these values by using
the storage system
management software.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 56
Creating a PV
apiVersion: v1
kind: PersistentVolume
metadata:
name: static-pv
annotations:
[Link]/provisioned-by: [Link]
spec:
persistentVolumeReclaimPolicy: Delete
accessModes:
- ReadWriteOnce
capacity:
storage: 1Gi
volumeMode: Filesystem
csi:
fsType: ext4
volumeAttributes:
connectionType: fc
volumeHandle: 60060e8116602000601660200000004f--spc-909b93359a--4026f840-e15e-
4410-a37f-3862072c10ba
driver: [Link]
controllerExpandSecretRef:
name: secret-sample
namespace: default
controllerPublishSecretRef:
name: secret-sample
namespace: default
storageClassName: sc-sample-vsp-one-sds-block
claimRef:
name: static-pvc
namespace: default
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 57
Creating a PV
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 58
Creating a PV
<volume-naaId>--<volume-name>--
<volume-id>
<volume-naaId>
naaId of the target volume
<volume-name>
name of the target volume
<volume-id>
id of the target volume
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 59
Creating a PVC
Creating a PVC
Create a PVC so that Storage Plug-in for Containers functions can be used.
Procedure
1. Create a YAML file.
Example of the YAML file:
The following shows examples for VSP family or VSP One Block.
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: static-pvc
namespace: default
spec:
accessModes:
- ReadWriteOnce
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 60
Creating a PVC
resources:
requests:
storage: 1Gi
storageClassName: sc-sample
volumeMode: Filesystem
volumeName: static-pv
Parameters:
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 61
Cloning a PVC
Cloning a PVC
This feature can create a duplicate as a clone of an existing volume. A clone can be
consumed in the same way as any standard volume.
Note:
■ If the volume is expanded, confirm for completion before executing this
feature. Refer to Expanding storage volume for a PVC (on page 66) for
details.
■ Flush the data before cloning for data consistency. For example, temporarily
remove the Pod.
■ This feature is not supported in VSP One B20 and VSP One SDS Block.
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: pvc-from-pvc-sample #(1)
spec:
dataSource:
name: pvc-sample #(2)
kind: PersistentVolumeClaim
apiGroup: ""
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi #(3)
storageClassName: sc-sample #(4)
Legend:
(1) PersistentVolumeClaim name of clone
(2) PersistentVolumeClaim name of source
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 62
Creating a snapshot for a PVC
(3) Specify the size of the source volume. Obtain the size by using the kubectl get pv
<PV-name> -o yaml command, which is displayed in size.
(4) Specify the same StorageClass name as the one used for dataSource.
Command examples
■ Create a PersistentVolumeClaim for a clone:
Note:
■ If the volume has been expanded, verify that the operation has successfully
completed before creating the volume snapshot. See Expanding storage
volume for a PVC (on page 66) for more details.
■ Flush the data before creating a snapshot for data consistency. For example,
temporarily remove the Pod.
■ This feature is not supported on VSP One SDS Block.
Note: If Snapshot Alpha or Beta CRDs are present in your environment, remove
them before installing Snapshot v1 CRDs.
apiVersion: [Link]/v1
kind: VolumeSnapshotClass
metadata:
name: snapshotclass-sample #(1)
driver: [Link]
deletionPolicy: Delete
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 63
Creating a snapshot for a PVC
parameters:
poolID: "1" #(2)
[Link]/snapshotter-secret-name: "secret-sample" #(3)
[Link]/snapshotter-secret-namespace: "default" #(4)
Legend:
(1) VolumeSnapshotClass name
(2) Same poolID as the StorageClass
(3) Same Secret name as the StorageClass
(4) Same Secret namespace as the StorageClass
apiVersion: [Link]/v1
kind: VolumeSnapshot
metadata:
name: snapshot-sample #(1)
spec:
volumeSnapshotClassName: snapshotclass-sample #(2)
source:
persistentVolumeClaimName: pvc-sample #(3)
Legend:
(1) VolumeSnapshot name
(2) VolumeSnapshotClass name
(3) PersistentVolumeClaim name from which the snapshot is obtained
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 64
Creating a snapshot for a PVC
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: pvc-from-snapshot-sample #(1)
spec:
dataSource:
name: snapshot-sample #(2)
kind: VolumeSnapshot
apiGroup: [Link]
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi #(3)
storageClassName: sc-sample #(4)
Legend:
(1) PersistentVolumeClaim name
(2) VolumeSnapshot name
(3) Specify the size of the source volume. Obtain the size by using the kubectl get pv
<PV-name> -o yaml command, which is displayed in size.
(4) Specify the same StorageClass name as the one used for dataSource.
Command examples
■ Create a VolumeSnapshotClass:
■ Create a VolumeSnapshot:
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 65
Expanding storage volume for a PVC
Note: If readyToUse is false, confirm the cause and solution by following the
steps:
1. Obtain the boundVolumeSnapshotContentName by using the
command: kubectl get volumesnapshot -o yaml
2. Confirm the error message by using the command: kubectl describe
volumesnapshotcontent <VolumeSnapshotContentName>
■ Create a PersistentVolumeClaim from a snapshot:
Caution:
■ Confirm completion of volume expansion with the kubectl get pvc
command, which is displayed in CAPACITY. Do not shut down the OS or drain
the node before volume expansion completes.
■ In NVMe over FC and NVMe/TCP, volume expansion in the state in which the
PVC is attached to a host is not supported. Expand a volume in the state in
which the PVC is detached from the host.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 66
Troubleshooting when using static provisioning
Command examples
■ Expand the capacity of an existing volume pvc-sample to 5GiB:
Caution:
■ Use the kubectl command to change the size of an LDEV created with
Storage Plug-in for Containers.
■ After you apply the patch for volume expansion, the volume capacity
increases. However, the PVC capacity might not be updated if it is not
attached to a Pod. You must expand the filesystem from within the node.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 67
Troubleshooting when using static provisioning
3. If you need to delete the volume, use the management software for the storage system
to delete it.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 68
Stretched PVC
To delete the volume, use the management software for the storage system to delete it.
Stretched PVC
The Stretched PersistentVolumeClaim (PVC) feature automates the provisioning of
synchronous replication between the storage system at each site in a single Kubernetes or
OpenShift cluster that spans two sites. By using this feature, you can build a high-availability
cluster that includes storage systems at two sites.
The provisioning of synchronous replication for conventional systems requires the storage
system administrator, cluster administrator, and user to cooperate closely. By using the
Stretched PVC feature, the cluster administrator and user can perform the provisioning of
synchronous replication by themselves by using the command line tool for Kubernetes or
OpenShift.
The following figure gives an overview of a cluster environment in which Stretched PVC is
installed.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 69
Requirements for using the Stretched PVC feature
Item Description
REST API connection Specify settings so that Storage Plug-in for Containers
can communicate with the storage systems at the
primary site and at the secondary site by using the
REST API.
Data path connection Specify settings so that each node can perform data
communication with the storage systems at the
primary site and at the secondary site. Only Fibre
Channel is supported for communication between
nodes and storage systems.
The following is an overview of connecting the server and storage systems in a stretched
cluster.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 70
Requirements for using the Stretched PVC feature
Item Description
Virtual storage machines For each storage system, create one virtual storage
machine. The virtual storage machine must meet the
following requirements:
■ At the primary site and the secondary site, specify the
same serial number and model for the virtual storage
machines. Note that a virtual storage machine is also
required at the primary site.
■ For the model of the virtual storage machines, specify
any storage system model supported by the
Stretched PVC feature.
■ Use the virtual storage machines only for Storage
Plug-in for Containers. Do not use the virtual storage
machines for other purposes.
Note the following when using the same combination of
storage systems from multiple clusters:
■ For each cluster, use the same storage system users
and virtual storage machines.
■ Make sure that the combination of the storage
system set for the primary site and the storage
system set for the secondary site for each cluster
matches each other.
Users and user groups Create a user group with access only to the virtual
storage machine's resource group and add users to it.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 71
Requirements for using the Stretched PVC feature
Item Description
Host groups For each port that you want to use, assign the required
number of unused host group IDs for the virtual storage
machines. The number of host group IDs must be at
least the total number of hosts + 1.
Remote paths Create remote paths. The same path group ID must be
used for both the primary site and the secondary site.
Quorum disks Create quorum disks. The same quorum disk ID must be
used for both the primary site and the secondary site.
Item Description
When connecting to a Pod, if you want to control the site to which the Pod will be deployed,
use the Node Affinity or Node Selector feature of Kubernetes and OpenShift.
Volume snapshot Yes (For details about how to use it, see Creating a
clone from a Stretched PVC (on page 77).)
Volume cloning Yes (For details about how to use it, see Creating a
clone from a Stretched PVC (on page 77).)
ReadWriteMany Yes
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 72
Creating a Stretched PVC
ReadOnlyMany Yes
Procedure
1. Create a Secret specifically for the Stretched PVC. A sample (secret-sample-
[Link]) can be found in the yaml directory.
apiVersion: v1
kind: Secret
metadata:
name: secret-sample-stretched
type: Opaque
stringData:
primarySerial: "11111" #(1)
primaryURL : [Link] #(2)
primaryUser : primary-user #(3)
primaryPassword : primary-password #(4)
secondarySerial: "22222" #(5)
secondaryURL : [Link] #(6)
secondaryUser : secondary-user #(7)
secondaryPassword : secondary-password #(8)
Legend:
(1) Serial number of the storage system at the primary site
(2) URL of the REST API of the storage system at the primary site
(3) User of the storage system at the primary site
(4) User password for the storage system at the primary site
(5) Serial number of the storage system at the secondary site
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 73
Creating a Stretched PVC
(6) URL of the REST API of the storage system at the secondary site
(7) User of the storage system at the secondary site
(8) User password for the storage system at the secondary site
apiVersion: [Link]/v1
kind: StorageClass
metadata:
name: sc-sample-stretched
annotations:
[Link]/description: Hitachi Storage Plug-in for Containers
provisioner: [Link]
reclaimPolicy: Delete
volumeBindingMode: Immediate
allowVolumeExpansion: true
parameters:
connectionType: fc
replicationType: stretched #(1)
quorumID: "30" #(2)
primaryPoolID: "10" #(3)
primaryPortID: CL1-A,CL2-A #(4)
secondaryPoolID: "20" #(5)
secondaryPortID: CL1-F #(6)
[Link]/node-publish-secret-name: "secret-sample-stretched"
[Link]/node-publish-secret-namespace: "default"
[Link]/provisioner-secret-name: "secret-sample-stretched"
[Link]/provisioner-secret-namespace: "default"
[Link]/controller-publish-secret-name: "secret-sample-stretched"
[Link]/controller-publish-secret-namespace: "default"
[Link]/node-stage-secret-name: "secret-sample-stretched"
[Link]/node-stage-secret-namespace: "default"
[Link]/controller-expand-secret-name: "secret-sample-stretched"
[Link]/controller-expand-secret-namespace: "default"
Legend:
(1) Parameter indicating that the replication type is Stretched PVC
(2) ID of the Quorum disk
(3) Pool ID of the storage system at the primary site
(4) Port ID of the storage system at the primary site
(5) Pool ID of the storage system at the secondary site
(6) Port ID of the storage system at the secondary site
3. Create a PVC by specifying the created StorageClass.
4. Display the created PVC to make sure that STATUS is Bound.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 74
Checking information on Stretched PVCs
Note: Creating a Stretched PVC takes more time than creating a regular
PVC.
Parameter Description
nickname Nickname of the created LDEV (the same for both the
primary site and the secondary site)
Procedure
1. Create a StorageClass for the Stretched PVC with ADR. You can find a sample (sc-
[Link]) file in the yaml directory.
Add the storageEfficiency and storageEfficiencyMode parameters to the
yaml file to enable ADR for a stretched PVC.
apiVersion: [Link]/v1
kind: StorageClass
metadata:
name: sc-sample-stretched-adr
annotations:
[Link]/description: Hitachi Storage Plug-in for Containers
provisioner: [Link]
reclaimPolicy: Delete
volumeBindingMode: Immediate
allowVolumeExpansion: true
parameters:
connectionType: fc
quorumID: "4"
primaryPoolID: "1"
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 75
Expanding storage volumes for a Stretched PVC
primaryPortID: CL1-A
secondaryPoolID: "2"
secondaryPortID: CL1-B
storageEfficiency: "CompressionDeduplication" #(1)
storageEfficiencyMode: "PostProcess" #(2)
[Link]/node-publish-secret-name: "secret-sample-stretched"
[Link]/node-publish-secret-namespace: "default"
[Link]/provisioner-secret-name: "secret-sample-stretched"
[Link]/provisioner-secret-namespace: "default"
[Link]/controller-publish-secret-name: "secret-sample-stretched"
[Link]/controller-publish-secret-namespace: "default"
[Link]/node-stage-secret-name: "secret-sample-stretched"
[Link]/node-stage-secret-namespace: "default"
[Link]/controller-expand-secret-name: "secret-sample-stretched"
[Link]/controller-expand-secret-namespace: "default"
Legend:
(1) The storage efficiency for ADR. The value can be
"CompressionDeduplication" or "Compression"
(2) The storage efficiency mode for ADR. The value can be "PostProcess" or
"Inline"
Note: Creating a Stretched PVC takes more time than creating a regular
PVC.
Procedure
1. Create a stretched PVC. See Creating a Stretched PVC (on page 73).
or
Create a stretched PVC with ADR. See Creating a Stretched PVC with Adaptive Data
Reduction (ADR) (on page 75).
Note:
■ Verify that the value for the allowVolumeExpansion parameter is set
to true. If the parameter is set to false, you will not be able to expand
the storage volume.
■ Verify that the GAD pair is healthy and in Pair state during volume
expansion.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 76
Creating snapshots for a Stretched PVC
Note: The storage size must be more than the PVC size for the expansion
to be successful.
Procedure
1. Create a stretched PVC. See Creating a Stretched PVC (on page 73).
or
Create a stretched PVC with ADR. See Creating a Stretched PVC with Adaptive Data
Reduction (ADR) (on page 75).
2. Create a VolumeSnapshotClass yaml file. The following is a sample yaml file:
apiVersion: [Link]/v1
kind: VolumeSnapshotClass
metadata:
name: snapshotclass-sample-stretched
driver: [Link]
deletionPolicy: Delete
parameters:
poolID: "1"
serialNumber: "715035" # Required for some volume types
[Link]/snapshotter-secret-name: "secret-sample-stretched"
[Link]/snapshotter-secret-namespace: "default"
apiVersion: [Link]/v1
kind: VolumeSnapshot
metadata:
name: VolumeSnapshot-stretched
spec:
volumeSnapshotClassName: snapshotclass-sample-stretched
source:
persistentVolumeClaimName: pvc-sample
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 77
Connecting a Stretched PVC to a Pod
Item Description
Storage system user Assign both the resource group for the virtual storage
machine used for a stretched PVC and the resource group
used for a regular PVC. Do not assign other resource
groups.
Procedure
1. Create a stretched PVC. See Creating a Stretched PVC (on page 73).
2. Create a stretched PVC [Link] Creating snapshots for a Stretched PVC (on
page 77).
3. Create a Secret for a regular PVC. See Secret settings (on page 33).
4. Create a StorageClass for a regular PVC. See StorageClass settings (on page 34).
5. Create a PVC from the stretched PVC snapshot. Enter:
Parameter references for [Link]
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: pvc-from-stretched-snapshot-sample
spec:
dataSource:
name: VolumeSnapshot-stretched
kind: VolumeSnapshot
apiGroup: [Link]
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
storageClassName: sc-sample
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 78
Deleting a Stretched PVC
When you create a Pod, the following message is output to the log of Storage Plug-in for
Containers. The log displays the serial number of the storage system that successfully
connected to the Pod. Generally, both the storage system at the primary site and the one at
the secondary site will be used. However, depending on the status of the storage systems,
only one of these storage systems (either the one at the primary site or the one at the
secondary site) might be used.
Note:
■ Deleting a Stretched PVC takes more time than deleting a regular PVC.
■ If the Stretched PVC cannot be deleted, follow the guidance provided in the
error message to determine the next steps. If the problem persists, see
Forcibly deleting a Stretched PVC (on page 79).
Procedure
1. Check the information about the resources created at the primary and secondary sites.
See Checking information on Stretched PVCs (on page 75).
2. Delete the PVC and the PV.
3. Based on the information you checked in step 1, use Storage Navigator to delete the
global-active device pair, volumes, and the associated LUNs. In addition, change the
virtual LDEV IDs of the deleted volumes to unassigned (65534).
Failover
If a failure occurs on a storage system or at a site, allocate the Pod to a different site at your
discretion. A Stretched PVC can continue to operate by using the volumes of the storage
system that is running normally.
Note: Use Element manager for Block 20 to split or resync a GAD pair.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 79
Troubleshooting
Troubleshooting
Pair status
If a failure occurs in a storage system, the global-active device pairs configuring the
Stretched PVC might have an abnormal status. If an error occurs when you are using the
Stretched PVC or a Pod connected to the Stretched PVC becomes unavailable, refer to the
Global-Active Device User Guide and perform recovery for the storage system failure and the
pair status. If recovery from the failure is difficult, by referring to Creating a clone from a
Stretched PVC (on page 77) and creating a volume clone of either the primary or secondary
storage system, you can continue to use the clone as the regular PVC.
Host failure
If a host fails, the status of the Pod run by the relevant host becomes Terminating and the
Pod has an abnormal state. If you want to use this Pod with a normal host where the failure
did not occur, do the following.
1. Forcibly delete the Pod.
2. Delete the VolumeAttachment related to the Stretched PVC that the Pod was using.
Chapter 3: Usage
Hitachi Storage Plug-in for Containers Quick Reference Guide 80
Chapter 4: Upgrade
This chapter describes how to upgrade Storage Plug-in for Containers. The upgrade method
you use depends on whether your environment is OpenShift or Kubernetes.
Note:
■ If alpha versions of VolumeSnapshotClass and VolumeSnapshot are present
in your environment, remove them before upgrading Storage Plug-in for
Containers.
■ If you are using an old version of OpenShift or Kubernetes, the latest Storage
Plug-in for Containers might not operate. If you want to use the latest Storage
Plug-in for Containers, upgrade OpenShift or Kubernetes first.
■ Before upgrading Storage Plug-in for Containers, back up the settings
configured in Configuration of Storage Plug-in for Containers instance (on
page 29). The settings that are backed up might also be used for the new
version of Storage Plug-in for Containers. If you do not have the
hspc_v1_hspc.yaml file that was used when configuring the settings, run
kubectl get hspc -A -o yaml to obtain the configured settings.
Upgrade on OpenShift
For OpenShift, you can upgrade Storage Plug-in for Containers using OpenShift web
console.
Procedure
1. Delete HSPC on the Storage Plug-in for Containers tab for Operator Details.
2. Uninstall the Operator of Storage Plug-in for Containers.
3. Install new Storage Plug-in for Containers. See Installation on OpenShift (on page 27).
Upgrade on Kubernetes
For Kubernetes, you can upgrade Storage Plug-in for Containers by following the steps
below.
Chapter 4: Upgrade
Hitachi Storage Plug-in for Containers Quick Reference Guide 81
Upgrade on Kubernetes
Procedure
1. Delete Storage Plug-in for Containers and the Operator by using the previous version
package:
2. Install new Storage Plug-in for Containers. See the topic Installation on Kubernetes (on
page 28).
Chapter 4: Upgrade
Hitachi Storage Plug-in for Containers Quick Reference Guide 82
Chapter 5: Re-creation
This chapter describes how to re-create Storage Plug-in for Containers. The re-creation
method depends on whether your environment is OpenShift or Kubernetes. To re-create
Storage Plug-in for Containers, delete Storage Plug-in for Containers, and then create it
again.
Kubernetes
Run the following command to delete the Storage Plug-in for Containers instance:
Kubernetes
Run the following command to create a Storage Plug-in for Containers instance:
Chapter 5: Re-creation
Hitachi Storage Plug-in for Containers Quick Reference Guide 83
Chapter 6: Uninstallation
This chapter describes how to uninstall Storage Plug-in for Containers. This step includes
removing any PersistentVolumeClaims, PersistentVolumes, StorageClasses, Storage Plug-in
for Containers, and other elements. The uninstallation method you use depends on whether
your environment is OpenShift or Kubernetes.
Uninstallation on OpenShift
For OpenShift, you can uninstall Storage Plug-in for Containers using OpenShift web
console.
Procedure
1. Delete all Pods which are using the volumes created by Storage Plug-in for Containers.
2. Delete the VolumeSnapshotClass, VolumeSnapshot, PersistentVolumeClaim, the
StorageClass, and the Secret that were created in relation to Storage Plug-in for
Containers.
3. Delete HSPC on the Hitachi Storage Plug-in for Containers tab of the Operator Details.
4. Uninstall the Operator of Storage Plug-in for Containers.
Uninstallation on Kubernetes
For Kubernetes, you can uninstall Storage Plug-in for Containers by following the steps
below.
Procedure
1. Delete all Pods which are using the volumes created by Storage Plug-in for Containers.
2. Delete the VolumeSnapshotClass, VolumeSnapshot, PersistentVolumeClaim, the
StorageClass, and the Secret that were created in relation to Storage Plug-in for
Containers.
3. Delete Storage Plug-in for Containers and the resources for the Operator:
Chapter 6: Uninstallation
Hitachi Storage Plug-in for Containers Quick Reference Guide 84
Chapter 7: Troubleshooting
When troubleshooting, you must understand what information to collect when an error
occurs, the cases where an error occurs, and what action to take in each case.
Information Procedure
Command execution logs Retrieve the command that you ran and the
result of running that command.
Result of running the kubectl describe Run the following command for the resource
command for the operation target resource you operated.
CSI controller logs See Collecting logs for Storage Plug-in for
Containers (on page 86).
Chapter 7: Troubleshooting
Hitachi Storage Plug-in for Containers Quick Reference Guide 85
Collecting logs for Storage Plug-in for Containers
Information Procedure
CSI node logs See Collecting logs for Storage Plug-in for
Containers (on page 86).
Application manifests Get the YAML files for applications that uses
Storage Plug-in for Containers PVCs.
1. Before retrieving logs, run the following command to check the Pod name.
Chapter 7: Troubleshooting
Hitachi Storage Plug-in for Containers Quick Reference Guide 86
Collecting storage system information for VSP family and VSP One Block
■ CSI controller
■ CSI node
Note:
■ You must specify -c hspc-csi-driver to run the command.
■ You will see multiple CSI node Pods because this is deployed as a
DaemonSet. Collect logs from all these Pods.
3. Perform the following procedure to retrieve the directories as old logs might be rotated
and removed from the retrieved logs.
a. Check the target node.
From the result of step 1, find the line where the value of NAME includes hspc-
csi-controller, and check the value of NODE in the same line.
b. Retrieve the directories stored under /var/log/pods for the node you checked in
step a.
Collecting storage system information for VSP family and VSP One
Block
If you are using an SVP, collect the regular dump files.
If you are not using an SVP, collect system dumps using the maintenance utility. For details
about how to collect the dump files of storage systems, see the System Administrator Guide.
Chapter 7: Troubleshooting
Hitachi Storage Plug-in for Containers Quick Reference Guide 87
Viewing the volume properties of PersistentVolume
Property Description
Property Description
Chapter 7: Troubleshooting
Hitachi Storage Plug-in for Containers Quick Reference Guide 88
Creating and deleting PersistentVolumeClaim simultaneously
apiVersion: [Link]/v1
kind: HSPC
metadata:
name: hspc
namespace: <Storage-Plug-in-for-Containers-namespace>
spec:
controller:
containers:
- name: csi-provisioner
args:
- --csi-address=/csi/[Link]
- --timeout=300s
- --v=5
- --worker-threads=10
- --default-fstype=ext4
Chapter 7: Troubleshooting
Hitachi Storage Plug-in for Containers Quick Reference Guide 89
Timeout errors when creating or deleting Pods
Check if the multipathd daemon is active and running. If the deamon is not in the
running state, continue to step 2.
This command starts the multipathd service immediately and verifies it when you
boot the node.
3. Load the Multipath kernel module required for device-mapper multipath. Enter:
“modprobe dm-multipath”
“multipath -ll”
Note:
■ You must reboot the node after configuring the multipath settings.
■ Verify that the storage devices used by the PersistentVolume are listed.
Chapter 7: Troubleshooting
Hitachi Storage Plug-in for Containers Quick Reference Guide 90
Hitachi Vantara
Corporate Headquarters [Link]/contact
2535 Augustine Drive
Santa Clara, CA 95054 USA