This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ -d /2nd_path ] && echo "Error: /2nd_path is a directory. You must first delete the folder." || ln -sfn /1st_path /2nd_path | |
find /2nd_path -type l | |
ls -ltra /2nd_path | |
# 2nd path is where the symbolic will be created and name of the symlink and the 1st path is the target directory |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
String DEBUG_TEMPLATE = 'C:[C] R:[R] U:[U] D:[D] MA:[MA] RA:[RA] | [PROFILE_NAME] | [OBJECT_NAME]'; | |
String TRUE_TEMPLATE = '[X]'; // do not use space, horizontal char alignment will be off | |
String FALSE_TEMPLATE = '[_]'; // same | |
Integer PROFILE_NAME_MAX_LENGTH; | |
// Grab the max chars of each, so we can get an evenly formatted / spaced output later | |
List<Integer> nameLengths = new List<Integer>(); | |
for (Profile profile : [SELECT Name FROM Profile]) { | |
nameLengths.add(profile.Name.length()); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
setup follow https://cloud.google.com/natural-language/docs/reference/libraries#client-libraries-install-php |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#1. Download the entire directory at ftp://public.dhe.ibm.com/software/ibmi/products/pase/rpms/repo | |
#2. Upload the entire directoy to IBM i ifs | |
#3. Change the baseurl in /QOpenSys/etc/yum/repos.d/ibm.repo to point to ifs directory | |
# FROM: baseurl=ftp://public.dhe.ibm.com/software/ibmi/products/pase/rpms/repo | |
# TO: baseurl=file:///path/to/local/repo | |
# EXTO: baseurl=file:///QOpenSys/etc/yum/IBMRepoLocalMirror/repo | |
vi /QOpenSys/etc/yum/repos.d/ibm.repo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$db2Connection = db2_connect('MYDB', 'MYUSER', 'MYPASS',array('i5_lib' => 'MYLIB')); | |
$sql = "CALL MYLIB.TESTSP(?,?)"; | |
$stmt = db2_prepare($db2Connection, $sql); | |
for ($i = 0; $i <= 20; $i++) | |
{ | |
if ($stmt) | |
{ | |
$id = 20; | |
$name = ""; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Output of phpinfo() when xdebug is enabled | |
xdebug | |
xdebug support enabled | |
Version 2.5.1 | |
IDE Key NETBEANS | |
Supported protocols Revision | |
DBGp - Common DeBuGger Protocol $Revision: 1.145 $ | |
Directive Local Value Master Value |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;Turn off zend debugger in /usr/local/zendphp7/etc/conf.d/debugger.ini | |
;zend_extension_manager.dir.debugger=/usr/local/zendphp7/lib/debugger |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Load the SSL module into Apache | |
LoadModule ibm_ssl_module /QSYS.LIB/QHTTPSVR.LIB/QZSRVSSL.SRVPGM | |
# Listen for HTTPS traffic | |
Listen 10.1.1.200:80 | |
Listen 10.1.1.200:443 | |
NameVirtualHost 10.1.1.200:443 | |
# MYApp - Redirect to HTTPS | |
<VirtualHost 10.1.1.201:80> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://www.google.com/search?q=ibm+watson+services+and+apis&oq=ibm+watson+services+and+apis&aqs=chrome..69i57.6374j0j7&sourceid=chrome&ie=UTF-8 | |
Watson API Explorer to test PAIs | |
https://watson-api-explorer.mybluemix.net/ | |
https://bitbucket.org/litmis/python-itoolkit | |
Integrated web services (IWS) - SOAP and REST. Expose RPG as REST. Supports XML and JSON | |
So much data is being consumed and 80% of data can't be consumed... Consumed -> Understand |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo Start $(date '+%Y %b %d %H:%M:%S') $HOSTNAME | |
ps aux | awk '{print $3;}' | awk '{total += ($1) ;} END {print total " % of CPU Used by All Processes";}' | |
ps aux | awk '{print $4;}' | awk '{total += ($1) ;} END {print total " % of Memory used by ALL Processes";}' | |
ps aux | grep 'httpd' | awk '{print $3;}' | awk '{total += ($1) ;} END {print total " % of CPU Used by Apache Processes";}' | |
ps aux | grep 'httpd' | awk '{print $4;}' | awk '{total += ($1) ;} END {print total " % of Memory used by Apache Processes";}' | |
ps aux | grep 'httpd' | awk '{print $6/1024;}' | awk '{total += ($1) ;} END {print total " MB used by Apache Processes";}' | |
ps aux | grep 'httpd' | awk '{print $6/1024;}' | awk '{avg += ($1 - avg) / NR;} END {print avg " MB used on average per Apache process";}' | |
ps -C httpd --no-headers | wc -l | awk '{print $0 " apache processes ";}' | |
echo '---CPU and IO Usage sar -P ALL 1 5 | grep average---' |
NewerOlder