HDsamba2 on WNR3500L installation errors

12 posts / 0 new
Last post
Ed Hut
Ed Hut's picture
HDsamba2 on WNR3500L installation errors

Hi all,

I'm running DD-WRT on my WNR3500L. Works fine, but now I want to add a USB harddisk as extra storage. In order to access the drive from Windows boxes in an easy way, I want to run Samba on the router and the easiest way to go, or so it seemed, was to use HDsamba2 as described on this Wiki page:
http://www.dd-wrt.com/wiki/index.php/HDsamba2

I've setup the partitions as described, only using ext3 and linux-swap as file systems. Upon installation, I get the following messages in the log file:

HDsamba2 v5.60
Start Installation Log
---------------------------------------------------------
Mon Apr 12 23:25:14 UTC 2010
Detected valid time server !
Detected JFFS !
Detected adequate JFFS space !
Detected USB Storage Device !
SAFEMOUNT: No disc can be found with GUID , exiting

After digging a bit in the HDsamba2 script, I found that the script may not be suitable for how DD-WRT works in combination with the WNR3500L. The script contains a safemount function that cannot figure out which drives are available on the system. After hacking a bit in the safemount function, I got a little bit further, but then hit another wall.

My question: who has used the HDsamba2 install script (V5.6) successfully on the WNR3500L with DD-WRT? Can it actually work and am I doing something (obvious) wrong? If so, please help me in finding out how to proceed.

Many thanks,
Ed

Brandon C
Brandon C's picture
Did you try the detection
Ed Hut
Ed Hut's picture
I used the detection script

I used the detection script already to find out how I should enter the partition id's that the script asks for. That is in task 3 of the install script and it succesfully configures the JFFS in that step (if I remember it correctly). The script runs into an error in task 4, where it tries to detect all available drives connected to the system. In a function called _safemount it greps certain data and there it goes wrong. I would like to know if the HDsamba installation script has already been run successfully in WNR3500L routers. If so, then I must be doing something wrong. If not, then I think I can either try to make the script work or look for another way to install Samba on the router, e.g. with Slimsamba.

Ed Hut
Ed Hut's picture
Well, I finally made HDsamba2

Well, I finally made HDsamba2 work on my WNR3500L. I had to edit the version 5.6 installation script of HDsamba2 in order to do it. One big error concerned the '_safemount' function that is found in more than one script. It contains an obvious mistake in variables used to test and mount a partition. I wonder how many people actually can make it work with the original versions of these scripts.

Also, I wonder if the results of various queries that are done on the USB-drive depend on the brand/make of the USB drive. In my case I use an WD Elements drive of 2 TB. For instance, the HDsamba scripts test on the existence of the line "GUID" in the attributes of the reported attached drive. Instead of GUID I got a line with "Serial Number". Same info, but in a script that tests on GUID, that a reason to fail. Another example, the mount script that is executed when the router boots waits for the drive to report that it is active. Well, the WD Elements doesn't report this attribute.

If people recognize these, and other, problems and would like to get it working, then please respond to this thread and I will try to help you out. In the mean time, I'm contemplating on installing Tomato firmware with Samba support out of the box :-)

Cheers,
Ed

Bert Becker
Bert Becker's picture
Hi Ed!

Hi Ed!

I got the same problem with the installation script v5install.HDsamba2.

I have the WRT610n router with dd-wrt v24-sp2 and try to get an attached HDD working with samba. I have a little experience and could track the problem to the same point, that the script is looking for the GUID line, but, as you, I have instead a "Serial Number" line.
I also had the problem that I was for some reason unable to relocate the /jffs partition, but now I think this could also be because of this same bug. I manually mounted /jffs to /dev/discs/disc0/part4 and now don't need to relocate at all.

The partitions are setup according to plan. I can mount the partitions manually without problems.

Maybe you could give me a hint, how to patch the script? I tried a little myself by changing 'GUID' into 'Serial Number' but my scripting knowledge is definatly not enough for that.

Your posting made me hope, that this is indeed not my fault and it could be done. Would appreciate any help, maybe your custom script?

THX & Greetings from Germany
Bert

Ed Hut
Ed Hut's picture
Hi Bert,

Hi Bert,

I can email you the script that I finally ended up with after a lot of trial and error. I cannot guarantee the correct working on your combo of router and harddisk, but it may be a better start for you to tweak on with. BTW, I have used a Western Digital Elements harddisk.

Cheers,
Ed

liriel
liriel's picture
Hi Ed,

Hi Ed,

I have exactly the same hard drive as you and have encountered the same problem. Would you mind emailing me the script you used? My address is imsnos at yahoo dot com.

Cheers,
Jason

MoxZ
MoxZ's picture
Hi, ED

Hi, ED
I would also like to have your script I have the same router as you and I can't get things working.

Best Regards from Mr.MoxZ
moxz at yakumo dot se.

Kong
Kong's picture
There is no need anymore to

There is no need anymore to install samba through optware, in the download section you'll find a dd-wrt firmware with included samba.Once you installed it you'll find a new section under Services->NAS

liriel
liriel's picture
Thanks Kong. I have actually

Thanks Kong. I have actually been using your version of dd-wrt for the last week or so. Works great!

Kris O
Kris O's picture
I'm having the same issue

I'm having the same issue with a WRT610n and a WD Elements 2TB drive.

Any chance you can post or email the script to me? (Or otherwise hint at what I might need to change in the script).

My email is:

script [at] olhovsky [dot] com

Ed Hut
Ed Hut's picture
Kris O said: I'm having the

Kris O said: I'm having the same issue with a WRT610n and a WD Elements 2TB drive. Any chance you can post or email the script to me? (Or otherwise hint at what I might need to change in the script). My email is: script [at] olhovsky [dot] com

Hi Kris,

I've emailed you just a moment ago.

Cheers,

Ed