LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Embedded & Single-board computer (https://www.linuxquestions.org/questions/linux-embedded-and-single-board-computer-78/)
-   -   backup embedded system (https://www.linuxquestions.org/questions/linux-embedded-and-single-board-computer-78/backup-embedded-system-704711/)

audiogreenie 02-14-2009 07:44 PM

backup embedded system
 
New to embedded linux and linux. I have an embedded linux system on ARM9. I am able to access root via LAN and access the console (I think) via serial port. It use vivi (or something called suppervivi) as bootloader. I found a JTAG on the board but don't know the pin config. I would like to learn embedded system by replacing the bootloader and regen the linux kernel. But before that, I would like to prepare for the worse. How can I backup the whole system so that in case something wrong I can restore to stock?

ravi_chobey 02-20-2009 03:54 AM

with the help of "dd" command,you can make the image. And after that you can do whatever you want.
dd if=/dev/mtdblocks of=linux.img.

After your work,

dd if=linux.img of=/dev/mtdblocks

Try this and let us know.

Regards,
Ravi

theNbomr 02-22-2009 11:14 AM

You should proceed with caution. It may be possible to overwrite the bootloader from a userspace application, but unless the new bootloader is at least functional enough to repeat the process, you will have to use an alternative method to restore a working bootloader. Whether this is possible is completely hardware dependent. Given the presence of a JTAG interface, it is possible, but not guaranteed, that the bootloader can be restored using the JTAG interface. You should ascertain that you have a clear understanding of, and the necessary ancillary support (cabling, development host software, etc.) to correct any bootloader corruption. Without this, there is a real possibility of making your embedded target into a brick.
Can you provide a make/model description of your target hardware? There may be someone with firsthand experience with your hardware that can provide specific answers.
--- rod.

audiogreenie 02-23-2009 12:40 AM

ravi, Am I right that the dd only backup the kernel image but not the bootloader?

Nbomr, Thanks. I don't know what info is needed for others to help me. I have root access so that I can look for anywhere in the system, but I don't know what to look for answer to my question. Here is a few which I believe is related:

/proc/cpuinfo
Processor : ARM920Tid(wb) rev 0 (v4l)
BogoMIPS : 202.34
Hardware : SBC2440

Here is at the beginning of the console (I believe), before loading kernel:
VIVI version 0.1.4 (root@localhost.localdomain) (gcc version 2.95.3 20010315 (re
lease)) #0.1.4 Sat Jul 21 11:51:25 CST 2007
MMU table base address = 0x33DFC000
Succeed memory mapping.
DIVN_UPLL0
MPLLVal [M:7fh,P:2h,S:1h]
CLKDIVN:5h

+---------------------------------------------+
| S3C2440A USB Downloader ver R0.03 2004 Jan |
+---------------------------------------------+
USB: IN_ENDPOINT:1 OUT_ENDPOINT:3
FORMAT: <ADDR(DATA):4>+<SIZE(n+10):4>+<DATA:n>+<CS:2>
NOTE: Power off/on or press the reset button for 1 sec
in order to get a valid USB device address.

NAND device: Manufacture ID: 0xec, Chip ID: 0x76 (Samsung K9D1208V0M)
Could not found stored vivi parameters. Use default vivi parameters.
Press Return to start the LINUX/Wince now, any other key for vivi
Copy linux kernel from 0x00050000 to 0x30008000, size = 0x00200000 ... done

Would like to find out how to backup the bootloader. Let me know if any other info is needed.

theNbomr 02-23-2009 12:26 PM

You will need to know in what part of non-volatile memory the bootloader is stored, and what method(s) are used to write to said memory. If the target host/board is intended to be used for OEMs to embed in other products, this information should be provided by the manufacturer as part of the product documentation. In the case of OEM-targeted products, they may also provide documentation or software tools to help you perform the operation of reloading/replacing the bootloader. Your challenge is not to backup the bootloader, but to restore it, if necessary.
Can you provide a make/model description of your target hardware? There may be someone with firsthand experience with your hardware that can provide specific answers.
--- rod.


All times are GMT -5. The time now is 06:00 PM.