Originally posted by: chandru0078
Dear Gurus
Can anyone help me write a script for below steps? Expect the PID others are static
statement .Do anyone know how to wite below 4 steps into script ??? PLEASE HELP.THANK YOU IN ADVANCE
1 steps : Grep mfcs32 process and get the PID
-
ps -ef|grep mfcs32
root 479392 1179864 0 17:20:18 - 0:00 /opt/microfocus/cobol/bin/mfcs32
root 1851532 552982 0 17:23:34 pts/1 0:00 grep mfcs32
2 steps : Execute dbx -a <PID of mfcs32>
-
dbx -a 479392
Waiting to attach to process 479392 ...
Successfully attached to mfcs32.
warning: Directory containing mfcs32 could not be determined.
Apply 'use' command to initialize source path.
Type 'help' for help.
reading symbolic information ...
stopped in _p_pause at 0xd0128060 ($t2)
0xd0128060 (_p_pause+0x80) 80410014 lwz r2,0x14(r1)
3 Steps :dbx will requested for input and input will be "thread"
(dbx) thread
4 Steps : dbx will requested for input and input will be "quit"
(dbx) quit
chandru0078