What's new

Permanent Samba Mount AC66r

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

drice717

New Around Here
I want to create a permanent samba mount on my AC66r. For example - I have a share on a Windows 7 machine that I want to always be accessible from my router. I also want this to show up if I network browse to \\RT-AC66r. Hopefully this will show up in AiCloud as well but I'm not as concerned with that.

I have successfully mounted my samba share on the router through SSH using:

mount \\\\192.168.0.4\\MOV_VOL1 /mnt/MOV_VOL1 -t cifs -o username=user,pass=pass

Confirmed by doing a directory listing on /mnt/MOV_VOL1 - my files show up.

Next I began looking at the samba config and potentially storing a jffs add-on script to add a similar entry like this to smb.conf:

[TOSHIBA_EXT]
comment = TOSHIBA External USB 3.0's TOSHIBA_EXT
path = /tmp/mnt/TOSHIBA_EXT
writeable = yes

_________________________________________________

So this is where I ran into issues - I assume I need to use nmbd somehow and add that as an add-on script as well. I can see in the log files where it does a hotplug to find a USB device that just got added to the router and then the router does a samba share. I want to emulate this with my network share whenever my router reboots.

Things to keep in mind: I *do* have one USB hard drive connected to the router currently so as to keep the samba running (I read somewhere that samba isn't available if something is not plugged in).


The reason I'm doing all of this, is because I've found with multiple file handlers opened on the drives connected to my router, I end up getting errors with I/O reads and then the USB device catastrophically fails - disconnects from the router, and then upon resetting the USB device - the file system is corrupt. I have to take the drive over to a windows machine to fix the file system - this is becoming cumbersome, and I'm losing files. As much as I want my drives to be connected to my router 24/7 - I would much rather have file stability. So I will leave my drives connected to my Windows 7 machine and 'trick' the router into thinking it's holding those files.

I KNOW someone has done this already - I just can't find it in the forums.
 
Re-sharing a share isn't really efficient. Your router will greatly reduce the throughput, as you will put the load on your router for accessing the share, and sharing the data. I wouldn't be surprised if it dropped the throughput to around 6-8 MB/s max, versus 60-70 MB/s that could be attained from a Windows PC connected over gigabit.

If for some reason you still want to do this, the best way to manually add a new share to smb.conf is through a custom config addon, as described on the Wiki.
 
Okay, that makes sense - what if my throughput is already at 6-8. I would *love* to see those speeds, is it possibly the Cat5e cable I'm using? I don't have a gigabit card with the laptop that is directly connected. Everything says its connected at 100 mbps but I can only transfer files to the router attached hard drives at a maximum of 8.5 mpbs. My wireless transfer to the same hard drive is only 5 mbps *MAX*.
 
Okay, that makes sense - what if my throughput is already at 6-8. I would *love* to see those speeds, is it possibly the Cat5e cable I'm using? I don't have a gigabit card with the laptop that is directly connected. Everything says its connected at 100 mbps but I can only transfer files to the router attached hard drives at a maximum of 8.5 mpbs. My wireless transfer to the same hard drive is only 5 mbps *MAX*.

100 Mbits should give you around 8 MB/s on average (note the distinction between bits and bytes here).

The fastest this router can stream from a plugged USB disk is around 15-17 MB/s, so a bit faster than what your 100 Mbits laptop can support.
 

Similar threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top