AIX ：AWS cli 導入スクリプトの確認 ( /usr/samples/nim/cloud_setup )


AIX の /usr/samples/nim/ に cloud_setup コマンドという、IBM Cloud Object Storage を操作するための、aws 、gsutil、cloud-init コマンド導入用スクリプトがあることに気づきましたので確認内容を記載します。


AIX 7.2 TL3 以降で導入されているそうです。

参考：IBM Cloud Direct Link を介した COS の使用
https://cloud.ibm.com/docs/power-iaas?topic=power-iaas-backup-strategies&locale=ja#cos-over-directlink

>AIX 7.2 TL3 以降を実行する IBM Power Systems には、パス /usr/samples/nim/cloud_setup にスクリプトが置かれています。この cloud_setup コマンドで、クラウド・ストレージ・サービス用のコマンド・ライン環境をインストールできます。


----

##### 確認環境

IBM Cloud Power Systems Virtual Server : AIX 7.2TL5SP1
　・yum でAIX Toolbox for Linux Applications からモジュールを取得できるように構成済み。

----

##### コマンドの確認

```
# ls -l /usr/samples/nim/cloud_setup
-r-xr-xr-x    1 root     system         8606 Apr 27 2020  /usr/samples/nim/cloud_setup

# cd /usr/samples/nim/

# file cloud_setup
cloud_setup: shell script  - ksh (Korn VF)

# ./cloud_setup -h
Usage cloud_setup: Installs command line environment for cloud storage services.
cloud_setup [-I | G] [-v]

-I    Install the necessary RPMs for universal CLI (supports IBM Cloud Object Storage).
-G    Install the necessary RPMs for gsutil CLI (Google Cloud Storage).
-v    Enable debug output.
```


##### 導入実行


デバッグモードで導入を実行します。


