HUB
Sign inSign up
sdc logo

dellemc/sdc

By dellemc

•Updated almost 2 years ago

The PowerFlex SDC container is designed to be running on RHCOS/RHEL nodes

Image
6

1M+

dellemc/sdc repository overview

⁠SDC Container

SDC container is designed to be running on Supported OS nodes that are managed by either Openshift or Kubernetes.

The SDC container comes with SDC packages and tools inside. Its purpose is to deploy and manage the SDC service on supported nodes.

⁠Supported Environment

Supported Hosts Distribution: RedHed Enterprise Linux CoreOS (RHCOS), RedHat Enterprise Linux 7.9, RedHat Enterprise Linux 8.4, RedHat Enterprise Linux 8.6

Supported SDC version: v3.5.1 and above

Supported OpenShift version: v4.3 and above (K8s version 1.16 and above, RHCOS version 4.3 and above)

SDC container can be executed on standalone Supported OS nodes as well, using podman (docker like tool available in the Supported OS nodes). In this case, need to manage the container directly, as opposed to the OpenShift / K8s environment where the container is managed using DeamonSets

⁠SDC Container Run (docker run)

SDC container has 3 running modes, configuration, monitoring, and command mode. The configuration vs monitoring mode is determined via the MODE environment parameter. The command mode is determined once a command is passed to the container.

⁠Configuration Mode

When running in configuration mode, the container will perform configuration command and exit with status code, zero for success, and non-zero for error. Supported configuration operations:

  • Install SDC on a host
  • Upgrade & downgrade existing SDC on a host
  • Uninstall existing SDC on a host
  • Update SDC configuration on a host

During the run step, the container performs sequential operations: detects the host platform, detects the SDC service state on the host, and the parses ENV variables. Based on these, it determines which operation to perform.

⁠Monitoring Mode

When running in monitoring mode, the container runs as a 'live' container and performs passive monitoring tasks such as logs (dmesg) and metrics (network, CPU, RAM metrics) collection. Metrics collection will be done using the diag_coll service worker, similarly to a conventional setup. Logs and metrics output will be stored in the /storage mapping.

When the host's distribution is unsupported, the container in monitoring mode will run but do nothing.

⁠Command Mode

When running the command, the SDC container will not perform any configuration nor monitoring step. It will only execute the provided command. This mode is useful when interested to execute an operation using SDC support tools like get_info scripts, sdbg, drv_cfg.

⁠Run Arguments

docker run -e <environment variables> \
           --privileged \
           --network=host \
           --pid=host \
           --rm \
           -it \
           -v <mappings> \
           $(REGISTRY)$(IMAGE):$(IMAGE_TAG) \
           <command>
⁠Flags
  • -e Set of environment variables. Can set multiple variables, each variable should follow with -e flag. See environment variables section.
  • --privileged The container is running in a privileged mode so it would be able to load & unload SDC kernel module.
  • --network=host The container has access to host network, mostly relevant for metrics collection in monitoring mode.
  • --pid=host The container has access to host process, mostly relevant for metrics collection in monitoring mode.
  • --rm When the container finishes running the requested operation, the container instance is terminated with exit code.
  • it Must specify to run interactive processes (like a shell), see docker documentation⁠ for more details.
  • -v Mapping of the host's directories to the container. Can add multiple mappings, each mapping should follow with -v flag. See mappings section.
  • REGISTRY The SDC container registry.
  • IMAGE The SDC container name.
  • IMAGE_TAG The SDC container tag.
  • <command> Command to execute inside the SDC container. When provided, the SDC container runs in 'command mode'.
⁠Environment variables

NOTE: Each environment variable must be in upper case

NOTE: Variables with default value are optional

Environment Variable

MDM

Description

Use this variable to provide MDM cluster configuration. A single MDM cluster with at least one accessible IP with an active MDM service is required. MDM password is not required but once its set, the SDC container will enable SDC authentication on SDC level, e.g. will run the set_mdm_password command

Format

<IPs string> PASSWORD:<password string>

<IPs string>: MDM cluster IPs. Use ',' separator for multiple IPs
<password string>: MDM cluster password

Use "&" as a separator for multiple clusters

Example:
Single MDM cluster, no password:
127.0.0.1,127.0.0.2,127.0.0.3
Single MDM cluster, with password:
127.0.0.1,127.0.0.1,127.0.0.1 PASSWORD:AQAAAAAAAAAG+zslCAmjN/FiUBZmy3Iq7dAYNNAK1AY
Multiple MDM clusters, first cluster 3 MDM IPs, no password. Second cluster with single MDM IP and password
127.0.0.1,127.0.0.2,127.0.0.3&127.0.0.1 PASSWORD:AQAAAAAAAAAG+zslCAmjN/FiUBZmy3Iq7dAYNNAK1AY

Default Value

None


Environment Variable

REPO_ADDRESS

Description

Scini kernel modules FTP endpoint string.

When using secure FTP (SFTP) connection, the SDC container would expect additional variables and mappings. See MODULE_SIGCHECK, AUTO_FETCH_PUBLIC_KEYS variables and /config mapping in supported mappings section.

Format

<endpoint string>

Default Value

ftp://ftp.emc.com


Environment Variable

REPO_USER

Description

Scini kernel modules FTP endpoint, user name credential string

Format

<user name string>

Default Value

QNzgdxXix


Environment Variable

REPO_PASSWORD

Description

Scini kernel modules FTP endpoint, password credential string

Format

<password string>

Default Value

Aw3wFAwAq3


Environment Variable

MODULE_SIGCHECK

Description

Should the fetched modules' signatures be checked

