DSM-G600, DNS-3xx and NSA-220 Hack Forum

Unfortunately no one can be told what fun_plug is - you have to see it for yourself.

You are not logged in.

Announcement

#51 2008-07-22 16:04:19

knireis
Member
Registered: 2007-12-10
Posts: 231

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

silversurfer wrote:

I can at least say that it is not because of the firmware or funplug.

I have a CH3SNAS myself with firmware 1.04RC4 and funplug 1.05. That's the same as knireis' system.

If you like you can try my cleanboot installation. I attached it to this post. Copy the cleanboot-2.0.5-ffp05.tar to your /ffp directory and then do:

"cd /ffp"
"tar -xvf cleanboot-2.0.5-ffp05.tar"

This will unpack the files to their respective directories ( etc, share and start ).

Please keep in mind that I don't have to use the "rm -r sbin" but instead use only "rm sbin" in my script.

Thanks, but it does not work, i tried both with the rm -r sbin and the rm sbin. But cleanboot is running according the status request

root@CH3SNAS:~# cd /ffp/start
root@CH3SNAS:/mnt/usb/ffp/start# sh cleanboot.sh status
cleanboot running
root@CH3SNAS:/mnt/usb/ffp/start# reboot
root@CH3SNAS:/mnt/usb/ffp/start# do_reboot
root@CH3SNAS:/mnt/usb/ffp/start# cd
root@CH3SNAS:~# reboot
root@CH3SNAS:~#

Offline

 

#52 2008-07-22 19:50:42

silversurfer
Member
Registered: 2008-07-20
Posts: 95

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Did you test all the commands of the setup section manually?

Code:

cd /usr
rm -r sbin
mkdir /usr/sbin
ln -s /sys/crfs/sbin/* /usr/sbin
rm /usr/sbin/do_reboot 2>/dev/null
rm /sbin/reboot 2>/dev/null
rm /sbin/shutdown 2>/dev/null
rm /sbin/halt 2>/dev/null
rm /ffp/sbin/reboot 2>/dev/null
rm /ffp/sbin/halt 2>/dev/null
rm /ffp/sbin/shutdown 2>/dev/null
chmod 0755 /ffp/share/cleanboot/*
cp /ffp/share/cleanboot/do_reboot.pof /usr/sbin/do_reboot
cp /ffp/share/cleanboot/cleanboot.sh /sbin/cleanboot.sh
ln -s /usr/sbin/do_reboot /sbin/shutdown
ln -s /usr/sbin/do_reboot /sbin/halt
ln -s /usr/sbin/do_reboot /sbin/reboot

This would help to identify where the script fails to setup the correct link between "/sbin/reboot" and "/usr/sbin/do_reboot".

Offline

 

#53 2008-08-15 03:56:32

Jimmie
New member
Registered: 2008-08-15
Posts: 4

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Sorry to bump...

But, cleanboot seems to be working fine on the reboots.

However when I issue a shutdown, it just reboots as if it's a reboot.

I vi'd the cleanboot.sh (in share) and there's something like if $1 = shutdown then blabla
Now curious as I am I entered those 2 commands and bam my NAS was off (oopsy smile)


Running a CH3SNAS (1.04RC5 + FFP0.5 with cleanboot 2.0 (with slightly edited start/cleanboot.sh as shown here, so the start script works)


My Linux knowledge is way too small to fully understand the script and why it fails to recognize the shutdown order (it does the same on halt). Anyone an idea?

Offline

 

#54 2008-08-18 16:25:49

snap
New member
Registered: 2008-08-18
Posts: 2

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

hello forum members,
after lurking around here for 2 months decided to join in and this is my first post

I have setup a cron job to do a system shutdown daily and was trying to use this cleanboot script to do a clean shutdown.

Now I have FW 1.05, ffp 0.5 on USB and the cleanboot package for ffp0.5 from the first post, but i still get file system check warnings in dmesg.
thought cleanboot works fine when I issue a shutdown command from telnet, the cron job initiated shutdown fails unmount disks before a shutdown.

Code:

crontab -l
0 9 * * * /sbin/shutdown

digging into the /ffp/share/cleanboot/cleanboot.sh script there were a few problems

1. the "export PATH....." line needs to be uncommented else the command further down for shutting down the fun_plug installed packages fails (rcorder cannot be found)"
2. the staggeted kill command uses "xarg", it should be "xargs"
3. And the kill command for killings processes listed in cleanboot.conf could first check if process exists before trying to kill it
   

Code:

    for p in $PROCS ; do
        p_id=`pidof $p`
        if [ -n "$p_id" ]; then
                kill $p_id
        fi
    done

All this seems to have fixed my problem. hope this helps others.

Offline

 

#55 2008-08-18 16:54:37

timschuerewegen
Member
Registered: 2008-08-05
Posts: 6

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Jimmie wrote:

However when I issue a shutdown, it just reboots as if it's a reboot.

I vi'd the cleanboot.sh (in share) and there's something like if $1 = shutdown then blabla
Now curious as I am I entered those 2 commands and bam my NAS was off (oopsy smile)

This is a known bug in cleanboot 2.0

if [ $1 = shutdown ]; then
should actually be
if [ $1 = "shutdown" ]; then

Download and install cleanboot 2.0.4 (unofficial?) from here instead.

Last edited by timschuerewegen (2008-08-18 16:55:14)

Offline

 

#56 2008-08-21 02:23:09

Eskas
Member
Registered: 2008-05-23
Posts: 13

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Hello!
I don't know what I'm doing wrong when I'm trying to use cleanboot. But it doesn't work for me at all.
I'm having a dns 323 with 2x750 GB disks in standard mode with fw 1.05 and ffp 0.5, cleanboot-2.0-ffp05 installed.

I've pasted a list of running processes on my NAS. As you see I've made both a "reboot" and a "shutdown", but absolutely no reboot or shutdown is being made. When running any of these commands I just get "cleanboot: nothing to do smile" and it hangs there, this state can only be interupted with ctrl+c:

Code:

root@Nasse:/mnt/HD_a2/ffp/tmp# reboot
root@Nasse:/mnt/HD_a2/ffp/tmp# cleanboot: nothing to do :)

Anyone have any suggestions what can be wrong with my installation of cleanboot?

Code:

PID   USER     COMMAND
    1 root     init
    2 root     [ksoftirqd/0]
    3 root     [events/0]
    4 root     [khelper]
    5 root     [kthread]
   11 root     [kblockd/0]
   14 root     [khubd]
   49 root     [pdflush]
   50 root     [pdflush]
   52 root     [aio/0]
   51 root     [kswapd0]
  188 root     [scsi_eh_0]
  189 root     [scsi_eh_1]
  199 root     [mtdblockd]
  216 root     [kcryptd/0]
  217 root     [kmirrord/0]
  228 root     [loop0]
 1364 root     atd
 1612 root     chkbutton
 1633 root     /web/webs
 1635 root     /bin/sh /usr/sbin/chk_fun_plug
 1665 root     /usr/sbin/samba/smbd -D
 1669 root     /usr/sbin/samba/smbd -D
 1670 root     /usr/sbin/samba/nmbd -D
 1675 root     op_server 3 3 3
 1686 root     -sh
 1728 root     pure-ftpd (SERVER)
 1733 root     lpd Waiting
 1768 root     crond
 1780 root     /bin/sh /mnt/HD_a2/fun_plug
 1794 root     /ffp/bin/sh /ffp/etc/rc
 1819 Mackan   /ffp/bin/transmission-daemon -f -v 2
 1821 Mackan   /ffp/bin/transmission-daemon -f -v 2
 1822 Mackan   /ffp/bin/transmission-daemon -f -v 2
 1838 root     /ffp/sbin/sshd
 1850 root     /ffp/sbin/lighttpd -f /ffp/etc/lighttpd.conf
 1860 root     /bin/sh /ffp/start/ctrl_fan.sh start
 1867 root     /ffp/bin/php-cgi
 1877 root     /ffp/bin/php-cgi
 1881 root     /ffp/bin/php-cgi
 1882 root     /ffp/bin/php-cgi
14739 root     sshd: root@pts/0
14741 root     -sh
14860 root     /ffp/sbin/telnetd -l /ffp/bin/sh
14861 root     /ffp/bin/sh
15081 root     reboot
15082 root     sh -c /sbin/cleanboot.sh reboot 2>/dev/null
15083 root     /bin/sh /sbin/cleanboot.sh reboot
15092 root     /bin/sh /ffp/start/ctrl_fan.sh stop
15168 root     sleep 60
15190 root     sleep 60
15193 root     shutdown
15194 root     sh -c /sbin/cleanboot.sh shutdown 2>/dev/null
15195 root     /bin/sh /sbin/cleanboot.sh shutdown
15204 root     /bin/sh /ffp/start/ctrl_fan.sh stop
15222 root     sleep 60
15230 root     ps

EDIT: Problem solved! The cause of the problem was that I've added the ctrl_fan.sh script in my /ffp/start folder. This script contains an infinite loop which interupts the reboot/shutdown performed by cleanboot. My solution was to remove the infinite loop from the script, move the script to another folder than /ffp/start and execute the script from crontab instead. Now cleanboot seems to work.

Last edited by Eskas (2008-08-22 04:57:05)

Offline

 

#57 2008-08-21 15:55:04

Jimmie
New member
Registered: 2008-08-15
Posts: 4

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

timschuerewegen wrote:

Jimmie wrote:

However when I issue a shutdown, it just reboots as if it's a reboot.

I vi'd the cleanboot.sh (in share) and there's something like if $1 = shutdown then blabla
Now curious as I am I entered those 2 commands and bam my NAS was off (oopsy smile)

This is a known bug in cleanboot 2.0

if [ $1 = shutdown ]; then
should actually be
if [ $1 = "shutdown" ]; then

Download and install cleanboot 2.0.4 (unofficial?) from here instead.

Thanks a lot!

Offline

 

#58 2008-08-31 23:00:57

SVD
New member
Registered: 2008-06-22
Posts: 4

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Some remarks concerning the cleanboot funplug.
I've installed the funplug 5.0 on a USB memory stick of 1Gb.
Rebooting or shutdown of the DNS323 is working fine what the hard disks concerns however the USB device isn't unmounted correctly and generates some failure messages in the dmesg file after starting up the device.
Isn't it possible to unmount the usb device correctly?
in the directory /etc/hotplug there you can find the following

-rwxr--r-- 1 root root 22327 Dec 27  2005 usb.agent
-rwxr-xr-x 1 root root 10830 Dec  1  2006 usb.rc
-rwxr--r-- 1 root root 14877 Dec 27  2005 usbcdmount
-rwxr--r-- 1 root root 53019 Dec 27  2005 usbmount
-rwxr--r-- 1 root root 15913 Dec 27  2005 usbumount
-rwxr--r-- 1 root root  7758 Dec 27  2005 usbumountall
-rwxr--r-- 1 root root  1007 Dec 27  2005 usbunloaddrv

can we use the usbumountall to correctly close the USB device. I've tried this but the system give a error message

/ffp/bin/sh: usbumountall: not found

any advice?

Next point if the RAID1 is not clean anymore it is not sufficient to perform a:

  mdadm -A /dev/md0 /dev/sd[ab]2
  e2fsck /dev/md0

one need also to clean the swap files which are located on each separate drive and accessible via:

  sda4
  sdb4

so the check need to be done as follows:

  e2fsck /dev/sda4
  e2fsck /dev/sda4

and for the USB device

  e2fsck /dev/sdc1

system configuration

2 x 1Tb in RAID1 configuration
Fun plug 5.0 installed on USB device (1G)

Last edited by SVD (2008-08-31 23:03:17)

Offline

 

#59 2008-09-22 05:37:48

puterboy
Member
Registered: 2008-09-18
Posts: 306

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

pof wrote:

* Problem:

* How to shutdown your box after cleanboot has been installed:

telnet or ssh into your box and issue the command 'shutdown' or 'halt'.

NOTE: at the moment this is the only way to cleanly shutdown, if you do it either via the web panel or by pressing the button, the hard drives will not be cleanly unmounted.


* How to reboot your box after cleanboot has been installed:

There are several ways to reboot, all of them will umount the hard drives properly:

    1) telnet or ssh into your box and issue the command 'reboot'.
    2) issue a 'system restart' through the web administration panel
    3) point your browser to http://your_nas_ip/goform/System_restart

What about pressing down and holding the blue-lit power button on the DNS-323? Does that work with cleanboot? If not can it be made to work?

Offline

 

#60 2008-09-22 10:53:48

timschuerewegen
Member
Registered: 2008-08-05
Posts: 6

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

puterboy wrote:

What about pressing down and holding the blue-lit power button on the DNS-323? Does that work with cleanboot? If not can it be made to work?

Because I always shut down my DNS-323 using the front power button and almost never use the reboot/shutdown command from telnet/ssh I decided to uninstall the cleanboot package and add instead support for a "fun_plug_shutdown" script. This script, which is executed when you shut down the DNS-323 using the front power button, stops all FFP services, unmounts my USB thumbdrive (from which FFP is running), etc. so that the DNS-323 can unmount its drives properly. Interested?

Offline

 

#61 2008-09-22 11:30:51

knireis
Member
Registered: 2007-12-10
Posts: 231

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

timschuerewegen wrote:

puterboy wrote:

What about pressing down and holding the blue-lit power button on the DNS-323? Does that work with cleanboot? If not can it be made to work?

Interested?

I am

Offline

 

#62 2008-09-22 21:12:08

puterboy
Member
Registered: 2008-09-18
Posts: 306

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Interesting - does your script also work with the other reboot/shutdown methods?
Because it would be nice to have one unified "cleanboot" type package...

Offline

 

#63 2008-09-23 00:28:29

puterboy
Member
Registered: 2008-09-18
Posts: 306

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Just wondering too whether it might make sense to add lines to the script that check to make sure that the permissions on the root partition directories are 777 to avoid the infamous chmod a+w on reboot.

Offline

 

#64 2008-09-24 23:23:00

puterboy
Member
Registered: 2008-09-18
Posts: 306

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Reboot is working fine for me but 'halt' either doesn't shut down or takes about an hour for the command to finally shut the machine day.

Not sure what is happening here...

Offline

 

#65 2008-09-24 23:24:33

puterboy
Member
Registered: 2008-09-18
Posts: 306

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

to clarify, as soon as I type "halt" the NAS becomes unreachable via telnet, ssh, and the web interface. Also smb file sharing stops.
But the NAS is still pingable...

Offline

 

#66 2008-09-24 23:26:04

puterboy
Member
Registered: 2008-09-18
Posts: 306

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

and for good measure the hardware reset button isn't responsive either...

I imagine it must be getting "stuck" somewhere in the shutdown process

Offline

 

#67 2008-10-07 14:30:01

nurunet
Member
From: Germany
Registered: 2008-08-31
Posts: 44

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

timschuerewegen wrote:

puterboy wrote:

What about pressing down and holding the blue-lit power button on the DNS-323? Does that work with cleanboot? If not can it be made to work?

Because I always shut down my DNS-323 using the front power button and almost never use the reboot/shutdown command from telnet/ssh I decided to uninstall the cleanboot package and add instead support for a "fun_plug_shutdown" script. This script, which is executed when you shut down the DNS-323 using the front power button, stops all FFP services, unmounts my USB thumbdrive (from which FFP is running), etc. so that the DNS-323 can unmount its drives properly. Interested?

Heck yeah! I'm not running PuTTY all the time, so this would be really sweet to have.


Conceptronic CH3SNAS FW 1.03, ffp from USB key.

Offline

 

#68 2008-10-08 22:04:08

nurunet
Member
From: Germany
Registered: 2008-08-31
Posts: 44

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Hi you all! I just installed cleanboot, entered "reboot" in PuTTY (ssh) and something seems to go terribly wrong. I get something like this, repeating itself all the time:

root@NAS:/mnt/HD_a2/usbstorage/ffp/start# $Shutting down SMB services:
$Shutting down NMB services:
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
umount: /mnt/HD_c*: not found
umount: /mnt/HD_c*: not found
umount: /mnt/HD_c*: not found
umount: /mnt/HD_c*: not found
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
$Shutting down SMB services: kill: Usage: kill [-s sigspec | -signum | -sigspec] [pid | job]... or
kill -l [exitstatus]

$Shutting down NMB services: kill: Usage: kill [-s sigspec | -signum | -sigspec] [pid | job]... or
kill -l [exitstatus]

umount: /mnt/HD_a*: not found
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
umount: /mnt/HD_b*: not found
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
umount: /mnt/HD_c*: not found
umount: /mnt/HD_c*: not found
umount: /mnt/HD_c*: not found
umount: /mnt/HD_c*: not found
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
$Shutting down SMB services: kill: Usage: kill [-s sigspec | -signum | -sigspec] [pid | job]... or
kill -l [exitstatus]

$Shutting down NMB services: kill: Usage: kill [-s sigspec | -signum | -sigspec] [pid | job]... or
kill -l [exitstatus]

umount: /mnt/HD_a*: not found
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
umount: /mnt/HD_b*: not found
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
Refresh Shared Name Table version v1.04
umount: /mnt/HD_c*: not found

This seems to be an endless loop. And there should be /mnt/HD_a* and /mnt/HD_b*.

Anybody knows what I can do? While this was running, I couldn't reboot via the web interface (although it stated success), had to use the CH3SNAS' button.

Last edited by nurunet (2008-10-08 22:18:27)


Conceptronic CH3SNAS FW 1.03, ffp from USB key.

Offline

 

#69 2008-10-09 09:22:27

RunaR
Member
Registered: 2008-08-14
Posts: 49

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Same thing here. That's the reason I removed cleaboot from my CH3SNAS.

Offline

 

#70 2008-10-11 01:56:08

SilentException
Member
From: Island of Krk, Croatia
Registered: 2008-05-04
Posts: 148

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

huh, i spent some time checking, testing and investigating cleanboot.sh script and attached here is my modified version smile

this is the modified version of marinalink's script: http://dns323.kood.org/forum/t2346-smal … nboot.html

i fixed a few bugs and added few things of my own (to suite my needs). included is even netcat debugging if you get stuck smile

have fun with it

Last edited by SilentException (2008-10-11 02:05:40)


Attachments:
Attachment Icon cleanboot.tgz, Size: 1,476 bytes, Downloads: 752

D-Link DNS-323 v1.05 fun_plug-ed + many mods,  2 x 320GB Seagate Barracuda 7200.10 RAID0, Cat6 Gigabit Network, 9k Jumbo Frames, Average (WRITE): 19,32 MB/sec, Average (READ): 28,6 MB/sec

Offline

 

#71 2008-10-11 11:51:59

nurunet
Member
From: Germany
Registered: 2008-08-31
Posts: 44

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Hi SilentException,

how do I install your script? "funpkg -i cleanboot.tgz" does not work. Do I have to install marinalink's package first and the replace her cleanboot.sh with yours?

Regards
Ben

Last edited by nurunet (2008-10-11 11:53:25)


Conceptronic CH3SNAS FW 1.03, ffp from USB key.

Offline

 

#72 2008-10-12 02:02:16

puterboy
Member
Registered: 2008-09-18
Posts: 306

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

SilentException wrote:

huh, i spent some time checking, testing and investigating cleanboot.sh script and attached here is my modified version smile

this is the modified version of marinalink's script: http://dns323.kood.org/forum/t2346-smal … nboot.html

i fixed a few bugs and added few things of my own (to suite my needs). included is even netcat debugging if you get stuck smile

have fun with it

SilentException, could you help clarify a couple of questions:
1. Is your version based off of the latest 2.0.4 version or was it forked earlier?
2. Is there a way to unify at least your bug fixes (if not also your enhancements) with the original trunk and to have a unified numbering system so that upgrades are easy and clear?
3. What bugs did you fix and what enhancements did you add?

Thanks!

Offline

 

#73 2008-10-12 21:19:29

SilentException
Member
From: Island of Krk, Croatia
Registered: 2008-05-04
Posts: 148

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

puterboy wrote:

SilentException wrote:

huh, i spent some time checking, testing and investigating cleanboot.sh script and attached here is my modified version smile

this is the modified version of marinalink's script: http://dns323.kood.org/forum/t2346-smal … nboot.html

i fixed a few bugs and added few things of my own (to suite my needs). included is even netcat debugging if you get stuck smile

have fun with it

SilentException, could you help clarify a couple of questions:
1. Is your version based off of the latest 2.0.4 version or was it forked earlier?
2. Is there a way to unify at least your bug fixes (if not also your enhancements) with the original trunk and to have a unified numbering system so that upgrades are easy and clear?
3. What bugs did you fix and what enhancements did you add?

Thanks!

ok, here it goes:
1. this version is based on 2.0.4 version from marinalink in that thread i posted
2. 2.0.4 is based on original, mine is based on 2.0.4. since the original author of cleanboot (pof) wasn't around much lately, i could create new ffp package, version 2.0.5, open a thread and maintain it there.
3.

* i fixed all paths (when issuing restart via web interface there is no fun_plug path set) so awk command for example wouldnt be found, or xargs

* one thing i noticed is when there are no paths set right (web interface restart), many of the scripts from /ffp/start won't work.. here is the cut from the log file:

Code:

current 'set':
USER='root'
HOME='/'
PS1='# '
OPTIND='1'
PS2='> '
TERM='vt102'
PPID='1811'
PATH='/usr/bin:/bin:/usr/sbin:/sbin'
SHELL='/bin/sh'
IFS='
'
PWD='/'

cleanboot: nothing to do :)
Stopping ezipupdate...
sed: illegal option -- i
BusyBox v1.00-pre1 (2007.12.10-08:03+0000) multi-call binary

Usage: sed [-nef] pattern [files...]

Stopped
WARNING: lighttpd: Not running
WARNING: telnetd: Not running

lighttpd and telnetd were running btw..
therefore i added this lines at start of /ffp/etc/ffp.subr file:

Code:

if [ -z ${MAIL} ]; then
        #setup the ENV variables if not found
        #this can happen when running from crontab
        echo "Environment variables not found, including fun_plug defaults."
        . /ffp/etc/profile
fi

if your startup/shutdown scripts aren't using ffp.subr but a custom start/stop methods (like mlnet.sh) you should add the same lines at start of those too

* added more kill lines (for /HD_ /USB). mine USB drive is mounted on /mnt/USB, if you use other replace it in the script

* pid check before kill when killing daemons from /ffp/etc/cleanboot.conf

* swapoff

* lsof kill

* cut command (not working) replaced with sed

* added some daemons in cleanboot.conf


Attachments:
Attachment Icon cleanboot-2.0.5-ffp05.tgz, Size: 95,062 bytes, Downloads: 1,434

D-Link DNS-323 v1.05 fun_plug-ed + many mods,  2 x 320GB Seagate Barracuda 7200.10 RAID0, Cat6 Gigabit Network, 9k Jumbo Frames, Average (WRITE): 19,32 MB/sec, Average (READ): 28,6 MB/sec

Offline

 

#74 2008-10-14 00:54:51

nurunet
Member
From: Germany
Registered: 2008-08-31
Posts: 44

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

Would it maybe possible to integrate EnricoM's patch for CH3SNAS users? Without it, it won't run.

Cheers,
Ben


Conceptronic CH3SNAS FW 1.03, ffp from USB key.

Offline

 

#75 2009-02-12 08:10:02

MosaicPaul
Member
Registered: 2008-12-31
Posts: 10

Re: cleanboot 1.0 for DNS-323 / CH3SNAS

I've installed cleanboot 2.0.5 with ffp0.5 and I've been testing it.  It seems to allow me to reboot cleanly, either through telnet or the admin web interface, but I can't shutdown cleanly.  Whether I use the web interface's Shutdown, or I press the front panel button to shutdown, I subsequently get the EXT2-fs warnings in dmesg after the next boot.

timschuerewegen, you mentioned a script for shutting down cleanly from the front panel button; does that work?  I'm desperate for at least some way of shutting down cleanly!

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2010 PunBB