```
# time /usr/samples/nim/cloud_setup -I -v
+ typeset +f
+ typeset -ft catch_rc
+ typeset -ft ck_deps
+ typeset -ft ck_fs
+ typeset -ft ck_version
+ typeset -ft get_rc
+ typeset -ft install_pkg
+ typeset -ft install_yum
+ getopts :CIGv c
+ id -u
+ [[ 0 != 0 ]]
+ 1> /var/adm/ras/cloudpkg_15925644.log
+ 1> /tmp/RC.15925644
+ ck_deps
+ dspmsg -s 2 cmdnim.cat 117 Initializing resources ...\n\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Initializing resources ...

+ dspmsg -s 2 cmdnim.cat 321 \nChecking for resource group %s... yum
+ tee -a /var/adm/ras/cloudpkg_15925644.log

Checking for resource group yum...+ rpm -q yum
+ 1> /dev/null 2>& 1
+ [[ 0 -ne 0 ]]
+ dspmsg -s 2 cmdnim.cat 278 done\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
done
+ rm ./yum.sh
+ 2> /dev/null
+ dspmsg -s 2 cmdnim.cat 321 \nChecking for resource group %s... python
+ tee -a /var/adm/ras/cloudpkg_15925644.log

Checking for resource group python...+ rpm -q python
+ 1> /dev/null 2>& 1
+ [[ 0 -ne 0 ]]
+ dspmsg -s 2 cmdnim.cat 278 done\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
done
+ install_pkg python update
+ typeset pkgname=python
+ typeset option=update
+ typeset -i space_req=250
+ dspmsg -s 2 cmdnim.cat 240 Installing filesets ...\n\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Installing filesets ...

+ ck_fs /opt 250.15
+ typeset fs_name=/opt
+ typeset -i space_need=250.15
+ typeset -i free_space=0
+ dspmsg -s 2 cmdnim.cat 283 Checking %s space requirement... /opt
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Checking /opt space requirement...+ + df -m /opt
+ awk NR==2{print $3}
+ 2> /dev/null
free_space=4776.81
+ ((  free_space < space_need  ))
+ dspmsg -s 2 cmdnim.cat 278 done\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
done
+ return 0
+ yum -y update python
+ 2>& 1
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Setting up Update Process
Resolving Dependencies
--> Running transaction check
---> Package python.ppc 0:2.7.15-3 will be updated
--> Processing Dependency: python = 2.7.15-3 for package: python-devel-2.7.15-3.ppc
--> Processing Dependency: python = 2.7.15-3 for package: python-tools-2.7.15-3.ppc
---> Package python.ppc 0:2.7.18-1 will be an update
--> Processing Dependency: expat >= 2.2.9 for package: python-2.7.18-1.ppc
--> Processing Dependency: readline >= 8.0 for package: python-2.7.18-1.ppc
--> Processing Dependency: libstdc++ >= 8.3.0 for package: python-2.7.18-1.ppc
--> Processing Dependency: bzip2 >= 1.0.8 for package: python-2.7.18-1.ppc
--> Processing Dependency: gettext >= 0.19.8.1 for package: python-2.7.18-1.ppc
--> Processing Dependency: ncurses >= 6.2 for package: python-2.7.18-1.ppc
--> Processing Dependency: libgcc >= 8.3.0 for package: python-2.7.18-1.ppc
--> Processing Dependency: sqlite >= 3.28.0 for package: python-2.7.18-1.ppc
--> Processing Dependency: gdbm >= 1.18.1 for package: python-2.7.18-1.ppc
--> Processing Dependency: libgdbm.a(libgdbm.so.6) for package: python-2.7.18-1.ppc
--> Running transaction check
---> Package bzip2.ppc 0:1.0.6-2 will be updated
---> Package bzip2.ppc 0:1.0.8-2 will be an update
--> Processing Dependency: libgcc_s.a(shr.o) for package: bzip2-1.0.8-2.ppc
---> Package expat.ppc 0:2.2.4-1 will be updated
---> Package expat.ppc 0:2.2.9-2 will be an update
---> Package gdbm.ppc 0:1.8.3-5 will be updated
---> Package gdbm.ppc 0:1.18.1-1 will be an update
---> Package gettext.ppc 0:0.19.7-1 will be updated
---> Package gettext.ppc 0:0.20.2-1 will be an update
--> Processing Dependency: libtextstyle = 0.20.2-1 for package: gettext-0.20.2-1.ppc
--> Processing Dependency: libunistring >= 0.9.9-2 for package: gettext-0.20.2-1.ppc
--> Processing Dependency: libxml2 >= 2.9.9 for package: gettext-0.20.2-1.ppc
--> Processing Dependency: libgomp >= 8.3.0 for package: gettext-0.20.2-1.ppc
--> Processing Dependency: glib2 >= 2.56.1 for package: gettext-0.20.2-1.ppc
--> Processing Dependency: libiconv >= 1.16 for package: gettext-0.20.2-1.ppc
--> Processing Dependency: libstdc++.a(libstdc++.so.6) for package: gettext-0.20.2-1.ppc
--> Processing Dependency: libgomp.a(libgomp.so.1) for package: gettext-0.20.2-1.ppc
--> Processing Dependency: libiconv.a(libiconv.so.2) for package: gettext-0.20.2-1.ppc
--> Processing Dependency: libtextstyle.a(libtextstyle.so.0) for package: gettext-0.20.2-1.ppc
--> Processing Dependency: libunistring.a(libunistring.so.2) for package: gettext-0.20.2-1.ppc
---> Package libgcc.ppc 0:8.1.0-2 will be updated
---> Package libgcc.ppc 1:8-1 will be an update
---> Package libstdc++.ppc 0:8.1.0-2 will be updated
---> Package libstdc++.ppc 1:8-1 will be an update
---> Package ncurses.ppc 0:6.1-2 will be updated
---> Package ncurses.ppc 0:6.2-2 will be an update
---> Package python-devel.ppc 0:2.7.15-3 will be updated
---> Package python-devel.ppc 0:2.7.18-1 will be an update
---> Package python-tools.ppc 0:2.7.15-3 will be updated
---> Package python-tools.ppc 0:2.7.18-1 will be an update
---> Package readline.ppc 0:7.0-5 will be updated
---> Package readline.ppc 0:8.0-2 will be an update
---> Package sqlite.ppc 0:3.15.2-1 will be updated
---> Package sqlite.ppc 0:3.32.3-1 will be an update
--> Running transaction check
---> Package glib2.ppc 0:2.14.6-2 will be updated
---> Package glib2.ppc 0:2.56.1-2 will be an update
---> Package libgcc8.ppc 0:8.3.0-4 will be installed
---> Package libgomp.ppc 1:8-1 will be installed
---> Package libgomp8.ppc 0:8.3.0-4 will be installed
---> Package libiconv.ppc 0:1.16-1 will be installed
---> Package libstdc++8.ppc 0:8.3.0-4 will be installed
---> Package libtextstyle.ppc 0:0.20.2-1 will be installed
---> Package libunistring.ppc 0:0.9.10-1 will be installed
---> Package libxml2.ppc 0:2.9.10-1 will be installed
--> Processing Dependency: xz-libs >= 5.2.4 for package: libxml2-2.9.10-1.ppc
--> Processing Dependency: liblzma.a(liblzma.so.5) for package: libxml2-2.9.10-1.ppc
--> Running transaction check
---> Package xz-libs.ppc 0:5.2.5-1 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================
 Package              Arch        Version          Repository              Size
================================================================================
Updating:
 python               ppc         2.7.18-1         AIX_Toolbox             21 M
Installing for dependencies:
 libgcc8              ppc         8.3.0-4          AIX_Toolbox_72         974 k
 libgomp              ppc         1:8-1            AIX_Toolbox_72          14 k
 libgomp8             ppc         8.3.0-4          AIX_Toolbox_72         1.4 M
 libiconv             ppc         1.16-1           AIX_Toolbox            1.6 M
 libstdc++8           ppc         8.3.0-4          AIX_Toolbox_72          12 M
 libtextstyle         ppc         0.20.2-1         AIX_Toolbox            1.1 M
 libunistring         ppc         0.9.10-1         AIX_Toolbox            1.5 M
 libxml2              ppc         2.9.10-1         AIX_Toolbox            5.5 M
 xz-libs              ppc         5.2.5-1          AIX_Toolbox            540 k
Updating for dependencies:
 bzip2                ppc         1.0.8-2          AIX_Toolbox            238 k
 expat                ppc         2.2.9-2          AIX_Toolbox            895 k
 gdbm                 ppc         1.18.1-1         AIX_Toolbox            278 k
 gettext              ppc         0.20.2-1         AIX_Toolbox             11 M
 glib2                ppc         2.56.1-2         AIX_Toolbox             28 M
 libgcc               ppc         1:8-1            AIX_Toolbox_72          14 k
 libstdc++            ppc         1:8-1            AIX_Toolbox_72          14 k
 ncurses              ppc         6.2-2            AIX_Toolbox            3.5 M
 python-devel         ppc         2.7.18-1         AIX_Toolbox             16 k
 python-tools         ppc         2.7.18-1         AIX_Toolbox             16 k
 readline             ppc         8.0-2            AIX_Toolbox            2.4 M
 sqlite               ppc         3.32.3-1         AIX_Toolbox            8.2 M

Transaction Summary
================================================================================
Install       9 Packages
Upgrade      13 Packages

Total size: 100 M
Downloading Packages:
Running Transaction Check
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : libgcc8-8.3.0-4.ppc                                         1/35
  Updating   : 1:libgcc-8-1.ppc                                            2/35
  Installing : libstdc++8-8.3.0-4.ppc                                      3/35
  Updating   : 1:libstdc++-8-1.ppc                                         4/35
  Updating   : ncurses-6.2-2.ppc                                           5/35
  Installing : libgomp8-8.3.0-4.ppc                                        6/35
  Updating   : readline-8.0-2.ppc                                          7/35
  Updating   : sqlite-3.32.3-1.ppc                                         8/35
  Installing : 1:libgomp-8-1.ppc                                           9/35
  Installing : xz-libs-5.2.5-1.ppc                                        10/35
  Installing : libtextstyle-0.20.2-1.ppc                                  11/35
  Installing : libunistring-0.9.10-1.ppc                                  12/35
  Installing : libiconv-1.16-1.ppc                                        13/35
add shr4.o shared members from /usr/lib/libiconv.a to  /opt/freeware/lib/libiconv.a
add shr.o shared members from /usr/lib/libiconv.a to  /opt/freeware/lib/libiconv.a
add shr4_64.o shared members from /usr/lib/libiconv.a to  /opt/freeware/lib/libiconv.a
/
  Installing : libxml2-2.9.10-1.ppc                                       14/35
  Updating   : glib2-2.56.1-2.ppc                                         15/35
  Updating   : gettext-0.20.2-1.ppc                                       16/35
  Updating   : gdbm-1.18.1-1.ppc                                          17/35
  Updating   : bzip2-1.0.8-2.ppc                                          18/35
  Updating   : expat-2.2.9-2.ppc                                          19/35
  Updating   : python-2.7.18-1.ppc                                        20/35
  Updating   : python-devel-2.7.18-1.ppc                                  21/35
  Updating   : python-tools-2.7.18-1.ppc                                  22/35
  Cleanup    : python-tools-2.7.15-3.ppc                                  23/35
  Cleanup    : glib2-2.14.6-2.ppc                                         24/35
  Cleanup    : python-devel-2.7.15-3.ppc                                  25/35
  Cleanup    : python-2.7.15-3.ppc                                        26/35
  Cleanup    : ncurses-6.1-2.ppc                                          27/35
  Cleanup    : libstdc++-8.1.0-2.ppc                                      28/35
  Cleanup    : sqlite-3.15.2-1.ppc                                        29/35
  Cleanup    : readline-7.0-5.ppc                                         30/35
  Cleanup    : libgcc-8.1.0-2.ppc                                         31/35
  Cleanup    : bzip2-1.0.6-2.ppc                                          32/35
  Cleanup    : expat-2.2.4-1.ppc                                          33/35
  Cleanup    : gdbm-1.8.3-5.ppc                                           34/35
  Cleanup    : gettext-0.19.7-1.ppc                                       35/35
Ignore the error about AIX-rpm dependency since the older libintl.a            is already preserved and will be reverted back

Dependency Installed:
  libgcc8.ppc 0:8.3.0-4                  libgomp.ppc 1:8-1
  libgomp8.ppc 0:8.3.0-4                 libiconv.ppc 0:1.16-1
  libstdc++8.ppc 0:8.3.0-4               libtextstyle.ppc 0:0.20.2-1
  libunistring.ppc 0:0.9.10-1            libxml2.ppc 0:2.9.10-1
  xz-libs.ppc 0:5.2.5-1

Updated:
  python.ppc 0:2.7.18-1

Dependency Updated:
  bzip2.ppc 0:1.0.8-2         expat.ppc 0:2.2.9-2  gdbm.ppc 0:1.18.1-1
  gettext.ppc 0:0.20.2-1      glib2.ppc 0:2.56.1-2 libgcc.ppc 1:8-1
  libstdc++.ppc 1:8-1         ncurses.ppc 0:6.2-2  python-devel.ppc 0:2.7.18-1
  python-tools.ppc 0:2.7.18-1 readline.ppc 0:8.0-2 sqlite.ppc 0:3.32.3-1

Complete!
+ catch_rc 0
+ echo 0
+ 1>> /tmp/RC.15925644
+ get_rc
+ + cat /tmp/RC.15925644
RC=0
+ rm /tmp/RC.15925644
+ 2> /dev/null
+ [[ 0 -ne 0 ]]
+ dspmsg -s 2 cmdnim.cat 278 done\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
done
+ return 0
+ dspmsg -s 2 cmdnim.cat 321 \nChecking for resource group %s... python-pip
+ tee -a /var/adm/ras/cloudpkg_15925644.log

Checking for resource group python-pip...+ rpm -q python-pip
+ 1> /dev/null 2>& 1
+ [[ 1 -ne 0 ]]
+ install_pkg python-pip
+ typeset pkgname=python-pip
+ typeset option=install
+ typeset -i space_req=250
+ dspmsg -s 2 cmdnim.cat 240 Installing filesets ...\n\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Installing filesets ...

+ ck_fs /opt 250.15
+ typeset fs_name=/opt
+ typeset -i space_need=250.15
+ typeset -i free_space=0
+ dspmsg -s 2 cmdnim.cat 283 Checking %s space requirement... /opt
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Checking /opt space requirement...+ + df -m /opt
+ awk NR==2{print $3}
+ 2> /dev/null
free_space=4553.08
+ ((  free_space < space_need  ))
+ dspmsg -s 2 cmdnim.cat 278 done\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
done
+ return 0
+ yum -y install python-pip
+ tee -a /var/adm/ras/cloudpkg_15925644.log
+ 2>& 1
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package python-pip.noarch 0:10.0.1-1 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================
 Package          Arch         Version           Repository                Size
================================================================================
Installing:
 python-pip       noarch       10.0.1-1          AIX_Toolbox_noarch       4.3 M

Transaction Summary
================================================================================
Install       1 Package

Total download size: 4.3 M
Installed size: 4.3 M
Downloading Packages:
Running Transaction Check
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : python-pip-10.0.1-1.noarch                                   1/1

Installed:
  python-pip.noarch 0:10.0.1-1

Complete!
+ catch_rc 0
+ echo 0
+ 1>> /tmp/RC.15925644
+ get_rc
+ + cat /tmp/RC.15925644
RC=0
+ rm /tmp/RC.15925644
+ 2> /dev/null
+ [[ 0 -ne 0 ]]
+ dspmsg -s 2 cmdnim.cat 278 done\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
done
+ return 0
+ return 0
+ [[ awscli = gsutil ]]
+ [[ awscli = awscli ]]
+ [[ -f /opt/freeware/bin/aws ]]
+ ck_fs /opt
+ typeset fs_name=/opt
+ typeset -i space_need=250
+ typeset -i free_space=0
+ dspmsg -s 2 cmdnim.cat 283 Checking %s space requirement... /opt
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Checking /opt space requirement...+ + df -m /opt
+ awk NR==2{print $3}
+ 2> /dev/null
free_space=4534.78
+ ((  free_space < space_need  ))
+ dspmsg -s 2 cmdnim.cat 278 done\n
+ tee -a /var/adm/ras/cloudpkg_15925644.log
done
+ return 0
+ ck_fs /tmp
+ typeset fs_name=/tmp
+ typeset -i space_need=250
+ typeset -i free_space=0
+ dspmsg -s 2 cmdnim.cat 283 Checking %s space requirement... /tmp
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Checking /tmp space requirement...+ + df -m /tmp
+ awk NR==2{print $3}
+ 2> /dev/null
free_space=221.39
+ ((  free_space < space_need  ))
+ chfs -a size=+29M /tmp
+ 1> /dev/null 2>& 1
+ [[ 0 -ne 0 ]]
+ tee -a /var/adm/ras/cloudpkg_15925644.log
+ dspmsg -s 2 cmdnim.cat 278 done\n
done
+ return 0
+ ck_fs /var
+ typeset fs_name=/var
+ typeset -i space_need=250
+ typeset -i free_space=0
+ dspmsg -s 2 cmdnim.cat 283 Checking %s space requirement... /var
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Checking /var space requirement...+ + df -m /var
+ awk NR==2{print $3}
+ 2> /dev/null
free_space=41.32
+ ((  free_space < space_need  ))
+ chfs -a size=+209M /var
+ 1> /dev/null 2>& 1
+ [[ 0 -ne 0 ]]
+ tee -a /var/adm/ras/cloudpkg_15925644.log
+ dspmsg -s 2 cmdnim.cat 278 done\n
done
+ return 0
+ pip install awscli
+ tee -a /var/adm/ras/cloudpkg_15925644.log
Collecting awscli
  Downloading https://files.pythonhosted.org/packages/81/ba/6ece229cfa7e7acaf2218f36bc993a18764c65cbba956313f8db93525701/awscli-1.18.218-py2.py3-none-any.whl (3.5MB)
Collecting rsa<=4.5.0,>=3.1.2; python_version != "3.4" (from awscli)
  Downloading https://files.pythonhosted.org/packages/26/f8/8127fdda0294f044121d20aac7785feb810e159098447967a6103dedfb96/rsa-4.5-py2.py3-none-any.whl
Collecting docutils<0.16,>=0.10 (from awscli)
  Downloading https://files.pythonhosted.org/packages/3a/dc/bf2b15d1fa15a6f7a9e77a61b74ecbbae7258558fcda8ffc9a6638a6b327/docutils-0.15.2-py2-none-any.whl (548kB)
Collecting s3transfer<0.4.0,>=0.3.0 (from awscli)
  Downloading https://files.pythonhosted.org/packages/ea/43/4b4a1b26eb03a429a4c37ca7fdf369d938bd60018fc194e94b8379b0c77c/s3transfer-0.3.4-py2.py3-none-any.whl (69kB)
Collecting botocore==1.19.58 (from awscli)
  Downloading https://files.pythonhosted.org/packages/1a/22/e423cfaed6f89de9bfc3978d02db7284832d658b0c0695bdce9aceb1fc05/botocore-1.19.58-py2.py3-none-any.whl (7.2MB)
Requirement already satisfied: PyYAML<5.4,>=3.10; python_version != "3.4" in /opt/freeware/lib/python2.7/site-packages (from awscli) (3.11)
Collecting colorama<0.4.4,>=0.2.5; python_version != "3.4" (from awscli)
  Downloading https://files.pythonhosted.org/packages/c9/dc/45cdef1b4d119eb96316b3117e6d5708a08029992b2fee2c143c7a0a5cc5/colorama-0.4.3-py2.py3-none-any.whl
Collecting pyasn1>=0.1.3 (from rsa<=4.5.0,>=3.1.2; python_version != "3.4"->awscli)
  Downloading https://files.pythonhosted.org/packages/62/1e/a94a8d635fa3ce4cfc7f506003548d0a2447ae76fd5ca53932970fe3053f/pyasn1-0.4.8-py2.py3-none-any.whl (77kB)
Collecting futures<4.0.0,>=2.2.0; python_version == "2.7" (from s3transfer<0.4.0,>=0.3.0->awscli)
  Downloading https://files.pythonhosted.org/packages/d8/a6/f46ae3f1da0cd4361c344888f59ec2f5785e69c872e175a748ef6071cdb5/futures-3.3.0-py2-none-any.whl
Collecting urllib3<1.27,>=1.25.4; python_version != "3.4" (from botocore==1.19.58->awscli)
  Downloading https://files.pythonhosted.org/packages/f5/71/45d36a8df68f3ebb098d6861b2c017f3d094538c0fb98fa61d4dc43e69b9/urllib3-1.26.2-py2.py3-none-any.whl (136kB)
Collecting python-dateutil<3.0.0,>=2.1 (from botocore==1.19.58->awscli)
  Downloading https://files.pythonhosted.org/packages/d4/70/d60450c3dd48ef87586924207ae8907090de0b306af2bce5d134d78615cb/python_dateutil-2.8.1-py2.py3-none-any.whl (227kB)
Collecting jmespath<1.0.0,>=0.7.1 (from botocore==1.19.58->awscli)
  Downloading https://files.pythonhosted.org/packages/07/cb/5f001272b6faeb23c1c9e0acc04d48eaaf5c862c17709d20e3469c6e0139/jmespath-0.10.0-py2.py3-none-any.whl
Requirement already satisfied: six>=1.5 in /opt/freeware/lib/python2.7/site-packages (from python-dateutil<3.0.0,>=2.1->botocore==1.19.58->awscli) (1.10.0)
cloud-init 0.7.5 requires requests, which is not installed.
jsonpatch 1.8 has requirement jsonpointer>=1.3, but you'll have jsonpointer 1.0 which is incompatible.
Installing collected packages: pyasn1, rsa, docutils, futures, urllib3, python-dateutil, jmespath, botocore, s3transfer, colorama, awscli
Successfully installed awscli-1.18.218 botocore-1.19.58 colorama-0.4.3 docutils-0.15.2 futures-3.3.0 jmespath-0.10.0 pyasn1-0.4.8 python-dateutil-2.8.1 rsa-4.5 s3transfer-0.3.4 urllib3-1.26.2
You are using pip version 10.0.1, however version 20.3.3 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
+ catch_rc 0
+ echo 0
+ 1>> /tmp/RC.15925644
+ get_rc
+ + cat /tmp/RC.15925644
RC=0
+ rm /tmp/RC.15925644
+ 2> /dev/null
+ [[ 0 -ne 0 ]]
+ ck_version aws
+ typeset name=aws
+ typeset cmd=aws --version
+ tee -a /var/adm/ras/cloudpkg_15925644.log
+ dspmsg -s 2 cmdnim.cat 270 \nDone verifying resources.\n

Done verifying resources.
+ pip show awscli
+ tee -a /var/adm/ras/cloudpkg_15925644.log
+ 2> /dev/null
Name: awscli
Version: 1.18.218
Summary: Universal Command Line Environment for AWS.
Home-page: http://aws.amazon.com/cli/
Author: Amazon Web Services
Author-email: UNKNOWN
License: Apache License 2.0
Location: /opt/freeware/lib/python2.7/site-packages
Requires: rsa, docutils, s3transfer, botocore, PyYAML, colorama
Required-by:
+ catch_rc 0
+ echo 0
+ 1>> /tmp/RC.15925644
+ get_rc
+ + cat /tmp/RC.15925644
RC=0
+ rm /tmp/RC.15925644
+ 2> /dev/null
+ [[ 0 -ne 0 ]]
+ tee -a /var/adm/ras/cloudpkg_15925644.log
+ dspmsg -s 2 cmdnim.cat 273 Executing command:\n%s\n aws --version
Executing command:
aws --version
+ eval aws --version
+ 2>& 1
+ tee -a /var/adm/ras/cloudpkg_15925644.log
+ aws --version
aws-cli/1.18.218 Python/2.7.18 AIX/2 botocore/1.19.58
+ return 0
+ exit 0

real    0m54.98s
user    0m8.10s
sys     0m2.06s
#

```

