diff options
author | Simon Spöhel <simon.spoehel@open-infrastructure.net> | 2017-07-09 15:01:36 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@open-infrastructure.net> | 2017-07-21 17:41:03 +0000 |
commit | 592a80fa9483a6e61a99572155776e12eac0a1a5 (patch) | |
tree | d64e40ddb62e4253b5acb6be433a8b45e641e830 | |
parent | Merging sections for container-tools in nspawn file. (diff) | |
download | compute-tools-592a80fa9483a6e61a99572155776e12eac0a1a5.tar.xz compute-tools-592a80fa9483a6e61a99572155776e12eac0a1a5.zip |
Fixing typo in 'bandwidth'.
Diffstat (limited to '')
-rwxr-xr-x | lib/container/limit | 22 | ||||
-rwxr-xr-x | lib/container/start | 14 | ||||
-rw-r--r-- | share/bash-completion/container | 2 | ||||
-rw-r--r-- | share/man/container-limit.1.txt | 8 |
4 files changed, 23 insertions, 23 deletions
diff --git a/lib/container/limit b/lib/container/limit index b888656..05bffdc 100755 --- a/lib/container/limit +++ b/lib/container/limit @@ -25,7 +25,7 @@ MACHINES="/var/lib/machines" Parameters () { - GETOPT_LONGOPTIONS="name:,blockio-device-weight:,blockio-read-bandwith:,blockio-weight:,blockio-write-bandwith:,cpu-quota:,cpu-shares:,memory-limit:,tasks-max:," + GETOPT_LONGOPTIONS="name:,blockio-device-weight:,blockio-read-bandwidth:,blockio-weight:,blockio-write-bandwidth:,cpu-quota:,cpu-shares:,memory-limit:,tasks-max:," GETOPT_OPTIONS="n:b:c:m:t:," PARAMETERS="$(getopt --longoptions ${GETOPT_LONGOPTIONS} --name=${COMMAND} --options ${GETOPT_OPTIONS} --shell sh -- ${@})" @@ -71,8 +71,8 @@ Parameters () shift 2 ;; - --blockio-read-bandwith) - BLOCK_IO_READ_BANDWITH="${2}" + --blockio-read-bandwidth) + BLOCK_IO_READ_BANDWIDTH="${2}" shift 2 ;; @@ -81,8 +81,8 @@ Parameters () shift 2 ;; - --blockio-write-bandwith) - BLOCK_IO_WRITE_BANDWITH="${2}" + --blockio-write-bandwidth) + BLOCK_IO_WRITE_BANDWIDTH="${2}" shift 2 ;; @@ -101,7 +101,7 @@ Parameters () Usage () { - echo "Usage: container ${COMMAND} -n|--name NAME [--blockio-device-weight \"DEVICE WEIGHT\"] [--blockio-read-bandwith \"DEVICE BYTES\"] [-b|--blockio-weight WEIGHT] [--blockio-write-bandwith \"DEVICE BYTES\"] [-c|--cpu-quota QUOTA] [--cpu-shares SHARES] [-m|--memory-limit BYTES] [-t|--tasks-max NUMBER]" >&2 + echo "Usage: container ${COMMAND} -n|--name NAME [--blockio-device-weight \"DEVICE WEIGHT\"] [--blockio-read-bandwidth \"DEVICE BYTES\"] [-b|--blockio-weight WEIGHT] [--blockio-write-bandwidth \"DEVICE BYTES\"] [-c|--cpu-quota QUOTA] [--cpu-shares SHARES] [-m|--memory-limit BYTES] [-t|--tasks-max NUMBER]" >&2 exit 1 } @@ -136,9 +136,9 @@ then SET_PROPERTY="true" fi -if [ -n "${BLOCK_IO_READ_BANDWITH}" ] +if [ -n "${BLOCK_IO_READ_BANDWIDTH}" ] then - BLOCK_IO_READ_BANDWITH="BlockIOReadBandwidth=${BLOCK_IO_READ_BANDWITH}" + BLOCK_IO_READ_BANDWIDTH="BlockIOReadBandwidth=${BLOCK_IO_READ_BANDWIDTH}" SET_PROPERTY="true" fi @@ -148,9 +148,9 @@ then SET_PROPERTY="true" fi -if [ -n "${BLOCK_IO_WRITE_BANDWITH}" ] +if [ -n "${BLOCK_IO_WRITE_BANDWIDTH}" ] then - BLOCK_IO_WRITE_BANDWITH="BlockIOReadBandwidth=${BLOCK_IO_WRITE_BANDWITH}" + BLOCK_IO_WRITE_BANDWIDTH="BlockIOReadBandwidth=${BLOCK_IO_WRITE_BANDWIDTH}" SET_PROPERTY="true" fi @@ -193,7 +193,7 @@ do done # Run -systemctl --runtime set-property ${NAME} ${BLOCK_IO_DEVICE_WEIGHT} ${BLOCK_IO_READ_BANDWITH} ${BLOCK_IO_WEIGHT} ${BLOCK_IO_WRITE_BANDWITH} ${CPU_QUOTA} ${CPU_SHARES} ${MEMORY_LIMIT} ${TASKS_MAX} +systemctl --runtime set-property ${NAME} ${BLOCK_IO_DEVICE_WEIGHT} ${BLOCK_IO_READ_BANDWIDTH} ${BLOCK_IO_WEIGHT} ${BLOCK_IO_WRITE_BANDWIDTH} ${CPU_QUOTA} ${CPU_SHARES} ${MEMORY_LIMIT} ${TASKS_MAX} # Post hooks for FILE in "${HOOKS}/post-${COMMAND}".* "${HOOKS}/${NAME}.post-${COMMAND}" diff --git a/lib/container/start b/lib/container/start index da44dec..a81a98f 100755 --- a/lib/container/start +++ b/lib/container/start @@ -392,11 +392,11 @@ EOF SET_PROPERTY="true" fi - BLOCK_IO_READ_BANDWITH="$(crudini --get ${CONFIG}/${NAME}.nspawn ContainerTools BlockIOReadBandwith)" + BLOCK_IO_READ_BANDWIDTH="$(crudini --get ${CONFIG}/${NAME}.nspawn ContainerTools BlockIOReadBandwidth)" - if [ -n "${BLOCK_IO_READ_BANDWITH}" ] + if [ -n "${BLOCK_IO_READ_BANDWIDTH}" ] then - BLOCK_IO_READ_BANDWITH="BlockIOReadBandwith=${BLOCK_IO_READ_BANDWITH}" + BLOCK_IO_READ_BANDWIDTH="BlockIOReadBandwidth=${BLOCK_IO_READ_BANDWIDTH}" SET_PROPERTY="true" fi @@ -408,11 +408,11 @@ EOF SET_PROPERTY="true" fi - BLOCK_IO_WRITE_BANDWITH="$(crudini --get ${CONFIG}/${NAME}.nspawn ContainerTools BlockIOWriteBandwith)" + BLOCK_IO_WRITE_BANDWIDTH="$(crudini --get ${CONFIG}/${NAME}.nspawn ContainerTools BlockIOWriteBandwidth)" - if [ -n "${BLOCK_IO_WRITE_BANDWITH}" ] + if [ -n "${BLOCK_IO_WRITE_BANDWIDTH}" ] then - BLOCK_IO_WRITE_BANDWITH="BlockIOWriteBandwith=${BLOCK_IO_WRITE_BANDWITH}" + BLOCK_IO_WRITE_BANDWIDTH="BlockIOWriteBandwidth=${BLOCK_IO_WRITE_BANDWIDTH}" SET_PROPERTY="true" fi @@ -461,7 +461,7 @@ case "${START}" in true) case "${SET_PROPERTY}" in true) - systemctl --runtime set-property ${NAME} ${BLOCK_IO_DEVICE_WEIGHT} ${BLOCK_IO_READ_BANDWITH} ${BLOCK_IO_WEIGHT} ${BLOCK_IO_WRITE_BANDWITH} ${CPU_QUOTA} ${CPU_SHARES} ${MEMORY_LIMIT} ${TASKS_MAX} + systemctl --runtime set-property ${NAME} ${BLOCK_IO_DEVICE_WEIGHT} ${BLOCK_IO_READ_BANDWIDTH} ${BLOCK_IO_WEIGHT} ${BLOCK_IO_WRITE_BANDWIDTH} ${CPU_QUOTA} ${CPU_SHARES} ${MEMORY_LIMIT} ${TASKS_MAX} ;; esac ;; diff --git a/share/bash-completion/container b/share/bash-completion/container index 8847419..82084df 100644 --- a/share/bash-completion/container +++ b/share/bash-completion/container @@ -105,7 +105,7 @@ _container() ;; *) - opts="-n --name --blockio-device-weight --blockio-read-bandwith -b --blockio-weight --blockio-write-bandwith -c --cpu-quota --cpu-shares -m --memory-limit -t --tasks-max" + opts="-n --name --blockio-device-weight --blockio-read-bandwidth -b --blockio-weight --blockio-write-bandwidth -c --cpu-quota --cpu-shares -m --memory-limit -t --tasks-max" COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) ) return 0 ;; diff --git a/share/man/container-limit.1.txt b/share/man/container-limit.1.txt index f942fba..534bd76 100644 --- a/share/man/container-limit.1.txt +++ b/share/man/container-limit.1.txt @@ -47,14 +47,14 @@ The following container options are available: *--blockio-device-weight='DEVICE WEIGHT'*:: Specify device specific blockio weight, see systemd.resource-control(5). -*--blockio-read-bandwith='DEVICE BYTES'*:: - Specify device specific blockio read bandwith, see systemd.resource-control(5). +*--blockio-read-bandwidth='DEVICE BYTES'*:: + Specify device specific blockio read bandwidth, see systemd.resource-control(5). *-b, --blockio-weight='WEIGHT'*:: Specify general blockio weight, see systemd.resource-control(5). -*--blockio-write-bandwith='DEVICE BYTES'*:: - Specify device specific blockio write bandwith, see systemd.resource-control(5). +*--blockio-write-bandwidth='DEVICE BYTES'*:: + Specify device specific blockio write bandwidth, see systemd.resource-control(5). *-c, --cpu-quota='QUOTA'*:: Specify CPU quota, see systemd.resource-control(5). |