Skip to contentSkip to conversation

VFS mediator?

DISCUSSION Jesse Pollard 2 participants 2 messages Mar 19, 2002

lore
Share & tools
lore
#0 lore raw

Pavel Machek <[email protected]>:

Quoted 16 lines

Hi!

Quoted 14 lines

> Okay, take userland nfs-server. (This thread was about userland > filesystems).

Yech... Nobody should be seriously considering using unfsd: it does not even manage to follow the NFS protocol. That inability was one of the many reasons why Olaf Kirch abandoned further develpement of unfsd and started work on knfsd.

> Then, make memory full of dirty pages. Imagine that nfs-server > is swapped-out by some bad luck. What you have is extremely > nasty deadlock, AFAICS. [To free memory you have to write out > dirty data, but you can't do that because you don't have enough > memory for nfs-server].

Quoted 6 lines
Quoted 3 lines

So that is another argument for using knfsd rather than unfsd. I will agree with you that NFS is not perfect, but please judge it on its actual merits and not on some trumped up charge...

Sorry, this thread was about userland filesystems, and NFS is just not usefull there (for read/write case).

Assuming, of course, that the daemon doesn't mprotect itself...

A user mode file system is really only good at debugging a design.

All file migration style filesystems, and user mode filesystems, have this same problem on paging based systems:

Can't write buffer until file is migrated (file system full), Can't migrate file until buffer memory is freed.... system hung...

Although it is usually possible to detect this deadlock and abort some process, freeing memory (and sometimes disk space at the same time).

Swapping systems can have the equivalent problem if swap space is oversubscribed.

The problem boils down to the same solution - don't oversubscribe memory...

I know this is a bit of a troll, but memory controls are necessary to detect, avoid, or repair the situation.
-------------------------------------------------------------------------
Jesse I Pollard, II
Email: [email protected]

Any opinions expressed are solely my own.

#1 lore raw

Hi!

Quoted 14 lines
Quoted 14 lines
Quoted 14 lines

> Okay, take userland nfs-server. (This thread was about userland > filesystems).

Yech... Nobody should be seriously considering using unfsd: it does not even manage to follow the NFS protocol. That inability was one of the many reasons why Olaf Kirch abandoned further develpement of unfsd and started work on knfsd.

> Then, make memory full of dirty pages. Imagine that nfs-server > is swapped-out by some bad luck. What you have is extremely > nasty deadlock, AFAICS. [To free memory you have to write out > dirty data, but you can't do that because you don't have enough > memory for nfs-server].

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

So that is another argument for using knfsd rather than unfsd. I will agree with you that NFS is not perfect, but please judge it on its actual merits and not on some trumped up charge...

Sorry, this thread was about userland filesystems, and NFS is just not usefull there (for read/write case).

Assuming, of course, that the daemon doesn't mprotect itself...

Even if it did, I'm not sure it would be safe. write() may need some memory, too.

Quoted 1 line

A user mode file system is really only good at debugging a design.

Not agreed. I would not want ftpfs in kernel, yet its happy in userland.

Quoted 4 lines

All file migration style filesystems, and user mode filesystems, have this same problem on paging based systems:

Can't write buffer until file is migrated (file system full),

Well, filesystem full is nasty case. [I wonder how coda solves that?]
Pavel

Signature · 2 lines
Casualities in World Trade Center: ~3k dead inside the building,
cryptography in U.S.A. and free speech in Czech Republic.