Skip to Main Content

Infrastructure Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

strange KSH behavior

2652060Aug 24 2017 — edited Aug 24 2017

I am running ksh :

ksh --version                                

  version         sh (AT&T Research) 93u+ 2012-08-01

I have a file (b1) containing the following:

AAA

BBB

CCCC

I have a second file (b2) containing the following

1234

5432

AAAA

987

I run an interactive shell that goes like this
cat a2 | while read a ; do

grep $a b2

done

My output looks like this

AAAA

grep: grep: cannot execute [Exec format error]

grep: grep: cannot execute [Exec format error]

This is not data related as i manually created the above file with an editor simulating what i do with real world data.

This works for some users.  I am  trying to narrow down what in the environment may be different.

Any suggestions?

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 21 2017
Added on Aug 24 2017
1 comment
394 views