HDsamba Version 3 Available

Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC based Hardware
Goto page 1, 2, 3 ... 33, 34, 35  Next
Author Message
Amorphis
DD-WRT User


Joined: 08 Jan 2009
Posts: 234
Location: Toronto, Ontario

PostPosted: Sat Jan 31, 2009 3:06    Post subject: HDsamba Version 3 Available Reply with quote
There are some revisions to the install process, if you're already a HDsamba2 veteran please take a look at the revised install code.

MEGA Builds:
$ cd /tmp
$ wget http://www.3iii.dk/linux/optware/v3install.HDsamba2
$ sh /tmp/v3install.HDsamba2

MINI USB Builds: (With updated scripts)
$ cd /tmp
$ wget http://www.3iii.dk/linux/optware/v3install.HDsamba2
$ sh /tmp/v3install.HDsamba2 -mini

HDsamba2 in the wiki:
http://www.dd-wrt.com/wiki/index.php/HDsamba2

Read below before you install.

(Note I've changed the recommended JFFS size to 400kb of FREE SPACE)

_________________
WRT350N Eko Mega 11296 + HDsamba2 v4 beta


Last edited by Amorphis on Sat Jan 31, 2009 21:09; edited 6 times in total
Sponsor
Amorphis
DD-WRT User


Joined: 08 Jan 2009
Posts: 234
Location: Toronto, Ontario

PostPosted: Sat Jan 31, 2009 3:07    Post subject: Reply with quote
HDsamba2 v3.00
--------------

Important Note: (Thanks to Atmi)
There is an issue with the reboot button in the GUI. This issue affects HDsamba, and all other
script based methods of unmounting usb devices. Testing has shown, the reboot button in web gui
DOES NOT RUN THE SHUTDOWN SCRIPT. Soft reboots, made after changing and savings settings does
cleanly unmount the drive... but the reboot button under admin, DOES NOT UNMOUNT THE DRIVE.

At this time, I'm suggesting people use putty to reboot the router with the "reboot" command.
This will call the unmount script naturally.

Better still, configure the SESbutton, and simply unmount your HD manually before you reboot.

A bug has been listed in the tracker, and I hope this minor change can be made to avoid confusion
for those wanting a simple usb storage solution.


Background
----------

The Goal:

A quick, painless method of installing and setting up NAS on a broadcom router.
The scripts are designed to be intelligent in the sense that they can detect
bad gui settings, improperly partitioned disks, errors on disks, unmount problems,
processes that fail to execute or terminate, and other unexpected failures.

The golden rule with HDsamba, is that every command issued has atleast one verification
stage. If something fails, the log files should contain everything you need to identify
the problem.

HDsamba2
-Installs e2fsprogs and swap-utils to /jffs to address disk integrity and memory swap
-Installs Optware to /opt
-Installs Samba2 with an initial configuration file that works out of the box
-Installs xinetd to provide SWAT for Samba and works out of the box
-Mounts your Optware partition for you
-Mounts your Swap partition for you
-Mounts your NAS partition for you
-Allows you to configure the Router (ez)sesbutton to unmount the disk drive on press
*AND IF SOMETHING GOES WRONG, HDSAMBA2 WILL TELL YOU WHAT HAPPENED*


Quick Start Guide:
------------------


** IMPORTANT **
HDsamba Prerequisites

A) First, make your life easy and install firmware that already has USB support...
http://www.dd-wrt.com/dd-wrtv3/dd-wrt/downloads.html"
Try under / others / eko / V24_TNG /

This version of HDsamba2 was tested with Eko's 11218 and later MEGA builds.
They work. Keep in mind you will need 750kb of JFFS to run some utilities,
so this may influence which build you choose.

B) Please make sure your Hard Drive is partitioned as follows:
/part1 - ext3 (Optware and extra software...)
/part2 - linux swap (Swap partition for the router)
/part3 - ext3 (NAS data, this is the space that Samba will share)

I used a knoppix live cd to partition mine.
I was generous and provided 256mb to /part1 & /part2
I like cats.

C) Now, please spend time configuring the web GUI.."
Point your browser to 192.168.1.1, or whatever your router's IP is...