Format

<boolean>

Default Value

1


Environment Variable

AUTO_FETCH_PUBLIC_KEYS

Description

Fetch automatically new public keys

Format

<boolean>

Default Value

0


Environment Variable

SYNC_PATTERN

Description

Sync pattern (regular expression) for massive retrieve

Format

<pattern string>

Default Value

.*


Environment Variable

INI_GUID

Description

When set, the SDC container will set the provided GUID for the SDC (INI) service. The provided value must be valid GUID.

Format

<GUID string>

Default Value

""


Environment Variable

NODENAME

Description

Hostname. It will be used to generate SDC (INI) GUID persistently across reboots. If INI_GUID is provided, this parameter will be ignored.

Format

<string>

Default Value

""


Environment Variable

UNINSTALL

Description

Boolean variable, when set, the SDC container ignores all other SDC service configuration variables and remove all the SDC related files from the host.

For uninstall to proceed, must additionally provide NODENAME or INI_GUID flag.

Format

<boolean>

Default Value

0


Environment Variable

HOST_DRV_CFG_PATH

Description

Path of drv_cfg on the host. Must be in-sync with /host-drv-cfg-path mapping.

Format

<string>

Default Value

/var/emc/scaleio


Environment Variable

MODE

Description

Execution mode of the SDC container.

Format

<mode string>
Supported modes: 'config', 'monitoring'

Default Value

config


Environment Variable

HOST_NET

Description The SDC container has access to the host network, the option --network=host parameter is provided to the run command of the container.

Format

<boolean>

Default Value

0


Environment Variable

HOST_PID

Description

The SDC container has access to the host process, the option --pid=host parameter is provided to the run command of the container.

Format

<boolean>

Default Value

0


⁠Mappings
  • /rules.d Mapping for the udev rules. Can be set to /etc/udev/rules.d directory on the host
  • /dev Direct mapping (1:1) so that the container would be able to create the scini device on the host
  • /config/* Optional, Map all the SDC config files required by the SDC service to this mapping. For example keys required by the SFTP (secure FTP) connection
Mapped FileDescription
/config/user_private_rsa_keyUser's RSA private key file
/config/user_public_rsa_keyRepository host public key
/config/emc_public_gpg_keyEMC public signature key, needed when MODULE_SIGCHECK is 1
  • /storage Persistent storage directory for the container. This will be used for driver cache, SDC service config files, SDC logs, etc.
  • /host-os-release This will be used by the container to determine the host's OS distro. Can be set to /etc/os-release file on the host
  • /host-drv-cfg-path Directory on the host where to place the drv_cfg tool which is required for udev rules. Can be set to /var/emc/scaleio. The HOST_DRV_CFG_PATH must be in sync with this mapping.
⁠Examples:

Run command example in configuration mode

docker run -e MDM="127.0.0.1" \
           --privileged \
           --rm \
           -it \
           -v /dev:/dev \
           -v /etc/os-release:/host-os-release \
           -v /var/emc/sdc-storage:/storage \
           powerflex/sdc:3.6.112

Run command example in monitoring mode

docker run -e MDM="127.0.0.1" \
           -e MODE="monitoring" \
           -e HOST_PID=1 \
           -e HOST_NET=1 \
           --privileged \
           --network=host \
           --pid=host \
           --rm \
           -d \
           --name sdc \
           -v /dev:/dev \
           -v /etc/os-release:/host-os-release \
           -v /var/emc/sdc-storage:/storage \
           powerflex/sdc:3.6.112

Note: To run the SDC container in foreground replace -d with -it

Run command example in command mode to query SDC version using the drv_cfg utility

docker run --privileged \
           --rm \
           -it \
           -v /dev:/dev \
           -v /etc/os-release:/host-os-release \
           -v /var/emc/sdc-storage:/storage \
           powerflex/sdc:3.6.112 \
           drv_cfg --query_version

⁠Host Impact by The SDC Container

⁠Scini Kernel Module

Part of the config operations, the container loads & unloads the SDC scini kernel module to the host. Hence it requires the --privileged parameter to the run command.

⁠DRV_CFG Utility and UDEV rules

Part of the config operations, the container deploys scini udev rules and drv_cfg utility on the host's file system. This is to allow nodes to run the drv_cfg utility and execute the udev rules natively.

NOTE This case is unique, in general, when need to run drv_cfg utility should run it from the SDC container context, using the command mode.

⁠Debug and Logs Collection

While in monitoring mode, the SDC container will collect host's logs and metrics (RAM, CPU, network). To be able to collect these metrics the container relies on network and PID mappings to the host --network=host --pid=host flags in run container command. The HOST_PID and HOST_NET environment variables must be set according to these mappings.

To fetch the debug files, should run the get_info.sh script packaged in the SDC container. This script creates getInfoDump.tgz file with all the relevant data.

Example on how to get getInfoDump.tgz file from live SDC container in monitoring mode to a local file

docker exec sdc bash -c "get_info.sh <<< echo user &> /dev/null; cat /tmp/scaleio-getinfo/getInfoDump.tgz" > getInfoDump.tgz

The SDC container packages inside all the standard SDC debug utilities like sdbg, drv_cfg, etc. These tools can be used the conventional way within the container context.

Example on how to run the container with bash command to be able to interact live with the SDC tools in the container

docker run --rm -it --privileged <container repo url> bash

Note: For live SDC container in monitoring mode use docker exec command instead to connect the container.

Tag summary

Content type

Image

Digest

sha256:87a72c5ad…

Size

471.6 MB

Last updated

almost 2 years ago

docker pull dellemc/sdc:3.6.5