Bug 5596 - Can't export root filesystem (/) via local drives
Summary: Can't export root filesystem (/) via local drives
Status: NEW
Alias: None
Product: ThinLinc
Classification: Unclassified
Component: Local drive redirection (show other bugs)
Version: 4.4.0
Hardware: PC Unknown
: P2 Normal
Target Milestone: LowPrio
Assignee: Bugzilla mail exporter
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-07-14 16:31 CEST by Karl Mikaelsson
Modified: 2023-05-16 13:39 CEST (History)
1 user (show)

See Also:
Acceptance Criteria:


Attachments

Description Karl Mikaelsson cendio 2015-07-14 16:31:23 CEST
For some reason, I wanted to export the filesystem root (/). When trying to mount the local drives, this is what happened:

> $ tl-mount-localdrives -v
> Running ['/opt/thinlinc/libexec/tl-mount-personal', '-o', 'mountport=4914,port=4914,mountvers=3,nfsvers=3,nolock,tcp', '-o', 'fg,soft,intr,actimeo=2,rsize=524288,wsize=524288,timeo=50,retrans=1', '-n', 'localhost:@otp:301bedb08e4fe77af4a4db0c8fc3b536', '/var/opt/thinlinc/sessions/cendio/1/drives/']
> mount.nfs: mounting localhost:@otp:301bedb08e4fe77af4a4db0c8fc3b536 failed, reason given by server: No such file or directory

So, tl-mount-localdrives strips the any trailing slash from the path to be mounted, and when the path to be mounted is a single slash, it happily removes that too.

While it's easy to count the number of slashes, the next problem is that tl-mount-localdrives is trying to mount the exported filesystem root '/' on $SESSIONDIR/drives/ - on top of any other mount, which leads to later mounts failing (unless you're root on both client and server) and earlier mounts being overshadowed. So we'd have to introduce some kind of translation layer here, and with that you risk mount conflicts. Not sure if tl-mount-localdrives or the client already has ways to work around this.

Note You need to log in before you can comment on or make changes to this bug.