Re: /sbin/init Initrd

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

 



> Ty for reply,

> but i dont need the system /sbin/init
> i need the source code of /sbin/init from initrd.img
> if you unpack the initrd.img from Fedora 8 CD-ROM
> you will find a binary called init, what is a sym link from /sbin/init
> from initrd.img.

> but i already find what i need
> on fedora 8 anaconda installer create this init from your compilation,
> and when you install anaconda on the CD he copy you initrd to /cdrom/isolinux/initrd.img
> so now i can do what i want.

It sounds like you might have solved your problem.
If not, the following might help.

Your English is causing me  some trouble in understanding what you want to do.

I _think_ you might be trying to modify the init file which is
embedded inside the initrd.gz.
This file is not a "binary" but is an "executable script".

You need to do a 3 step process
1) unpack the initrd.gz
2) edit the init file
3) repack with the modified init file

Following is from some old notes from a long time ago:

I have used (not recently) this prescription and it works.

8. Modifying an Existing Initial Ram Disk
8.1      Introduction
This section
briefly describes how an initrd_usb.gz file may be unscrambled, modified and
put back together again.

8.2      Detailed Instructions

8.2.1 Unpacking
       cd                                        go to root's home dir
       mkdir clean; cd clean                     make and go somewhere clean
       cp /boot/initrd_usb.gz .                  cp initrd_usb.gz to clean dir
       gunzip -c initrd_usb.gz | cpio -i         gunzip and expand

This unpacks a complete directory structure
- the vital file is init, edit as required.

8.2.2 Repacking

Remember to move the original file first or it will be incorporated
in the new initrd image!!

       mv initrd_usb.gz ~
       find . | cpio -c -o | gzip -9 > ~/initrd_usb_modified.gz
The file can then be relocated to /boot and grub.conf modified to match.

I hope this helps

Jack
-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines

[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux