Find hangs when ran under superuser.

When I ran the following find command under a "regular" user is completes but it limited because of perms.

find / -name "*.*" | xargs grep something > ok

But when I try to run it under su, it hangs and never completes.

Any suggestion?

Another way:

find / -type f | xargs grep "something" > ok

Also pls check the content of "ok" file if it is getting new data all the time when find command is running.

tail -f ok

Try something like
find / -type f |tee /tmp/output| xargs grep "something" > ok
and on other shell tail -f /tmp/output
to see what is happening.
It might be that it runs into network directory unaccesible for a normal.
That find might be run as
find / -type f -exec grep "something" {} \;
Regards
Sebastian

But when I try to run it under su, it hangs and never completes.

Please post the exact lines you typed both with and without the "su" and state clearly which computer should receive the file called "ok".

Btw. Unix is not MSDOS. There is no significance in a period (.) in a filename except perhaps when transferring files to/from MSDOS. However if your "find" is only looking for filenames containing period then your script is nearly right.

If you run this it will process /dev and /proc which have system devices, and
there is a good chance it will never finish.
As other people here have suggested I would use "-type f" instead of "-name *.*". This will limit the find to files only, which although may take some time, it will eventually finish.