Set a Time Server:
This helps stop e2fsck from running disc checks when there is no reason.
It may seem like a small detail, but it's important!
*Set a Time Server* (The install script will detect if you are lazy...)
http://www.pool.ntp.org/ can help

Configure JFFS support:
We need a small JFFS to run disc checks from, as repairs are best run on unmounted
disks. Again you probably want around 750kb in your total JFFS size, including file system.

Under Services/USB in the GUI, enable the following:
Core USB Support
USB Storage Support
USB 2.0 (or the version your HD supports)
ext2/ext3 Support

THERE IS NO NEED TO SPECIFY AN AUTOMOUNT, OR STARTUP SCRIPTS
REMEMBER IF WE'RE GOING TO CHECK DRIVES FOR INTEGRITY, IT'S
BETTER TO DO SO ON AN UNMOUNTED DRIVE!

HDsamba2 will also automatically configure your shutdown script
to unmount cleanly on reboot (and thus save your HD wear and tear...)

Ok, that's it. You have met all the prerequisites.
Time to install.

Putty into your router. Connect your Hard Disk. No need to mount it manually, let the script do it.
(REVISED) At the prompt run:
$ cd /tmp
$ wget http://www.3iii.dk/linux/optware/v3install.HDsamba2
$ sh /tmp/v3install.HDsamba2


IMPORTANT NOTE: if you're using a MINI BUILD or a build without open-wrt
libraries you will get errors!
Run the install script this way, to include necessary libraries:
(REVISED) $ sh /tmp/v3install.HDsamba2 -mini
NOTE THAT THIS WILL CONFIGURE THE OPEN-WRT WRAPPER TO INCLUDE SOME LIBRARIES BUT FUNCTIONALITY
ISN'T COMPLETE YET!!! STILL IN DEVELOPMENT!


From there, HDsamba will take over.
Follow some basic instructions, answer some questions, and enjoy your NAS.


***NOTES ON SES BUTTON FUNCTION***

If you enable this feature, press and hold the button for a couple of seconds.
Your Hardrive LED should flicker.
Release button and wait (no more than 30 seconds)
Unplug HD safely.
There is no feedback feature implemented at this time, sorry.
If you don't trust it, putty in and run a mount command the first couple of times you try it.
IT *WILL* UNMOUNT THE DRIVE, you just need to give it 30 seconds max (see below as to why...)

To remount your drive you have 2 options:
1) Plug it back in, reboot your router. Or alternatively, reboot your router, plug drive in later.
2) Plug it back in, and press the SES button a SECOND TIME, hold briefly. This will remount
the drive and restart Samba.


Troubleshooting:
------------------

*** Note: The issue with firewall logging seems to have been resolved in version 3.


The Install Process:
If you encounter problems with installation you can view a summary of the installation:
$ cat /tmp/HDsamba_install.log

