Score:0

Mapping network drives to a shared sub-folder

in flag

I have shared a folder on my local machine as follows; /home/don/storage it appears in the fstab file as: /dev/sdb2 /mnt/storage

This in turn has a folder sturutre as follows; /home/don/storage/data and /home/don/storage/data/downloads and /home/don/storage/data/media

I have a Truenas server with two datasets with two separate SMB shares /tv and /movies

I would like to map the network drives to the following share on my Ubuntu server /data/media/tv (1st mapped network drive) and /data/media/movies (2nd mapped network drive). Can this be done?

What is the proper syntax to map this in the fstab file?

192.168.1.20/tv /mnt/ xxxxx?. 192.168.1.20/movies /mnt/ xxxxx?

ar flag
https://wiki.ubuntu.com/MountWindowsSharesPermanently
ar flag
Does this answer your question? [Proper fstab entry to mount a samba share on boot?](https://askubuntu.com/questions/157128/proper-fstab-entry-to-mount-a-samba-share-on-boot)
Donnie avatar
in flag
I have the correct syntax for the fstab what I need to know is if you can map two network shares to a single mount point.
ar flag
No you can't. You need 2 separate fstab lines. Anyway, if I understand you, you want each share in it's own subfolder of /data/media.
Donnie avatar
in flag
Yes, that's right, I currently have the syntax and two separate lines within the fstab file but they are as root folders. I want to mount them as separate directories within a parent directory ( like /mnt/media/tv and /mnt/media/movies) is this possible? They would be two separate lines within the fstab file. to be clear, can I have two mount points within a directory?
ar flag
Yes, if I understand what you mean, that is fine. Have you tried? If it doesn't work as you expect, post details.
Donnie avatar
in flag
I found a new command to use to join several filesystems together to form a single larger one (mhddfs). This did the job and worked. //192.168.1.151/Movies /mnt/movies cifs user=(XXX),password=(XXX)$,rw,uid=(XX),noperm 0 0 //192.168.1.151/TV /mnt/tv cifs user=(XXX),password=(XXX),rw,uid=(XX),noperm 0 0 mhddfs#/mnt/tv,/mnt/movies /mnt/media fuse defaults,allow_other 0 0
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.