lkml.org 
[lkml]   [2003]   [Jul]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectbug in loopback device (Linux version 2.6.0-test2)
Hi!

I found a bug in the loopback device.
See this two different results (the difference: in the second case I use
`-o loop' mount option for mounting /dev/hda3 to /hda3_copy

First case:
mount -t reiserfs /dev/hda3 /hda3
mount -t reiserfs /dev/hda3 /hda3_copy
rm -f /hda3/* /hda3_copy/*
ls -l /hda3/ /hda3_copy/
touch /hda3/xxx /hda3_copy/yyy
echo
ls -l /hda3 /hda3_copy
umount /hda3
umount /hda3_copy

The result is:
/hda3/:
total 0

/hda3_copy/:
total 0

/hda3:
total 0
-rw-r--r-- 1 root root 0 Jul 30 13:15 xxx
-rw-r--r-- 1 root root 0 Jul 30 13:15 yyy

/hda3_copy:
total 0
-rw-r--r-- 1 root root 0 Jul 30 13:15 xxx
-rw-r--r-- 1 root root 0 Jul 30 13:15 yyy

Everything is OK.
-----------------------------------------------------------------------
Second case:

mount -t reiserfs /dev/hda3 /hda3
mount -o loop -t reiserfs /dev/hda3 /hda3_copy
rm -f /hda3/* /hda3_copy/*
ls -l /hda3/ /hda3_copy/
touch /hda3/xxx /hda3_copy/yyy
echo
ls -l /hda3 /hda3_copy
umount /hda3
umount /hda3_copy

And the result:
/hda3/:
total 0

/hda3_copy/:
total 0

/hda3:
total 0
-rw-r--r-- 1 root root 0 Jul 30 13:17 xxx

/hda3_copy:
total 0
-rw-r--r-- 1 root root 0 Jul 30 13:17 yyy
---------------------------------------------------------------------------
Its quite interesting :-) Why to store to copy of the directory in the
memory? It causes inconsistency, and wastes memory.

Bye,
Istvan


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

\
 
 \ /
  Last update: 2005-03-22 13:47    [W:0.089 / U:0.356 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site