Re: Loopback (dir->dir) mounting (NOT -o loop)

From: H. Peter Anvin (hpa@transmeta.com)
Date: Thu Jun 01 2000 - 19:53:09 EST


"Kenneth C. Arnold" wrote:
\> >
> > But seriously, though... think of:
> >
> > mount -t bind /home/user /home/user/again
> >
> > Looking at dev_t won't help you, so your backup will recurse indefinitely.
>
> Actually, no.
>
> # mkdir /home/test
> # mkdir /home/test/again
> # mount -t bind /home/test /home/test/again
> # ls /home/test
> again
> # ls /home/test/again
> # echo "Not."
> Not.
>
> But I would like a fs that _could_ do that.
>
> Kenneth

Fine, then:

g=1
while [ $g -lt 10000 ]; do
        mkdir /home/user/junk/$g
        mount -t bind /home/user/megadir /home/user/junk/$g
        g=`expr $g + 1`
done

        -hpa

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Jun 07 2000 - 21:00:13 EST