documentation updates

This commit is contained in:
Travis Glenn Hansen 2021-02-16 16:52:19 -07:00
parent d0c3f80052
commit f41ee4e897
2 changed files with 76 additions and 12 deletions

View File

@ -45,7 +45,17 @@ Predominantly 3 things are needed:
You should install/configure the requirements for both nfs and iscsi. You should install/configure the requirements for both nfs and iscsi.
Follow the instructions here: https://netapp-trident.readthedocs.io/en/stable-v20.04/kubernetes/operations/tasks/worker.html ### nfs
```
RHEL / CentOS
sudo yum install -y nfs-utils
Ubuntu / Debian
sudo apt-get install -y nfs-common
```
### iscsi
Note that `multipath` is supported for the `iscsi`-based drivers. Simply setup Note that `multipath` is supported for the `iscsi`-based drivers. Simply setup
multipath to your liking and set multiple portals in the config as appropriate. multipath to your liking and set multiple portals in the config as appropriate.
@ -54,10 +64,51 @@ If you are running Kubernetes with rancher/rke please see the following:
- https://github.com/rancher/rke/issues/1846 - https://github.com/rancher/rke/issues/1846
```
RHEL / CentOS
# Install the following system packages
sudo yum install -y lsscsi iscsi-initiator-utils sg3_utils device-mapper-multipath
# Enable multipathing
sudo mpathconf --enable --with_multipathd y
# Ensure that iscsid and multipathd are running
sudo systemctl enable iscsid multipathd
sudo systemctl start iscsid multipathd
# Start and enable iscsi
sudo systemctl enable iscsi
sudo systemctl start iscsi
Ubuntu / Debian
# Install the following system packages
sudo apt-get install -y open-iscsi lsscsi sg3-utils multipath-tools scsitools
# Enable multipathing
sudo tee /etc/multipath.conf <<-'EOF'
defaults {
user_friendly_names yes
find_multipaths yes
}
EOF
sudo systemctl enable multipath-tools.service
sudo service multipath-tools restart
# Ensure that open-iscsi and multipath-tools are enabled and running
sudo systemctl status multipath-tools
sudo systemctl enable open-iscsi.service
sudo service open-iscsi start
sudo systemctl status open-iscsi
```
### freenas-smb ### freenas-smb
If using with Windows based machines you may need to enable guest access (even If using with Windows based machines you may need to enable guest access (even
if you are connecting with credentiasl) if you are connecting with credentials)
``` ```
Set-ItemProperty HKLM:\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters AllowInsecureGuestAuth -Value 1 Set-ItemProperty HKLM:\SYSTEM\CurrentControlSet\Services\LanmanWorkstation\Parameters AllowInsecureGuestAuth -Value 1
@ -81,7 +132,7 @@ Server preparation depends slightly on which `driver` you are using.
### FreeNAS (freenas-nfs, freenas-iscsi, freenas-smb) ### FreeNAS (freenas-nfs, freenas-iscsi, freenas-smb)
The recommended version of FreeNAS is 11.3+, however the driver should work The recommended version of FreeNAS is 12.0-U2+, however the driver should work
with much older versions as well. with much older versions as well.
Ensure the following services are configurged and running: Ensure the following services are configurged and running:
@ -90,12 +141,20 @@ Ensure the following services are configurged and running:
- ensure `zsh`, `bash`, or `sh` is set as the root shell, `csh` gives false errors due to quoting - ensure `zsh`, `bash`, or `sh` is set as the root shell, `csh` gives false errors due to quoting
- nfs - nfs
- iscsi - iscsi
- when using the FreeNAS API concurrently the `/etc/ctl.conf` file on the - (fixed in 12.0-U2+) when using the FreeNAS API concurrently the
server can become invalid, some sample scripts are provided in the `/etc/ctl.conf` file on the server can become invalid, some sample scripts
`contrib` directory to clean things up are provided in the `contrib` directory to clean things up ie: copy the
ie: copy the script to the server and directly and run - `./ctld-config-watchdog-db.sh | logger -t ctld-config-watchdog-db.sh &` script to the server and directly and run - `./ctld-config-watchdog-db.sh | logger -t ctld-config-watchdog-db.sh &`
please read the scripts and set the variables as appropriate for your server. please read the scripts and set the variables as appropriate for your server.
- ensure you have pre-emptively created portal, group, auth - ensure you have pre-emptively created portals, initatior groups, auths
- make note of the respective IDs (the true ID may not reflect what is
visible in the UI)
- IDs can be visible by clicking the the `Edit` link and finding the ID in the
browser address bar
- Optionally you may use the following to retrieve appropiate IDs:
- `curl --header "Accept: application/json" --user root:<password> 'http(s)://<ip>/api/v2.0/iscsi/portal'`
- `curl --header "Accept: application/json" --user root:<password> 'http(s)://<ip>/api/v2.0/iscsi/initiator'`
- `curl --header "Accept: application/json" --user root:<password> 'http(s)://<ip>/api/v2.0/iscsi/auth'`
- smb - smb
In addition, if you want to use a non-root user for the ssh operations you may In addition, if you want to use a non-root user for the ssh operations you may
@ -223,6 +282,11 @@ Install `democratic-csi` as usual with `volumeSnapshotClasses` defined as approp
- https://kubernetes.io/docs/concepts/storage/volume-snapshots/ - https://kubernetes.io/docs/concepts/storage/volume-snapshots/
- https://github.com/kubernetes-csi/external-snapshotter#usage - https://github.com/kubernetes-csi/external-snapshotter#usage
# Sponsors
A special shout out to the wonderful sponsors of the project!
[![ixSystems](https://www.ixsystems.com/wp-content/uploads/sites/13/2015/08/ix_logo_200x47.png "ixSystems")](http://ixsystems.com/)
# Related # Related
- https://github.com/nmaupu/freenas-provisioner - https://github.com/nmaupu/freenas-provisioner

View File

@ -5,12 +5,12 @@ const fs = require("fs");
let options; let options;
const args = require("yargs") const args = require("yargs")
.env("DEMOCRATIC_CSI") .env("DEMOCRATIC_CSI_LIVENESS_PROBE")
.scriptName("democratic-csi") .scriptName("liveness-probe")
.usage("$0 [options]") .usage("$0 [options]")
.option("csi-version", { .option("csi-version", {
describe: "versin of the csi spec to load", describe: "versin of the csi spec to load",
choices: ["0.2.0", "0.3.0", "1.0.0", "1.1.0", "1.2.0"], choices: ["0.2.0", "0.3.0", "1.0.0", "1.1.0", "1.2.0", "1.3.0"],
}) })
.demandOption(["csi-version"], "csi-version is required") .demandOption(["csi-version"], "csi-version is required")
.option("csi-address", { .option("csi-address", {
@ -27,7 +27,7 @@ args.version = package.version;
//const grpc = require("grpc"); //const grpc = require("grpc");
const grpc = require("grpc-uds"); const grpc = require("grpc-uds");
const protoLoader = require("@grpc/proto-loader"); const protoLoader = require("@grpc/proto-loader");
const csiVersion = process.env.CSI_VERSION || "1.1.0"; const csiVersion = process.env.CSI_VERSION || args.csiVersion || "1.2.0";
const PROTO_PATH = __dirname + "/../csi_proto/csi-v" + csiVersion + ".proto"; const PROTO_PATH = __dirname + "/../csi_proto/csi-v" + csiVersion + ".proto";
// Suggested options for similarity to existing grpc.load behavior // Suggested options for similarity to existing grpc.load behavior