blob: cb71dd370349f92e7f42e437e114bd8281c4314d [file] [log] [blame]
George Keishingfece9792017-05-05 10:28:33 -05001***Settings***
2Documentation Keywords for system related tools installation.
3... For HTX refer to https://github.com/open-power/HTX
4
5
6Resource utils_os.robot
George Keishing88366b32017-05-12 13:50:48 -05007Resource ../lib/boot_utils.robot
George Keishingfece9792017-05-05 10:28:33 -05008
9***Keywords***
10
11Prep OS For HTX Installation
12 [Documentation] Prepare OS for HTX tool installation.
13
14 Boot To OS
George Keishing88366b32017-05-12 13:50:48 -050015 ${status}= Run Keyword And Return Status Tool Exist htxcmdline
George Keishingfece9792017-05-05 10:28:33 -050016
17 Return From Keyword If '${status}' == 'True'
18 ... HTX tool already installed.
19
20 # Downloads the package lists from the repositories and "update"
21 # them to get information on the newest versions of packages and
22 # their dependencies.
23 Log To Console \n Update package list.
24 Execute Command On OS sudo apt-get update
25
26 # Download and install Git.
27 Log To Console \n Install Git.
28 Execute Command On OS sudo apt-get -y install git
29
30
George Keishing88366b32017-05-12 13:50:48 -050031Prep OS For OPAL PRD Installation
32 [Documentation] Prepare OS for OPAL PRD tool installation.
33
34 Boot To OS
35 ${status}= Run Keyword And Return Status Tool Exist opal-gard
36
37 Return From Keyword If '${status}' == 'True' ${False}
38
39
40 # Downloads the package lists from the repositories and "updates"
41 # them to get information on the newest versions of packages and
42 # their dependencies.
43 Log To Console \n Update package list.
44 Execute Command On OS sudo apt-get update
45
46
George Keishingfece9792017-05-05 10:28:33 -050047Setup HTX On OS
48 [Documentation] Download and install HTX exerciser tool from github.
49
50 # Download HTX source code from github.
51 Log To Console \n Download HTX source code from github.
52 Execute Command sudo git clone https://www.github.com/open-power/HTX
53
54 # Download and install pre-requisite packages before compiling HTX.
55 Log To Console \n Download pre-requisite packages before compiling HTX.
56 Execute Command On OS
57 ... sudo apt-get -y install gcc make libncurses5 g++ libdapl-dev
58
59 # To fix ncurse compile warning and errors.
60 Execute Command On OS
61 ... sudo apt-get -y install libncurses5-dev libncursesw5-dev
62
63 Execute Command On OS sudo apt-get -y install libibverbs-dev librdmacm-dev
64
65 # Compile HTX source code and install.
66 Log To Console \n Compile HTX source code.
67 Execute Command On OS cd HTX && sudo make all
68
69 Log To Console \n Installed compiled HTX binaries.
70 Execute Command On OS sudo make install
71
George Keishing88366b32017-05-12 13:50:48 -050072
Joy Onyerikwu56fd36a2018-04-10 10:09:07 -050073Install HTX On RedHat
74 [Documentation] Download and install HTX on Red Hat.
75 [Arguments] ${htx_rpm}
76 # Description of argument(s):
77 # htx_rpm The url of the rqm file for htx
78 # (e.g. http://server.com/projects/htx_package.rpm )
79
80
Joy Onyerikwua8074172018-04-20 07:08:19 -050081 ${stdout} ${stderr} ${rc} OS Execute Command
82 ... wget ${htx_rpm} ignore_err=1
83 Should Not Contain ${stderr} ERROR
Joy Onyerikwu56fd36a2018-04-10 10:09:07 -050084 @{str}= Split String From Right ${htx_rpm} / 1
Joy Onyerikwua8074172018-04-20 07:08:19 -050085
Joy Onyerikwu56fd36a2018-04-10 10:09:07 -050086 # Remove the old version.
87 OS Execute Command rpm -e `rpm -qa | grep htx` ignore_err=1
88 OS Execute Command rpm -Uvh ${str[1]}
89 Tool Exist htxcmdline
90
91
George Keishing88366b32017-05-12 13:50:48 -050092Setup Opal Prd On OS
93 [Documentation] Download and install opal prd tool.
94
95 # Download and install PRD packages.
96 Execute Command sudo apt-get install opal-prd
97 Execute Command sudo apt-get install opal-utils
98
99 # Reboot OS to activate installation.
100 Host Reboot
101
102 # Login to OS and verify opal prd installation working.
103 Login To OS
104 ${out}= Execute Command opal-gard list
105 Should Contain ${out} No GARD entries to display
106