"find" problem

Cameron Simpson cs at zip.com.au
Sat Jan 7 09:02:21 UTC 2012


On 06Jan2012 23:29, Dean S. Messing <deanm at sharplabs.com> wrote:
| In doing more experimenting with find, I discovered that
| / is evidently fstype "rootfs", whatever that is.

Interesting.

| Looking in /etc/mtab I see:
|    rootfs / rootfs rw 0 0

I was going to suggest you run the "mount" command, but I see you're
ahead of me.

| and 
|    /dev/mapper/vg00-lv_root / ext4
|    rw,relatime,user_xattr,acl,barrier=1,stripe=32,data=ordered 0 0
|
| In fact,
|    find /  -fstype rootfs -print
| prints all the files and ordinary directories under /.

Which makes sense, given the above.

| None of the ext4 mounts are entered, nor are /proc or /sys, &c.

As you'd hope!

|    find /  -fstype ext4 -print
| only prints the entries in ext4 directories mounted in /.

Well at least it is all nice and consistent.

| This behaviour thoroughly breaks some of my scripts.

Fun fun fun. What assumptions are you making (aside from ext4 == regular
filesystem)? Are you simply trying to avoid /proc and /dev etc? And NFS
mounts I guess?

Cheers,
-- 
Cameron Simpson <cs at zip.com.au> DoD#743
http://www.cskk.ezoshosting.com/cs/

I bested him in an Open Season of scouring-people's-postings-looking-for-
spelling-errors.        - kevin at rotag.mi.org (Kevin Darcy)


More information about the users mailing list