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

#1 2011-01-28 16:45:29

TXPilot69
New member
Registered: 2011-01-28
Posts: 2

Telnet from USB, so I can e2fsck my ext2 JBOD volume

Hi guys.  I'm new to the forums, but not to the DNS products; I have a 1.5TB DNS-323 with RAID0/EXT3 filesystem for my important files, and an 8TB DNS-343 with a JBOD/EXT2 filesystem for media file storage.

I took a power hit while moving some files to the DNS-343, and it works fine, but I'm seeing 'input/output error' for the inodes of the files I was in the process of moving at the time; Windows says the files are in use, and from the ssh prompt (I have ffp installed, ssh configured) I can't remove the files, with an error message that the system cannot stat the file due to input/output errors.

I ran e2fsck with the -n flag, and it found issues with those files, but I can't run it with the -y flag to fix the errors with the volume mounted.  I'm not able to unmount the volume because I'm ssh'd in, and 'fu' shows ssh using the volume (/ffp is mounted on that volume).

I *think* what I need to do from the research I've done on this excellent site and others is configure telnet to run from a bootable USB drive, boot from that USB stick and umount the volume and run my checks.  I'm a little lost on where to start or how to configure this.  Can somebody point me in the right direction?  Is there a HOWTO on this?  If not, I volunteer to document the process and create one as I go through this process.

Offline

 

#2 2011-03-14 01:52:05

cliaz
Member
From: Melbourne, Australia
Registered: 2008-11-10
Posts: 55
Website

Re: Telnet from USB, so I can e2fsck my ext2 JBOD volume

If you haven't managed to do it already...

Because the 343 has a different kernel, using fonz's fsck module (http://inreto.de/dns323/fsck) doesn't work.

The way I did it was to copy my ffp folder to USB so I could boot from there - meaning I can umount all my HDDs and go nuts.


1) To mount your usb drive - http://dns323.kood.org/forum/viewtopic. … 653#p30653 (do test to make sure you can reboot with it)

2) once rebooted and usb drive still working, copy your ffp from /mnt/HD_a2/ffp to /mnt/usb/

Code:

cp -a /mnt/HD_a2/ffp /mnt/usb

3) to boot ffp from usb
create a folder /mnt/HD_a2/.bootstrap

Code:

# mkdir /mnt/HD_a2/.bootstrap

copy /sys/crfs/driver/usb-storage.ko (make sure to use the one stored on system already as it's tailored for 343 - thanks fonz!) to /mnt/HD_a2/.bootstrap

Code:

# cp /sys/crfs/driver/usb-storage.ko /mnt/HD_a2/.bootstrap

download setup.sh (source: http://dns323.kood.org/forum/t3203-setu … -root.html) and place it into /mnt/HD_a2/.bootstrap

Edit setup.sh for your system. The two things you'll need to change are:

which usb-storage module to use

Code:

USBMODULE=${INTERNALHD}/.bootstrap/usb-storage.ko #USB storage module location

should be

Code:

cp /sys/crfs/driver/usb-storage.ko /lib/modules/ #copy USB storage module to VRAM so that physical disks can be unmounted
USBMODULE=/lib/modules/usb-storage.ko #USB storage module location

and which device is your usb - the 343 can have 4 HDDs as opposed to the 323's 2.

Code:

USBFFPPART=/dev/sdc5   #USB partition containing the /ffp system

should be

Code:

USBFFPPART=/dev/sde1   #USB partition containing the /ffp system

(or whatever dev/sd<letter>1 your usb drive is)

4) Last but not least, create the dummy file /mnt/usb/.ffp-usb

Code:

touch /mnt/usb/.usb-ffp

reboot!


then you can umount and e2fsck to your heart's content.

Offline

 

#3 2011-03-14 15:27:36

TXPilot69
New member
Registered: 2011-01-28
Posts: 2

Re: Telnet from USB, so I can e2fsck my ext2 JBOD volume

THANK YOU for those detailed instructions!  I did get past my original issue, but will be keeping this as a sticky note for future use!

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2010 PunBB