Looks like it can't find "libclntsh.so.9.0" -- is that anywhere where LD_LIBRARY_PATH doesn't point to in your CGI environment? Is /oracle/lib readable/executable by everybody? Or is your CGI environment setting a chroot different from "/"? Try `ls /` and print the output.