If at any other time you experience problems, you have 3 sets of HDsamba logs to take a look at:
/tmp/HDsamba/*.log (These will always be the most recent)
/mnt/HDsamba/logs/*.log (These are copied from /tmp in the event of a successful init.startup)
/mnt/data/Logs (These are copied from /tmp when Samba is started)


The log files are your friend, if you're having problems, post the log files, this is HDsamba2 telling you
what went wrong.
Log files created by HDsamba2:
install.log - Record of your original installation of HDsamba2.
summary.log - Overview of the HDsamba2 process, check here first for problems.
boot.log - Output of init.startup, how did the system startup, is the disk ok?
mount.log - Output of mount.usb, any problems with the NAS, or samba daemons?
disk_health.log - Health report on your HD
disk_health_forced.log - Created when there are critical problems with your HD, refer to date stamp.
shutdown.log - Created whenever the unmount scripts run, did everything shutdown ok?


Details:
------------------
HDsamba2 is initialized on startup from files stored in /jffs/etc/config:

init.startup executes first
Task 1: checks for /jffs and waits 30 seconds or until it appears
Task 2: checks for a time sever and waits 30 seconds or until it appears
Task 3: waits for HD to be plugged in, if it isn't already, infinite wait
Task 4: mounts the swap partition
Task 5: runs a check on paritions 1 and 3, may take time if there are problems
Task 6: mounts partion 1 to /mnt
Passes execution to /mnt/HDsamba/scripts/mount.usb

**NOTE: If you partition your HD with a Linux boot CD that doesn't use a time server it is likely
your HD will read it was created in 1970... e2fsck will force a check of a disk created
this far in the past, as a result EXPECT DELAYS ON YOUR FIRST BOOT OF HDSAMBA2.

**NOTE: Checking your disk, is an awesome good thing, and keeps stuff safe. Just my way of trying to
fight some bad perceptions of waiting for a diskcheck to finish on a large NAS volume Smile

mount.usb executes next
Task 1: mounts the /mnt/opt to /opt to allow optware to function
Task 2: mounts the NAS partition (partition 3) to /mnt/data
Task 3: starts Samba, waits for it to start, or 30 seconds whatever happens first
Task 4: starts Proftp, waits for it to start, or 30 seconds whatever happens first
*This only occurs if ProFTP is enabled in the web GUI*
Finally, it copies all log files for easy viewing



Other Utilities:

/mnt/HDsamba/scripts/network.usb
Simple question based method of quickly setting up smb.conf and swat config
Stores a backup of your config
Now also does the same for swat config, using the subnet your specify to
restrict access.
Requires a reboot when completed, or a manual restart of HDsamba2.

/mnt/HDsamba/scripts/jffs.repair
Returns files to /jffs in the event of a /jffs wipe or firmware upgrade
NOTE: can be run as /mnt/HDsamba/scripts/jffs.repair -mini
This enables library support on smaller builds that don't support open-wrt
(As above this is still in development, partly functional)

This script will:
-install e2fsprogs to jffs
-install swap-utils to jffs
-configure the open-wrt wrapper
-install the HDsamba2 startup scripts

It also configures the SESbutton.


/mnt/HDsamba/scripts/unmount.sesbutton
Allows the sesbutton to mount and unmount your Hard drive.
The install script copies this file to /jffs/etc/config/ to enable this feature
You can copy this file yourself to enable it.
You can also rm /jffs/etc/config/unmount.sesbutton to deactivate this feature


/mnt/HDsamba/scripts/forcecheck.usb
Simulates a bad shutdown... the advantage to this, is if you want to force
a full disk check on your partitions, running this will force such a check on
your next boot. Good for the data paranoid, like me...


The unmount scripts work this way:
1. Kills samba processes
- gives them up to 30 seconds to report a clean termination
- usually this is immediate unless there is a problem

2. Turns off the Swap Partition
- gives it up to 30 seconds to report a clean stop
- usually this is immediate unless there is a problem

3. Turns off ProFTP
- gives it up to 30 seconds to report a clean stop
- usually this is immediate unless there is a problem

4. Saves permanent logs to /mnt/HDsamba/logs
I want to avoid writing to /jffs as much as possible so the rest of the script is not logged

5. Attempts to unmount the HDs in 'normal' mode. Gives 15 seconds for this to happen.
This usually completes in 5 - 10 seconds. This will shut down the drives 90% of the time.

6. Check if the HD is still mounted. If so, try unmounting again in 'lazy' unmount mode.
99.9999% of the time this solves any lingering HD reads/writes, and shuts the drive down
cleanly. The script provides another 15 seconds to complete this process, or as much of that time
that is needed.

7. Last check, are the drives still mounted? I have never encountered this problem to date but
I admit it's a possibillity due to other processes or unforseen modifications.
Just in case, a small file bad_shutdown.flag is saved to /jffs to tell HDsamba2 on it's next
start that the drives didn't shut down properly, and that it should check the disks aggressively.

Update: If you're running transmission or other daemons on the optware partition, you need to include
code to terminate these daemons to free up the disk for the unmount process. Users in this scenario
should be aware they may get bad_shutdown.flag repeatedly. Refer to the section below.

8. Script is finished.


Advanced:
------------------
There are two other scripts installed with HDsamba2 that are not documented anywhere else:
daemon.kill
daemon.load

You can find these scripts at /mnt/HDsamba/scripts.

These are for advanced users, who want to load other optware daemons, and want to control how they are integrated
into the HDsamba2 system. This is also an ideal place to load other openwrt packages from JFFS if you so choose.

There is no automation of these files- their contents and configuration is totally up to you.
I have included an example of Atmi's code for the Transmission daemon here.

These scripts are already called by the HDsamba2 startup and shutdown scripts, and as such are your perfect
customization point for daemon control.

Remember, for every daemon you start in daemon.load, you should have a corresponding kill command in daemon.kill
to create your best chance for a clean unmount each and every time.

It's not for all of us, but it does give the more advanced users out there the opportunity to customize their
HDsamba2 setup.


Bug reports, issues, reports of success and failure on various builds are always welcome.
Suggestions are most welcome.

Enjoy,
Amorphis

_________________
WRT350N Eko Mega 11296 + HDsamba2 v4 beta
Amorphis
DD-WRT User


Joined: 08 Jan 2009
Posts: 234
Location: Toronto, Ontario

PostPosted: Sat Jan 31, 2009 3:07    Post subject: Reply with quote
Changes to HDsamba2 in Version 3.00
(There are quite a few this time around)
----------------------------------------


Global
-----------------
1) Cleaned up scripts, ALOT...
2) Removed all references to dmesg- firewall logging should no longer be a problem
3) Added summary.log for quick analysis of boot and mount issues
4) Added install.log (/tmp/HDsamba_install.log) for install troubleshooting


Install Script v3
-----------------
1) Avoid use of dmesg at all times, do checking using contents of /dev/discs/disc0/
2) Corrected Verification of /opt mount, will terminate the script on a fail
3) Corrected smb.conf backup procedure
-smb.last (last version before you try to install HDsamba2)
-smb.orig (optware original version of the config)
4) Added swat backup procedure
-swat.last (last version before you try to install HDsamba2)
-swat.orig (optware original version of the config)
5) Added Mr. Alvin's Routine to check the size of JFFS, changed my recommended size to 400kb of free space...
6) Changed script to run from /tmp, with a manual call to unmount the drive after install.
Hopefully this will improve the cleanliness of the shutdown on other routers
(although it worked as is on my own...)
7) Added an installation summary log at /tmp/HDsamba_install.log view it's contents to determine what went wrong
Cool Added capacity to copy the HDsamba_install.log to your main log directories, becomes install.log


network.usb v3
-----------------
1) Corrected smb.conf backup procedure
-smb.recent (most recent last version of the config, before you ran this utility)
2) Added swat backup procedure
-swat.recent (most recent last version of the config, before you ran this utility)
3) Configured the script to output a version of swat config, using the subnet specified
4) Addressed a security flaw in the default smb.conf that was allowing outside access.
Now subnet only by default.
5) Corrected Samba Log file error, should stop errors from filling up log.


jffs.repair v3
-----------------
1) Avoid use of dmesg at all times, do checking using contents of /dev/discs/disc0/
2) Avoid automatic reboot at the end of the script, make the user to it manually,
and avoid any potential disk problems. If you are running jffs.repair, you would know how to do this.


disk_health.usb
-----------------
1) Added verbose mode to all checks, more details for the impatient among us who wait for a check to finish
2) Created a seperate log:
disk_health_forced.log - HDsamba2 will occasionally force a recheck of the disks, if it detects errors
- If a e2fsck in -p mode finds errors, it is rechecked as e2fsck -fy
- This is only done in rare cases where errors have been found, so check the date


init.startup
-----------------
1) Avoid use of dmesg at all times, do checking using contents of /dev/discs/disc0/
2) If the router fails to load the swap file, the script will stop. You will just keep encountering problems.
-If you run into this problem, I suggest a manual mount of /mnt and running /mnt/HDsamba/scripts/jffs.repair
3) Added a extra step to disable SES button during initialization process, could screw things up big time if
you allow the button to be pressed during mount
4) Added extra time for the HD to stabilize on a reboot, but not on a sesbutton press.


mount.usb
------------------
1) Avoid use of dmesg at all times, do checking using contents of /dev/discs/disc0/
2) Intensive checking of optware directories and services, return a script failure on any error or missing file.


unmount.sesbutton
-------------------
1) Optimized some code, more thorough checks, some optimizations on button routines


unmount.usb
-------------------
1) Optimized some code, more thorough checks, clears button pressed flag as a "just in case" scenario


forcecheck.usb
-------------------
1) New utility, fakes a bad shutdown to force a full disk check on your next boot- for the data paranoid among us.


daemon.load
daemon.kill
-------------------
1) Two new scripts, that are meant to be edited by you!
They are designed to load and kill optware daemons that you choose, with the HDsamba2 verification checks.
Atmi's code for Transmission is included as an example... this is an advanced user configurable element of HDsamba2
that's not for everyone, but gives some flexibillity for advanced users, who don't want to skim through all my code.

_________________
WRT350N Eko Mega 11296 + HDsamba2 v4 beta


Last edited by Amorphis on Sat Jan 31, 2009 3:17; edited 1 time in total
Amorphis
DD-WRT User


Joined: 08 Jan 2009
Posts: 234
Location: Toronto, Ontario

PostPosted: Sat Jan 31, 2009 3:11    Post subject: Reply with quote
In case you missed it:

http://www.3iii.dk/linux/optware/v3install.HDsamba2

_________________
WRT350N Eko Mega 11296 + HDsamba2 v4 beta
Shadco
DD-WRT User


Joined: 29 Dec 2008
Posts: 214
Location: Lower Brackley on the Chesapeake

PostPosted: Sat Jan 31, 2009 3:39    Post subject: Reply with quote
Sweet

So I should try turning logging back on right?

root@WRT-350N:/tmp/HDsamba# cat summary.log |more
HDsamba2 v3.00
Start Summary Log
JFFS was detected!
Fri Jan 30 22:37:25 UTC 2009
Valid time server was detected!
Detected USB Storage Device!
Detected Partition1, Partition2 and Partition3!
Detected successful mount of Partition 2 (Swap) as memory swap!
Detected clean file systems!
Detected successful mount of Partition 1 (Optware) to /mnt!
Detected Optware!
Detected successful mount of Partition 1 (Optware) to /opt!
Detected successful mount of Partition 3 (NAS) to /mnt/data!
Detected successful start of Samba daemons!
**USB drive is now functioning as NAS**
Fri Jan 30 22:37:39 UTC 2009
Summary Logfile Complete
root@WRT-350N:/tmp/HDsamba#

_________________
Shad
-----
Linksys WRT600Nv1.1 v24-sp2 11667 BS std
Linksys WRT350Nv1 11650M NEWD Eko std
Linksys WRT300Nv1 11650M NEWD Eko std
Netgear WNR834bv2 v24-sp2 build 11667 BS mini
Linksys NSLU2 Unslung
Shadco
DD-WRT User


Joined: 29 Dec 2008
Posts: 214
Location: Lower Brackley on the Chesapeake

PostPosted: Sat Jan 31, 2009 3:49    Post subject: Reply with quote
oppss on the firewall logging

Fri Jan 30 22:36:04 UTC 2009
Installtion Logfile Complete
root@WRT-350N:/mnt/data/Logs# dmesg
OUT=vlan2 SRC=192.168.1.4 DST=66.102.1.157 LEN=52 TOS=0x00 PREC=0x00 TTL=63 ID=15104 DF PROTO=TCP SPT=56290 DPT=80 SEQ=1671594660 ACK=1979352302 WINDOW=65535 RES=0x00 ACK FIN URGP=0 OPT (0101080A0D9FDB6AA79ACEF5)
ACCEPT IN=br0 OUT=vlan2 SRC=192.168.1.4 DST=66.102.1.157 LEN=64 TOS=0x00 PREC=0x00 TTL=63 ID=45657 DF PROTO=TCP SPT=56499 DPT=80 SEQ=3686357098 ACK=0 WINDOW=65535 RES=0x00 SYN URGP=0 OPT (020405B4010303030101080A0D9FDB6A0000000004020000)
ACCEPT IN=br0 OUT=vlan2 SRC=192.168.1.4 DST=83.141.4.210 LEN=64 TOS=0x00 PREC=0x00 TTL=63 ID=22064 DF PROTO=TCP SPT=56500 DPT=80 SEQ=1770008918 ACK=0 WINDOW=65535 RES=0x00 SYN URGP=0 OPT (020405B4010303030101080A0D9FDB6A0000000004020000)
ACCEPT IN=br0 O

_________________
Shad
-----
Linksys WRT600Nv1.1 v24-sp2 11667 BS std
Linksys WRT350Nv1 11650M NEWD Eko std
Linksys WRT300Nv1 11650M NEWD Eko std
Netgear WNR834bv2 v24-sp2 build 11667 BS mini
Linksys NSLU2 Unslung
Amorphis
DD-WRT User


Joined: 08 Jan 2009
Posts: 234
Location: Toronto, Ontario

PostPosted: Sat Jan 31, 2009 3:55    Post subject: Reply with quote
That's normal for logging I'm told.
It won't affect your mount as hdsamba nolonger needs dmesg.

_________________
WRT350N Eko Mega 11296 + HDsamba2 v4 beta
Shadco
DD-WRT User


Joined: 29 Dec 2008
Posts: 214
Location: Lower Brackley on the Chesapeake

PostPosted: Sat Jan 31, 2009 4:16    Post subject: Reply with quote
Amorphis wrote:
That's normal for logging I'm told.
It won't affect your mount as hdsamba nolonger needs dmesg.


Install was silky smooth and fast.

Pretty work

_________________
Shad
-----
Linksys WRT600Nv1.1 v24-sp2 11667 BS std
Linksys WRT350Nv1 11650M NEWD Eko std
Linksys WRT300Nv1 11650M NEWD Eko std
Netgear WNR834bv2 v24-sp2 build 11667 BS mini
Linksys NSLU2 Unslung
AtMi
DD-WRT User


Joined: 04 Jan 2009
Posts: 90
Location: Vilnius, Lithuania

PostPosted: Sat Jan 31, 2009 8:32    Post subject: Reply with quote
Amorphis,
You are fast, about two weeks and new version Shocked Thanks MAN, I will try on my mini.

_________________
WRT600N V1.1 - 12672_mega_WRT610N
AtMi
DD-WRT User


Joined: 04 Jan 2009
Posts: 90
Location: Vilnius, Lithuania

PostPosted: Sat Jan 31, 2009 8:54    Post subject: Re: HDsamba Version 3 Available Reply with quote
Amorphis wrote:
MINI USB Builds:
$ cd /tmp
$ wget http://www.3iii.dk/linux/optware/v3install.HDsamba2 -mini
$ sh /tmp/v3install.HDsamba2

I got Sad :
PuTTY wrote:

Using username "root".
DD-WRT v24 mini (c) 2008 NewMedia-NET GmbH
Release: 01/21/09 (SVN revision: 11487)
==========================================================

____ ___ __ ______ _____ ____ _ _
| _ \| _ \ \ \ / / _ \_ _| __ _|___ \| || |
|| | || ||____\ \ /\ / /| |_) || | \ \ / / __) | || |_
||_| ||_||_____\ V V / | _ < | | \ V / / __/|__ _|
|___/|___/ \_/\_/ |_| \_\|_| \_/ |_____| |_|

DD-WRT v24-sp2
http://www.dd-wrt.com

==========================================================


BusyBox v1.13.2 (2009-01-21 02:48:56 CET) built-in shell (ash)
Enter 'help' for a list of built-in commands.

root@SAUGYKLA:~# cd /tmp
root@SAUGYKLA:/tmp# wget http://www.3iii.dk/linux/optware/v3install.HDsamba2 -mini
wget: illegal option -- m
root@SAUGYKLA:/tmp#

_________________
WRT600N V1.1 - 12672_mega_WRT610N
AtMi
DD-WRT User


Joined: 04 Jan 2009
Posts: 90
Location: Vilnius, Lithuania

PostPosted: Sat Jan 31, 2009 9:03    Post subject: Re: HDsamba Version 3 Available Reply with quote
Amorphis Exclamation,
For mini must be Code:
MINI USB Builds:
$ cd /tmp
$ wget http://www.3iii.dk/linux/optware/v3install.HDsamba2
$ sh /tmp/v3install.HDsamba2 -mini

PuTTY wrote:

Using username "root".
DD-WRT v24 mini (c) 2008 NewMedia-NET GmbH
Release: 01/21/09 (SVN revision: 11487)
==========================================================

____ ___ __ ______ _____ ____ _ _
| _ \| _ \ \ \ / / _ \_ _| __ _|___ \| || |
|| | || ||____\ \ /\ / /| |_) || | \ \ / / __) | || |_
||_| ||_||_____\ V V / | _ < | | \ V / / __/|__ _|
|___/|___/ \_/\_/ |_| \_\|_| \_/ |_____| |_|

DD-WRT v24-sp2
http://www.dd-wrt.com

==========================================================


BusyBox v1.13.2 (2009-01-21 02:48:56 CET) built-in shell (ash)
Enter 'help' for a list of built-in commands.

root@SAUGYKLA:~# cd /tmp
root@SAUGYKLA:/tmp# wget http://www.3iii.dk/linux/optware/v3install.HDsamba2 -mini
wget: illegal option -- m
root@SAUGYKLA:/tmp# wget http://www.3iii.dk/linux/optware/v3install.HDsamba2-mini
Connecting to www.3iii.dk (195.47.247.102:80)
root@SAUGYKLA:/tmp# sh /tmp/v3install.HDsamba2
sh: can't open /tmp/v3install.HDsamba2
root@SAUGYKLA:/tmp# sh /tmp/v3install.HDsamba2
sh: can't open /tmp/v3install.HDsamba2
root@SAUGYKLA:/tmp# wget http://www.3iii.dk/linux/optware/v3install.HDsamba2
Connecting to www.3iii.dk (195.47.247.102:80)
v3install.HDsamba2 100% |*************************************| 27096 --:--:-- ETA
root@SAUGYKLA:/tmp# sh /tmp/v3install.HDsamba2 -mini
Welcome to HDsamba v3.00
---------------------------------------------------------
Confirm Hard Drive Partitions....
---------------------------------------------------------
.
First, please make sure your Hard Drive is partitioned as follows:
/part1 - ext3 (Optware and extra router software...)
/part2 - linux swap (Swap partition for the router)
/part3 - ext3 (NAS data, this is the space that Samaba will share)
.
Optware and Swap size is up to you, I was generous and
provided 256 mb to each for my WRT350N.
.
---------------------------------------------------------
If your hard drive meets these requirements, press ENTER

_________________
WRT600N V1.1 - 12672_mega_WRT610N
AtMi
DD-WRT User


Joined: 04 Jan 2009
Posts: 90
Location: Vilnius, Lithuania

PostPosted: Sat Jan 31, 2009 9:19    Post subject: Reply with quote
At the end of install I got this error:
Quote:
Press ENTER to confirm...

Network Config Finished - You need to restart samba and xinetd for settings to take effect...
A reboot is suggested.
.
.
Press ENTER to reboot your router...

.
Shutting down daemons and swap...
/jffs/usr/sbin/swapoff: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
Unmounting USB drive...
Successfully unmounted USB drive

After reboot my summary.log:
Quote:
HDsamba2 v3.00
Start Summary Log
JFFS was detected!
Sat Jan 31 11:14:26 UTC 2009
Valid time server was detected!
Detected USB Storage Device!
Detected Partition1, Partition2 and Partition3!
ERROR: View boot.log
and boot.log:
Quote:
Sat Jan 31 11:14:26 UTC 2009
Initialization Script - HDsamba2 v3.00
---------------------------------------------------------
Router is booting....
---------------------------------------------------------
.
TASK 1: Waiting for Router to mount /jffs
-rw-r--r-- 1 root root 126 Jan 1 1970 dnsmasq.leases
drwxr-xr-x 1 root root 0 Jan 31 11:04 etc
drwxr-xr-x 1 root root 0 Jan 31 11:05 sbin
drwxr-xr-x 1 root root 0 Jan 1 1970 tmp
drwxr-xr-x 1 root root 0 Jan 31 11:06 usr
Router has mounted /jffs!
TASK 1: Done
---------------------------------------------------------
.
TASK 2: Waiting for Router to register a useable date...
Sat Jan 31 11:14:26 UTC 2009
Router is connected to a valid time server!
TASK 2: Done
---------------------------------------------------------
.
TASK 3: Waiting for Router to discover a USB Disk...
USB Storage Device Detected....
brw------- 1 root root 8, 0 Jan 1 1970 disc
brw------- 1 root root 8, 1 Jan 1 1970 part1
brw------- 1 root root 8, 2 Jan 1 1970 part2
brw------- 1 root root 8, 3 Jan 1 1970 part3
Looking for correct partitions....
VERIFIED: part1, part2, part3
WAITING: 10 seconds for HD stability...
Host scsi0: usb-storage
Vendor: JMicron
Product: USB to ATA/ATAPI Bridge
Serial Number: D57CA3522686
Protocol: Transparent SCSI
Transport: Bulk
GUID: 152d23380000d57ca3522686
Attached: Yes
TASK 3: Done
---------------------------------------------------------
.
TASK 4: Waiting for Router to mount swap partition...
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
/jffs/usr/sbin/swapon: can't resolve symbol 'setlocale'
ERROR: Router has failed to mount swap.
TERMINATING SCRIPT IMMEDIATELY
total used free shared buffers
Mem: 29236 12712 16524 0 1388
Swap: 0 0 0
Total: 29236 12712 16524
rootfs on / type rootfs (rw)
/dev/root on / type squashfs (ro)
none on /dev type devfs (rw)
proc on /proc type proc (rw)
ramfs on /tmp type ramfs (rw)
/dev/mtdblock/4 on /jffs type jffs2 (rw)

_________________
WRT600N V1.1 - 12672_mega_WRT610N
AtMi
DD-WRT User


Joined: 04 Jan 2009
Posts: 90
Location: Vilnius, Lithuania

PostPosted: Sat Jan 31, 2009 9:28    Post subject: Reply with quote
It is mistake in writing to "openwrt-run.sh". This script is writen like for mega build:
Quote:
#!/bin/sh
#HDsamba2 V3.00 Open-WRT wrap script, for compatibillity only
#By Amorphis
#January 2009

$1 $2 $3 $4 $5 $6

#Done

_________________
WRT600N V1.1 - 12672_mega_WRT610N
AtMi
DD-WRT User


Joined: 04 Jan 2009
Posts: 90
Location: Vilnius, Lithuania

PostPosted: Sat Jan 31, 2009 9:58    Post subject: Reply with quote
Can't run /mnt/HDsamba/scripts/jffs.repair -mini

Quote:
root@SAUGYKLA:~# mount
rootfs on / type rootfs (rw)
/dev/root on / type squashfs (ro)
none on /dev type devfs (rw)
proc on /proc type proc (rw)
ramfs on /tmp type ramfs (rw)
/dev/mtdblock/4 on /jffs type jffs2 (rw)
/dev/discs/disc0/part1 on /mnt type ext3 (rw)
root@SAUGYKLA:~# /mnt/HDsamba/scripts/jffs.repair -mini
-sh: /mnt/HDsamba/scripts/jffs.repair: Permission denied
root@SAUGYKLA:~#

jffs.repair is writen with 0644 permissions, I changet to 0777 and nothing - Permission denied

_________________
WRT600N V1.1 - 12672_mega_WRT610N
MrAlvin
DD-WRT User


Joined: 07 Jan 2007
Posts: 453
Location: Denmark

PostPosted: Sat Jan 31, 2009 12:28    Post subject: Reply with quote
AtMi wrote:
/mnt/HDsamba/scripts/jffs.repair -mini

Might be a case of extensions, not shure, but try:
sh /mnt/HDsamba/scripts/jffs.repair -mini
I think you will get better results then.
Goto page 1, 2, 3 ... 33, 34, 35  Next Display posts from previous:    Page 1 of 35
Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum