On Wednesday 26 February 2003 21:01, Oliver Ob wrote:
Dylan schrieb:
On Wednesday 26 February 2003 19:00, Oliver Ob wrote:
Alright, this is the third one for today.
I have 2 PCs here, PC One mounts NFS shares from PC TWO.
Both use Suse 7.3
TWO's export: / IPofPCone(rw,no_root_squash)
Now that I mount it on PCone, I have the whole / tree of "2" in my mnt.
Now the problem. I mounted another Linux HDD (Type83) inside PC TWO, why cant I see this one on PCOne, even though I have exported ENTIRE "/" to do just this?
Have a look in man exports - there are options which restrict or allow the exporting of sub-filesystems. There are security and reliability issues with this, however. It would be better to export filesystems one-by-one, and not export / (root fs) unless it's necessary.
It IS necessary for this case.
OK, no need to SHOUT. Why is it necessary? You are opening a massive security and reliability hole.
So is the export line (see above!) wrong?
No, it's right but it will _not_ export the second filesystem. Look at the nohide option in the manpage I mentioned. It says: <QUOTE> nohide This option is based on the option of the same name provided in IRIX NFS. Normally, if a server exports two filesystems one of which is mounted on the other, then the client will have to mount both filesystems explicitly to get access to them. If it just mounts the parent, it will see an empty directory at the place where the other filesystem is mounted. That filesystem is "hidden". Setting the nohide option on a filesystem causes it not to be hidden, and an appropriately authorised client will be able to move from the parent to that filesystem without noticing the change. However, some NFS clients do not cope well with this situation as, for instance, it is then possible for two files in the one apparent filesys tem to have the same inode number. The nohide option is currently only effective on single host exports. It does not work reliably with netgroup, subnet, or wildcard exports. This option can be very useful in some situations, but it should be used with due care, and only after confirming that the client system copes with the situation effectively. The option can be explicitly disabled with hide. </QUOTE> You may encounter reliability problems if you use this - If you _really_need to do it like this, then I'd recommend the following: mount the remote root-fs under /mnt mount the remote secondary-fs (via a separate nfs export) in the same place relative to /mnt as on the remote machine. Either way, SFAIK you need to explicitly export *both* filesystems. Dylan -- "Sweet moderation Heart of this nation Desert us not We are between the wars" Billy Bragg