Sharing NAS

tnavarra
Posts: 10
Joined: Thu Apr 29, 2010 12:19 pm

Sharing NAS

Postby tnavarra » Fri May 07, 2010 12:13 pm

I have a NAS (Maxtor, central axis). I use the NAS for all my working files and media.

I have been unable to see this disk with Amahi. If I am in Fedora, I can connect to the NAS and navigate through the files.

I would like to be able to mount directories in the NAS to existing shares.

Can I get some tips on how to do this? I have searched the forums and have not found too much on this topic.

Thanks

User avatar
cpg
Administrator
Posts: 2618
Joined: Wed Dec 03, 2008 7:40 am
Contact:

Re: Sharing NAS

Postby cpg » Sat May 08, 2010 2:01 pm

The idea is to do that in two steps:
  • mount the NAS shares to your HDA
  • make them available as Amahi shares to the rest of the network
The second step is just customizing the share path to be that path where you mounted the NAS shares.

NOTE: that page linked above in the wiki may need a bit of polishing. I just did a bit of it, however, it may need more. please do update/improve it as much as you can.
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 8GB RAM, 1TBx2+3TBx1

tnavarra
Posts: 10
Joined: Thu Apr 29, 2010 12:19 pm

Re: Sharing NAS

Postby tnavarra » Tue May 11, 2010 11:56 am

I had actually tried the "How to Mount a NAS" in the Wiki. So I went back and back tracked on my actions to see if I would get a different reaction. No change.

I am logged in as root.

Code: Select all

mount -a
response -

Code: Select all

line 17 in /etc/fstab is bad
Line 17 is -

Code: Select all

//192.168.1.106/My Documents/My Music /var/hda/files/music cifs credentials=/root/.smbcredentials,iocharset=utf8,file_mode=0777,dir_mode=0777 0 0
I have the ip address of my NAS, the directory, the mount point, my credentials, the rest I don't understand but am copying from the wiki.

I have searched high and low and cannot find what I am doing wrong

Thanks

User avatar
cpg
Administrator
Posts: 2618
Joined: Wed Dec 03, 2008 7:40 am
Contact:

Re: Sharing NAS

Postby cpg » Tue May 11, 2010 4:27 pm

the spaces in the share name may be the problem.

try using \040 instead of a space.

from the man fstab page:
If the name of the mount point contains spaces these can be escaped as ‘\040’.
i.e.

Code: Select all

//192.168.1.106/My\040Documents/My\040Music
why would fstab not use quotes or something sane, beats me.
My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 8GB RAM, 1TBx2+3TBx1

User avatar
moredruid
Expert
Posts: 791
Joined: Tue Jan 20, 2009 1:33 am
Location: Netherlands
Contact:

Re: Sharing NAS

Postby moredruid » Wed May 12, 2010 12:19 am

and the netfs syntax for /etc/fstab is:

Code: Select all

192.168.1.106:/this/is/your/nas/share /this/is/your/mount/point <the rest here>
echo '16i[q]sa[ln0=aln100%Pln100/snlbx]sbA0D2173656C7572206968616D41snlbxq' | dc
Galileo - HP Proliant ML110 G6 quad core Xeon 2.4GHz, 4GB RAM, 2x750GB RAID1 + 2x1TB RAID1 HDD

tnavarra
Posts: 10
Joined: Thu Apr 29, 2010 12:19 pm

Re: Sharing NAS

Postby tnavarra » Wed May 12, 2010 7:41 am

I made a lot of changes, but I hope I get the critical path to a solution right in this post.

I made the change of using the ASCII code of \040 for space in my windows directory structure. This left me with a new error message.
retrying with upper case share name
mount error(6): No such device or address
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
I googled this. There were a lot of different solutions that all boiled down to the solution I was already using.

One of the posts (http://opensuse.swerdna.org/susesambacifs.html) really filled in my education, but was no help with my problem. Finally I found a post that suggested using smbtree. When I did so, I found my NAS was not in the tree structure. With this hint, I went back to my NAS settings and made sure that my workgroup was set the same as all the other computers (Earlier in this process, I had found that I had two work groups - MSHOME and GECKO). The work group was the same. However, I ran a utility (forget which one) and it showed the workgroup was still MSHOME.

On a hunch, I set the IP address of the NAS (with it's own utility) to static and then updated. This also changed the workgroup. The next time I ran smbtree, the NAS was there.

[root@GeckoSrrrver ~]# smbtree
Enter root's password:
GECKONET
GECKO
\\TOKEK Maxtor Central Axis
\\TOKEK\ADMIN$ IPC Service (Maxtor Central Axis)
\\TOKEK\IPC$ IPC Service (Maxtor Central Axis)
\\TOKEK\GeckoNetFiles GeckoNetFiles
\\TOKEK\Public Public
\\TOKEK\config config
\\GECKOONE
\\GECKOONE\Brother DCP-7020 USB Printer Brother DCP-7020 USB Printer
\\GECKOONE\Gecko One Shared Documents
\\GECKOONE\My Local Documents
\\GECKOONE\My Music
\\GECKOONE\print$ Printer Drivers
\\GECKOONE\IPC$ Remote IPC
\\GECKOONE\My Documents
\\BULLDOG
AHA!

I needed to use this as the address of the NAS -
\\TOKEK\GeckoNetFiles

Back to fstab and changed the line -
//192.168.1.106/GeckoNetFiles/My\040Documents/My\040Music /var/hda/files/music/ cifs guest, _netdev 0 0

Mounted fine and I can browse my music on the NAS.

Thanks to everyone who has helped. Sure to have more questions in the future.

Tony

Who is online

Users browsing this forum: No registered users and 23 guests