2023-12-29 16:04:38 |
Ubuntu user |
description |
aws-parallelcluster-3.8.0-ubuntu-2204-lts-hvm-x86_64-202312160956 2023-12-16T10-00-45.861Z
ami-0b3fd4465f19a9981
During AWS parallelcluster, the following error was captured during execution of a
HeadNode.CustomAction.OnNodeConfigured.Script:
-sh: 3: /etc/profile.d/path.sh: Syntax error: "(" unexpected
For reference:
============================
$ cat /etc/profile.d/path.sh
#!/bin/bash
PATH_REQUIRED_DIRECTORIES=(/usr/local/sbin /usr/local/bin /sbin /bin /usr/sbin /usr/bin /opt/aws/bin)
for directory in "${PATH_REQUIRED_DIRECTORIES[@]}"; do
[[ ":$PATH:" == *":$directory:"* ]] || PATH="${PATH:+"$PATH:"}$directory"
done
export PATH
============================
The script's syntax seems to be compatible with bash, but incompatible with sh. |
aws-parallelcluster-3.8.0-ubuntu-2204-lts-hvm-x86_64-202312160956 2023-12-16T10-00-45.861Z
ami-0b3fd4465f19a9981
During AWS parallelcluster creation, the following error was captured during execution of a
HeadNode.CustomAction.OnNodeConfigured.Script:
-sh: 3: /etc/profile.d/path.sh: Syntax error: "(" unexpected
For reference:
============================
$ cat /etc/profile.d/path.sh
#!/bin/bash
PATH_REQUIRED_DIRECTORIES=(/usr/local/sbin /usr/local/bin /sbin /bin /usr/sbin /usr/bin /opt/aws/bin)
for directory in "${PATH_REQUIRED_DIRECTORIES[@]}"; do
[[ ":$PATH:" == *":$directory:"* ]] || PATH="${PATH:+"$PATH:"}$directory"
done
export PATH
============================
The script's syntax seems to be compatible with bash, but incompatible with sh. |
|