Switch to full style
User discussion and information resource forum for Image products.
Forum rules
Post a reply

Changes to initrmfs.gz

Mon Aug 28, 2017 2:00 pm

Hi,
I am trying to change some of the files within initrmfs.gz, and not sure how I can do this. Any suggestions would be appreciated.

Re: Changes to initrmfs.gz

Mon Aug 28, 2017 4:37 pm

Could you provide some details on what you're trying to accomplish? Depending what it is there may be an easier method.

Re: Changes to initrmfs.gz

Tue Aug 29, 2017 12:38 pm

Hi, yes. I have an initrmfs.gz on a USB that I am booting to do a system restore. The .gz has 2 custom embedded .png files that I need to replace. I would just like to unzip/untar, replace the 2 files, and zip/tar it back up into initrmfs.gz. I've tried a couple of times but the resulting USB won't boot. Thanks for the support.

Re: Changes to initrmfs.gz

Tue Aug 29, 2017 4:39 pm

I usually do that kind of thing in an installed Linux, but it can also be done when booted to the IFL boot media.

1. Boot to IFL UFD.

2. Open a Terminal.

3. Copy the initrmfs.gz file you want to modify to the ramdisk so it can be extracted. This may require mounting a drive or partition (e.g. the file is on the IFL UFD). Example: cp mnt1/initrmfs.gz .

4. Create a folder for the extracted files: mkdir extracted

5. Change to the new folder: cd extracted

6. Extract the files: zcat ../initrmfs.gz | cpio -idmv

7. Make changes to the files.

8. Repack the files (you should be in the folder with extracted files):
find . | cpio -H newc -o | gzip -9 > ../initrmfs_new.gz

You can rename the "new" file whatever you want. I used a different name here so it doesn't overwrite the original. You would need to adjust any paths/filenames as necessary and may want different options.

Re: Changes to initrmfs.gz

Tue Aug 29, 2017 7:52 pm

Thanks Paul, this is exactly the info I needed. I'll try it and let you know, I appreciate the help.

Re: Changes to initrmfs.gz

Wed Aug 30, 2017 4:04 pm

which graphics? Which license are you under? Can send to support@ email
address.

"dedeen" wrote in message news:14144@public.image...

Thanks Paul, this is exactly the info I needed. I'll try it and let you
know, I appreciate the help.

Post a reply