Linux - Embedded & Single-board computerThis forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am using Linux over AMCC PPC440EPx board. The Busybox image is a ram disk image that is loaded over the board.
During the booting up process, the device image is uncompressed and loaded into the ram but whatever changes that I have made are not saved to the compressed image. Instead all the settings are reset to default over reboot.
Of course your changes are lost. You are making the changes to the uncompressed system in RAM, not to the image. Read out the image, decompress it, make your changes, compress the new image and write it back.
No, you have to do it the way I told you. Unpack the image on a different computer, make the changes you want to the unpacked files, repack them and write the new image to you embedded board.
Is the original media from which the RAM disk is loaded accessible as a writable filesystem? Often on embedded systems, the bootloader fetches the kernel and initrd from a form of flash that can only be updated using something like a jtag interface. In such a case as that, you cannot store the changes back to non-volatile memory. It may also be the case that you have a small amount of writable non-volatile memory that can be used to store runtime data. In this case, you would have to modify your application so that it deliberately uses this kind of store. Your application might periodically write a configuration file or binary blob to the non-volatile media, and on boot, re-read the saved configuration to an appropriate place.
Is something like compact flash, SD card, or USB mass storage an option for you?
--- rod.
Just like theNbomr stated, if you can access the block device file where the ramdisk is written (usually flash memory), then you can change the whole ramdisk by using dd to write to that location. But you should know beforehand the address and allocated size of the ramdisk so you won't overwrite the other partition on that block device.
If you want to save some files that can be retained in your device, write them on a different writable partition that you mounted during bootup.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.