[HPADM] weird scripting problem.

From: Paveza, Gary (gary.paveza@AIG.COM)
Date: Mon Jun 25 2007 - 13:44:55 EDT


Okay, I'm at a loss. I'm trying to create a script which will go through
each group on the server and identify any file owned by that group which has
write access for either group or world (it's using the group owner because
that's how we assign responsibility)

Here is the snippet of code I'm using:

   ${ECHO} "Directories:" >> ${REPORT_FILE}
   ${ECHO} >> ${REPORT_FILE}
   ${FIND} / -group ${GROUP} -type d -perm -g=w -o -perm -o=w -exec ls -la
{} \\\; >>${REPORT_FILE}
   ${ECHO} >> ${REPORT_FILE}
   ${ECHO} "Files:" >> ${REPORT_FILE}
   ${ECHO} >> ${REPORT_FILE}
   ${FIND} / -group ${GROUP} -perm -g=w -o -perm -o=w -exec ls -la {} \\\;
>>${REPORT_FILE}

If I put an echo in front of each of the find commands, the output looks
correct:

/usr/bin/find / -group root -perm -g=w -o -perm -o=w -exec ls -la {} \;

However, it complains about exec not ending in an ";", which it clearly has
in the echo statement. Any ideas?

Also, typing the command at the command line exactly as shown in the echo
statement works just fine.
---------------------------------------------------------
Gary Paveza, Jr.
Technical Specialist - Architecture - HP CSE, SCSA
(302) 252-4831 - phone

--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)


This archive was generated by hypermail 2.1.7 : Sat Apr 12 2008 - 11:02:56 EDT