[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Upgrade to linux-image-3.12-1-kirkwood on qnap ts-110 bricks the NAS (until recover)



iacchi ha scritto:
> I'll let you know if everything was fine or if I need some more info.

Ok, I definitely need some more info. I've started to write a text file
describing the recovery process. Right now it's only an unordered list,
but I'll make a doc out of it. I'm pasting it here - can you read it and
then answer the questions I have at the end?

TS-11x recovery

- create a recovery image -
* Follow instructions at
http://www.cyrius.com/debian/kirkwood/qnap/ts-119/recovery/ to create a
recovery image with a Debian installer inside (i.e. substitute mtd1 and
mtd2 with the kernel and initrd downloaded from the Debian website). If
you made backups of mtds after Debian was installed in the nas, use
those instead of the one of the Debian installer.

- install a dhcp and a tftp server on a machine -
* install both server
* put the recovery image in the root of the tftp server
* if possible, connect the nas directly to the dhcp/tftp server machine,
otherwise configure your machine with a static address and switch off
your router's dhcp server so the one on your machine will be used instead

- discover the nas mac address -
* switch off the nas if it's on
* press the reset button, keep it pressed, switch on the nas, stop
pressing the reset button when you hear two short beeps
* look for dhcpdiscover messages in /var/log/syslog on your machine to
find out the nas mac address
* switch off the nas again

- configure the dhcp server and start recovering -
* write dhcpd.conf as described in the link above using the mac address
you've discovered
* switch on again the nas in recovery mode pressing the reset button
* wait until ti makes other two short beeps, it means that it has found
the tftp server and loaded the recovery image

- connect to the Debian installer -
* follow instructions on this page:
http://www.cyrius.com/journal/debian/installer-flash-kernel to connect
to the debian installer and load a shell



First question: the guide in the link just above assumes that / and
/boot are in two separate partitions, while I have them in the same one.
Should I only mount /dev/sda1 as / and that's it? In my case I won't
have to refer to the /boot directory in any way, because it's already
inside / in /dev/sda1, right?

Second question: the guide just says "make modifications to the system
and regenerate the initramfs" because you can do pretty much everything
there. But... what should I do? How do I flash a working kernel? This is
what I thought:
1. Flash the kernel and initram contained in the Debian installer - how?
Will it work?
2. Flash the last working kernel of Debian testing - how? Or, better, I
know how: I have to wget the .deb files of the working kernel and
initram and install them with dpkg, then launch flash-kernel (with
special parameters?). But how can I find these .deb files? can I look in
the apt cache directory to see if they're still there? Can I download
them from the Debian repositories? Does Debian keep a copy of older
kernels/deb in general online? I've never found them.
3. What else?

Third question: after I've managed to flash a working kernel and
initram, should I still give the command "update-initramfs -u" as the
guide says? Or will it be redundant/unuseful at this point?

Four: if all of the above goes right, when I reboot will I have my
system back as it was before the problem? With all my
data/programs/system accessible as it was before? Or there will be other
steps to perform before I can go back using it?

thank you for all your help,
Iacopo


Reply to: