ksh - pipe cannot write to output -
i use line in ksh (not ksh93) under aix 6.1
# initiate earlier linestart=235559 cst_tracortaillook=128 filename=/longpathwithslash/logs/file.log # /longpathwithslash/logs/file.log -> file_log.27jun2014-00:00:00 # file 250.000 line , 60.000.000 bytes or more # failing line tail -n +$(( ${linestart} - ${cst_tracortaillook} + 1 )) ${filename} | someaction
running in direct session, no problem, return result (test wc -l
after pipe return number of line) running , agent (tivoli monitoring agent) line return:
tail: 0652-046 cannot write output. there no process read data written pipe.
loking limitation found less limitation (ulimit-a
) agent direct session
direct agent time(seconds) unlimited unlimited file(blocks) unlimited unlimited data(kbytes) 131072 unlimited stack(kbytes) 32768 32768 memory(kbytes) 32768 32768 coredump(blocks) 2097151 unlimited nofiles(descriptors) 2000 unlimited threads(per process) unlimited unlimited processes(per user) unlimited unlimited
i found several issue on aix 5.3 limitation 2 gb not size nor os version
eventually, there alternative without passing through temporary file ?
when someaction after pipe finished before tail finished, have broken pipe. make sure someaction wait until tail finished.
Comments
Post a Comment