1 分程度で実行完了しました。


/opt/freeware/bin/ 下に aws コマンドが導入されていました。
PATH は通っていません。

```
# ls -l /opt/freeware/bin/aws*
-rwxr-xr-x    1 root     system          823 Jan 22 02:19 /opt/freeware/bin/aws
-rwxr-xr-x    1 root     system         1432 Jan 22 02:19 /opt/freeware/bin/aws.cmd
-rwxr-xr-x    1 root     system          204 Jan 22 02:19 /opt/freeware/bin/aws_bash_completer
-rwxr-xr-x    1 root     system         1144 Jan 22 02:19 /opt/freeware/bin/aws_completer
-rwxr-xr-x    1 root     system         1807 Jan 22 02:19 /opt/freeware/bin/aws_zsh_completer.sh
#
```

---

##### 参考: 導入されたrpm

awscli 導入で、10個の rpm が導入され、13個の rpm がアップデートされていました。

＊ cloud_setup -I コマンド実行で導入された rpm (10個)

```
libgcc-8-1.ppc
libgomp8-8.3.0-4.ppc
xz-libs-5.2.5-1.ppc
libunistring-0.9.10-1.ppc
libxml2-2.9.10-1.ppc
libstdc++8-8.3.0-4.ppc
libgomp-8-1.ppc
libtextstyle-0.20.2-1.ppc
libiconv-1.16-1.ppc
python-pip-10.0.1-1.noarch
```



