I created this simple short shell script to download the current version of Zend Server for IBM i.  Unzip the downloaded zip file and then securely copy the save file to the savf ZENDPHP7 in the QGPL library.  Then we send a remote system command to submit a job to batch to silently restore the savf file.  You’ll have to wait for the batch job to run but afterward it finishes ZS9.1 will be installed in /usr/local/zendphp7

#get the shell script from the gist
wget https://gist.githubusercontent.com/phpdave/9f4090af8b90fa6c3916554b970a63b3/raw/1987d10ad25c885b7a4ebd26523cecce9dba50b1/InstallZS91onIBMi.sh
#modify the user name and IBM i name
vim InstallZS91onIBMi.sh
#Add execute permission to the owner of the file
chmod o+x InstallZS91onIBMi.sh
#run the shell script
./InstallZS91onIBMi.sh

InstallZS91onIBMi.sh Source

#wget http://downloads.zend.com/zendserver/9.1.0/ZendServer-9.1.0-php-7.1.3-IBM-i.zip
wget http://downloads.zend.com/zendserver/9.1.1/ZendServer-9.1.1-php-7.1.7-IBM-i.zip
#unzip ZendServer-9.1.0-php-7.1.3-IBM-i
unzip ZendServer-9.1.1-php-7.1.7-IBM-i
scp zendphp7.savf QSECOFR@MYIBMi.example.com:/tmp/
ssh QSECOFR@MYIBMi.example.com system "\"CPYFRMSTMF FROMSTMF('/tmp/zendphp7.savf') TOMBR('/QSYS.LIB/QGPL.LIB/ZENDPHP7.FILE')\""
ssh QSECOFR@MYIBMi.example.com system "\"SBMJOB CMD(RSTLICPGM LICPGM(7PHPZND) DEV(*SAVF) SAVF(QGPL/zendphp7))\""

view raw
InstallZS91onIBMi.sh
hosted with ❤ by GitHub

CRTSAVF FILE(QGPL/zendphp7) TEXT('Zend Server 9 product save file')
#clear it if it already exisits
CLRSAVF FILE(QGPL/zendphp7)

view raw
setupsavf.sh
hosted with ❤ by GitHub