Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Can't browse /media subdirs through NFS
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
urcindalo
Guru
Guru


Joined: 08 Feb 2005
Posts: 590
Location: Almeria, Spain

PostPosted: Mon Oct 15, 2012 3:50 pm    Post subject: Can't browse /media subdirs through NFS Reply with quote

Hi!

I own a Xtreamer multimedia HD connected to my TV, and I can browse my laptop NFS configured directories from it. However, I can't browse the folders in /media if I set up /media as the directory to share.

Let me elaborate to better explain the issue. This is my current /etc/exports file:
Code:
$ cat /etc/exports
# /etc/exports: NFS file systems being exported.  See exports(5).
/media/Almacen250GB/ 192.168.1.0/255.255.255.0(insecure)
/media 192.168.1.0/255.255.255.0(insecure)


With this set up I can perfectly browse the contents of /media/Almacen250GB/ on my TV through the multimedia HD. However, to my suprise, when I want to browse the same folder from the /media share point, I can see its subfolder Almacen250GB appearing, but with an empty content.

In other words, when clicking on the /media/Almacen250GB/ share point, I can browse through its subfolders and select whichever file I please. But, when clicking on the /media share point, after entering into its Almacen250GB subfolder, the latter is empty.

Why is that? Am I missing something? What must I do to browse any subfolder in /media?
I need that to display the content of any USB device I connect to the computer on the TV, without setting up an explicit share point for every one of them.

Thanks in advance.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 42583
Location: 56N 3W

PostPosted: Mon Oct 15, 2012 5:25 pm    Post subject: Reply with quote

urcindalo,

Are we really talking directories or are the directories in question used as mount points for other block devices?
NFS does not by default make the contents of mount points available when you share and mount the parent filesystem
The NFS client needs to mount this for itself.

Read up on the nohide option in the man page
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
_______0
Guru
Guru


Joined: 15 Oct 2012
Posts: 521

PostPosted: Mon Oct 15, 2012 7:00 pm    Post subject: nfs known limitations Reply with quote

nfs can't share dynamically mounted devices. However before further speculating about it first provide detailed info about ur setup:

mount info
nfs version info
etc...

more logs

looks like ur using obsolete nfs3 there.
Back to top
View user's profile Send private message
Thistled
Guru
Guru


Joined: 06 Jan 2011
Posts: 548
Location: Scotland

PostPosted: Mon Oct 15, 2012 11:07 pm    Post subject: Re: nfs known limitations Reply with quote

________________________0 wrote:
nfs can't share dynamically mounted devices. However before further speculating about it first provide detailed info about ur setup:

mount info
nfs version info
etc...

more logs

looks like ur using obsolete nfs3 there.


How is NFS3 obsolete?
I use it without a problem.
There is no mention of it being obsolete or deprecated in the Kernel config.
:?:
_________________
Whatever you do, do it properly!
Back to top
View user's profile Send private message
urcindalo
Guru
Guru


Joined: 08 Feb 2005
Posts: 590
Location: Almeria, Spain

PostPosted: Tue Oct 16, 2012 3:20 pm    Post subject: Reply with quote

First of all, thanks everybody for your help.
Indeed, my directories are mount points for other block devices. That's why they are in /media :)

Thanks for pointing me out to the nohide option, although in my case it was crossmnt that was needed. From the exports man page:
Code:
crossmnt
 This option is similar to nohide  but it makes it possible for clients to move from the filesystem marked with crossmnt to exported filesystems mounted on it. Thus when a child filesystem "B" is mounted on a parent "A", setting crossmnt on "A" has the same effect as setting "nohide" on B.


So, after changing my /etc/exports to this:
Code:
$ cat /etc/exports
# /etc/exports: NFS file systems being exported.  See exports(5).
/media/ 192.168.1.60(crossmnt,subtree_check)

it now works with my internal ReiserFS and an external ext4 partitions.

However, to my surprise, I can't see the content of two FAT32 4GB pendrives.
Any clue on this? The client is an Xtreamer device running a Linux 2.6.12.6-VENUS kernel. So, apart from actually running Linux, the client device is able to read both FAT32 pens when they are plugged into its USB port. And, of course, my laptop also deals with them perfectly well.

Thanks in advance.
Back to top
View user's profile Send private message
urcindalo
Guru
Guru


Joined: 08 Feb 2005
Posts: 590
Location: Almeria, Spain

PostPosted: Tue Oct 16, 2012 3:38 pm    Post subject: Reply with quote

I think I got the answer to my last question, but can't solve the matter :?

When taking a look at /media, I found out my Linux formatted partitions have drwxrwxrwx permissions and belong to root:root
On the other hand, my FAT32 mounted partitions have drwx------ permissions and belong to me.

Take a look at this series of commands:
Code:
/media $ ls -la
total 5
-rw-r--r--  1 root   root      0 may 11  2011 .hal-mtab
-rw-r--r--  1 root   root      0 jun 13 16:15 .keep_sys-fs_udisks-0
drwx------  4 myname myname 4096 ene  1  1970 9AFA-DB42
drwxrwxrwx 23 root   root    816 oct 15 16:57 Almacen250GB
/media $ chmod a+rwx 9AFA-DB42
/media $ ls -la
total 5
-rw-r--r--  1 root   root      0 may 11  2011 .hal-mtab
-rw-r--r--  1 root   root      0 jun 13 16:15 .keep_sys-fs_udisks-0
drwx------  4 myname myname 4096 ene  1  1970 9AFA-DB42  ----> FAT32 mounted pendrive
drwxrwxrwx 23 root   root    816 oct 15 16:57 Almacen250GB  ----> Internal ReiserFS partition


Why can't I change the permissions on the mounted FAT32 pendrive?
Back to top
View user's profile Send private message
Veldrin
Veteran
Veteran


Joined: 27 Jul 2004
Posts: 1945
Location: Zurich, Switzerland

PostPosted: Tue Oct 16, 2012 4:57 pm    Post subject: Reply with quote

fat32 does not understand unix permission.

but you can assign a certain permission set (and owner) at mount time using umask, dmask, fmask, gid, and uid respectively (use man mount for details).

for mounting (more or less) permanent storage, i suggest that you use /mnt and not /media.

V.
_________________
read the portage output!
If my answer is too concise, ask for an explanation.
Back to top
View user's profile Send private message
urcindalo
Guru
Guru


Joined: 08 Feb 2005
Posts: 590
Location: Almeria, Spain

PostPosted: Wed Oct 17, 2012 2:30 pm    Post subject: Reply with quote

Veldrin wrote:
fat32 does not understand unix permission.

Oops! You're absolutely right. Sometimes I forget it's a crap filesystem :roll:

Veldrin wrote:
but you can assign a certain permission set (and owner) at mount time using umask, dmask, fmask, gid, and uid respectively (use man mount for details).

I know, but the goal is to plug & play :)

Veldrin wrote:
for mounting (more or less) permanent storage, i suggest that you use /mnt and not /media.

I prefer not to bloat fstab and to let udisks decide. Again, the lesser I intervene, the more convenient :)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum