Hi, I did man find and everything... What i am doing is deleting the 0 size files within a directory and using exec with find. find ./ -size 0 -type f -exec rm { } \; But the above command is not working.. On Mon, Apr 25, 2011 at 3:57 AM, Cameron Simpson <cs@xxxxxxxxxx> wrote: > On 24Apr2011 23:23, Abhilash abhi <abhilashck72@xxxxxxxxx> wrote: > | Why there is no command `exec` in RHEL5. > | > | [root@localhost ~]# which exec > | /usr/bin/which: no exec in > | > (/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/root/bin) > > "exec" is a shell builtin; it _cannot_ be a standalone command. > > | because of this i am not able to execute finds output using exec!! > > Urr, or as another poster points out, the "exec" in find is a switch, > and is spelt "-exec". Eg: > > find . -type d -exec ls -ld {} ';' > > See "man find" for details. > > Cheers, > -- > Cameron Simpson <cs@xxxxxxxxxx> DoD#743 > http://www.cskk.ezoshosting.com/cs/ > > The ship is cold -- and damp. I complain -- but no one listens. > - Capt. Kirk, Star Trek XXIII: _So Very Tired_ > Jim Hill <jimhill@xxxxxxxxxxxxxxxx> > > -- > redhat-list mailing list > unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe > https://www.redhat.com/mailman/listinfo/redhat-list > -- Regards, Abhilash -- redhat-list mailing list unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe https://www.redhat.com/mailman/listinfo/redhat-list