＊ cloud_setup -I コマンド実行でアップデートされたrpm (13個)

```
libgcc8-8.3.0-4.ppc
ncurses-6.2-2.ppc
gettext-0.20.2-1.ppc
sqlite-3.32.3-1.ppc
expat-2.2.9-2.ppc
python-2.7.18-1.ppc
python-devel-2.7.18-1.ppc
libstdc++-8-1.ppc
readline-8.0-2.ppc
glib2-2.56.1-2.ppc
gdbm-1.18.1-1.ppc
bzip2-1.0.8-2.ppc
python-tools-2.7.18-1.ppc
```


＊ cloud_setup -I コマンド実行後のrpm 全量 (57個)

```
# rpm -qa
tcl-8.4.7-3.ppc
expect-5.42.1-3.ppc
info-6.4-1.ppc
yum-metadata-parser-1.1.4-2.ppc
python-requests-2.4.3-1.noarch
python-PyYAML-3.11-1.ppc
curl-7.52.1-1.ppc
python-boto-2.34.0-1.noarch
python-configobj-5.0.5-1.noarch
python-jsonpointer-1.0-1.noarch
python-oauth-1.0.1-1.noarch
python-pycurl-7.19.3-1.ppc
python-pyserial-2.7-1.ppc
python-six-1.10.0-1.noarch
cloud-init-0.7.5-4.4.ppc
python-argparse-1.2.1-1.noarch
db-4.8.24-3.ppc
libgcc-8-1.ppc
libstdc++-8-1.ppc
libgomp8-8.3.0-4.ppc
sqlite-3.32.3-1.ppc
xz-libs-5.2.5-1.ppc
libunistring-0.9.10-1.ppc
libxml2-2.9.10-1.ppc
gettext-0.20.2-1.ppc
bzip2-1.0.8-2.ppc
python-2.7.18-1.ppc
python-tools-2.7.18-1.ppc
tk-8.4.7-3.ppc
AIX-rpm-7.2.5.0-2.ppc
zlib-1.2.11-1.ppc
bash-4.3.30-1.ppc
libffi-3.2.1-2.ppc
libyaml-0.1.4-2.ppc
ca-certificates-2016.10.7-2.ppc
pysqlite-1.1.7-2.ppc
python-cheetah-2.4.4-2.ppc
python-iniparse-0.4-1.noarch
python-jsonpatch-1.8-1.noarch
python-prettytable-0.7.2-1.noarch
python-urlgrabber-3.10.1-1.noarch
python-setuptools-0.9.8-2.noarch
python-xml-0.8.4-1.ppc
yum-3.4.3-5.noarch
osinstall-1.6-1.noarch
libgcc8-8.3.0-4.ppc
libstdc++8-8.3.0-4.ppc
ncurses-6.2-2.ppc
readline-8.0-2.ppc
libgomp-8-1.ppc
libtextstyle-0.20.2-1.ppc
libiconv-1.16-1.ppc
glib2-2.56.1-2.ppc
gdbm-1.18.1-1.ppc
expat-2.2.9-2.ppc
python-devel-2.7.18-1.ppc
python-pip-10.0.1-1.noarch
```





以上です。