NFS .... question

Scott Manley (spm@star.arm.ac.uk)
Sun, 14 Feb 1999 16:26:32 +0000


A little bit of confusion over what's happening with NFS - can anyone
enlighten me? It's not urgent.... I'm just wondering exactly what's going
where....

Picture the scene - a standard redhat 5.2 alpha setup with 5 1GB disks hooked
up to it. 4 of these were exported under a single directory via NFS.

The NFS client was a redhat derived 2.2.1ac5 system.

Can anyone explain why NFS would let me copy a 1.3 GB file to one of the disks?
The File ends halfway through - the rest of its length is padded with zeros.

[spm@arpc disk2]$ ls -l
total 932138
drwxr-xr-x 2 spm root 12288 Feb 5 17:12 lost+found
-rw-r--r-- 1 spm spm 1296355328 Feb 14 09:33 new.shn

[spm@arpc disk2]$ df
Filesystem 1024-blocks Used Available Capacity Mounted on
/dev/hda4 4307071 3657355 426815 90% /
/dev/hdd2 143048 25268 117780 18% /mnt/scratch
alpha:/mnt/dat 908818 491259 370606 57% /home/spm/data/

So - the NFS client on my end doesn't see the disk being full.

[spm@alpha spm]$ ls -l /mnt/data/disk2/
total 932138
drwxr-xr-x 2 spm root 12288 Feb 5 17:12 lost+found/
-rw-r--r-- 1 spm spm 1296355328 Feb 14 09:33 new.shn

that says I've got a 1.3GB file in a <1GB file system

Running du at one end gave me...
1024-blocks Used Available Capacity Mounted on
/dev/sda3 908818 491261 370604 57% /
/dev/sdb1 982915 519472 412667 56% /mnt/dat/disk1
/dev/sdc1 982915 932139 0 100% /mnt/dat/disk2
/dev/sdd1 982915 924656 7483 99% /mnt/dat/disk3
/dev/sde1 982915 446546 485593 48% /mnt/dat/disk4

But the NFS server considers the disk to be full

Then after rming the file I got....
Filesystem 1024-blocks Used Available Capacity Mounted on
/dev/sda3 908818 491261 370604 57% /
/dev/sdb1 982915 519472 412667 56% /mnt/dat/disk1
/dev/sdc1 982915 13 932126 0% /mnt/dat/disk2
/dev/sdd1 982915 924656 7483 99% /mnt/dat/disk3
/dev/sde1 982915 446546 485593 48% /mnt/dat/disk4

I can do really stupid things too....

[spm@arpc disk3]$ cat /dev/zero > bigfile.dat
... wait a long time - not too long - disk 3 is 99% full already...

[spm@alpha disk3]$ df
Filesystem 1024-blocks Used Available Capacity Mounted on
/dev/sda3 908818 491261 370604 57% /
/dev/sdb1 982915 519472 412667 56% /mnt/mp3/disk1
/dev/sdc1 982915 13 932126 0% /mnt/mp3/disk2
/dev/sdd1 982915 932145 0 100% /mnt/mp3/disk3
/dev/sde1 982915 446546 485593 48% /mnt/mp3/disk4

[spm@alpha disk3]$ ls -l bigfile.dat
-rw-rw-r-- 1 spm spm 101257216 Feb 14 16:22 bigfile.dat

[spm@alpha4 disk3]$ ls -l bigfile.dat
-rw-rw-r-- 1 217 svj 200445952 Feb 14 16:24 bigfile.dat

it just keeps growing....

I guess what I'm asking is - is this normal WRT NFS behaviour?

Scott Manley (aka Szyzyg) /------ _@/ Mail -----\
___ _ _ __ __ _ | Armagh Observatory |
/ __| __ ___| |_| |_ | \/ |__ _ _ _ | |___ _ _ | Armagh |
\__ \/ _/ _ \ _| _| | |\/| / _` | ' \| / -_) || | | Northern Ireland |
|___/\__\___/\__|\__| |_| |_\__,_|_||_|_\___|\_, | | BT61 9DG. |
http://star.arm.ac.uk/~spm/welcome.html |__/ \=====================/

-
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/