summaryrefslogtreecommitdiff
path: root/mkinitramfs
AgeCommit message (Collapse)Author
2010-06-18mkinitramfs, lsinitramfs: Better error message for non-GNU getoptmaximilian attems
Reported-by: Michael Prokop <mika@debian.org> Signed-off-by: maximilian attems <maks@debian.org>
2010-06-17mkinitramfs: No point in hardcoding busybox pathmaximilian attems
should make merge for Ubuntu easier. Thanks to David Greaves in LP: #573282 for the idea. Signed-off-by: maximilian attems <maks@debian.org>
2010-06-16initramfs-tools: work around 'find -printf %Y' bugColin Watson
The change to filter out looping or broken symlinks from the initramfs, written by me for Ubuntu and applied to Debian for #575157, tickles a bug in find (which I think also had an associated Debian bug, but I've been unable to find it): https://savannah.gnu.org/bugs/index.php?29460 This was fixed in 4.5.8, which is currently only in experimental. In any case findutils is very deep in the dependency chain for upgrades and I believe it would be a good idea to avoid requiring a new version of it (I've had problems quite recently with strict dependencies on findutils causing unresolvable dependency loops). The following patch works around this bug in a reasonably straightforward way. [ debian findutils bug was #576772 ] Signed-off-by: maximilian attems <maks@debian.org>
2010-06-14code cleanup: consequently use "W:" for warnings.Michael Prokop
The only exception is log_warning_msg() inside scripts/functions which is/can be used by external scripts. Signed-off-by: Michael Prokop <mika@debian.org>
2010-06-14code cleanup: consequently replace spaces in indentions with tabs to unify ↵Michael Prokop
coding stile Signed-off-by: Michael Prokop <mika@debian.org>
2010-06-14code cleanup: drop trailing whitespaces.Michael Prokop
Signed-off-by: Michael Prokop <mika@debian.org>
2010-06-14hook-functions/mkinitramfs/update-initramfs: consequently output error ↵Michael Prokop
messages to stderr Signed-off-by: Michael Prokop <mika@debian.org>
2010-06-08mkinitramfs: warn if TMPDIR is mounted noexec + fall back to not cache run ↵Michael Prokop
scripts then If the TMPDIR (/tmp by default) is mounted with noexec the user will notify several lines like: /usr/sbin/mkinitramfs: 276: /tmp/mkinitramfs_Ck5cpl/scripts/init-top/all_generic_ide: Permission denied To get rid of that the user can either point $TMPDIR to a filesystem that's mounted with exec permission or otherwise the cache_run_scripts() feature won't be used. Notify user accordingly with a warning message. [Closes: #576678] Signed-off-by: Michael Prokop <mika@debian.org>
2010-06-08Support dashes inside scripts names.Michael Prokop
[Closes: #566056] Signed-off-by: Michael Prokop <mika@debian.org>
2010-05-18Revert "mkinitramfs: only copy modprobe conf files"maximilian attems
This reverts commit 836e5cf6ddb30757365c2b879b96958c250dcd7b. due to partial upgrades this can only done after squueeze release. Reopen: #506533 Closes: #577981 Signed-off-by: maximilian attems <maks@debian.org>
2010-04-10mkinitramfs: use -9 for lzopbert schulze
"You do want to use -9 as far as LZO is concerned. The compression ratio is way better, and the extraction time is actually *not* related to the compression level" Albin Tonnerre already pointed that out to Maximilian, forgot to put you on CC. Let's keep the gzip "speed enthusiasts" happy and enable -9 for lzop only. Signed-off-by: maximilian attems <maks@debian.org>
2010-04-09mkinitramfs: add LZO supportbert schulze
Albin Tonnerre sent a patch fixing the initramfs LZO decompression, so heres my fix for initramfs-tools to have compete compression support. Tell me if you want me to open a new bugreport. On a side note: this will only work with a patched kernel (might be upstream with 2.6.34), its a good idea to include a warning for those running 2.6.33 from experimental [ adding it on TODO of Lenny linux-2.6 2.6.32 ] Signed-off-by: maximilian attems <maks@debian.org>
2010-04-07mkinitramfs: On verbose indication what we rmmaximilian attems
not a fix for #576677, but at least some indication. Signed-off-by: maximilian attems <maks@debian.org>
2010-04-07mkinitramfs: Fix several unbound variablesmaximilian attems
might not be all, but a first go in stricter mkinitramfs. as bonus remove old amusing unused varialbe from day 2.. Signed-off-by: maximilian attems <maks@debian.org>
2010-04-07mkinitramfs: guard against empty EXTRA_CONFmaximilian attems
nothing there to see allmost.. Signed-off-by: maximilian attems <maks@debian.org>
2010-04-06mkinitramfs: Use TMPDIR definitionmaximilian attems
mktemp has marked the "-t" option as depcrecated, support TMPDIR. Signed-off-by: maximilian attems <maks@debian.org>
2010-04-06mkinitramfs: check only once for existing lddmaximilian attems
no point to recheck on every copy_exec. now copy_exec starts to get redable.. Signed-off-by: maximilian attems <maks@debian.org>
2010-04-05mkinitramfs: be silent if no map was generated in first placemaximilian attems
no need to spam people with: rm: cannot remove `/tmp/mkinitramfs_jWCE0R/lib/modules/2.6.33-2-amd64/modules.*map': No such file or directory Signed-off-by: maximilian attems <maks@debian.org>
2010-04-05mkinitramfs: set initramfs root to 755Colin Watson
fixes unionfs-fuse to service requests made by non-root users. [ merge from 0.92bubuntu31, this does not interfer with UMASK setting of created initramfs, but only concerns / of initramfs -maks ] Signed-off-by: maximilian attems <maks@debian.org>
2010-04-05mkinitramfs: generate pre-cached boot order fileScott James Remnant
if tsort is available, use it instead of custom sorting code if a pre-cached order file is available, use that instead [ move cache_run_scripts from scripts/functions to hook-scripts as only used on mkinitramfs build and not on boot ] Signed-off-by: maximilian attems <maks@debian.org>
2010-04-05mkinitramfs: no longer copy depmodmaximilian attems
it is no longer used on boot, saves initramfs space and thus speed. Signed-off-by: maximilian attems <maks@debian.org>
2010-04-04mkinitramfs: -c compression support / commandline overrideBert Schulze
fixed the commandline argument to select the compressor. also your test with "command" needed to be negated otherwise the fallback to gzip would take place everytime. -- frohe ostern Bert Schulze [ nuked trailing whitespace, and add comment for usage() ] Signed-off-by: maximilian attems <maks@debian.org>
2010-04-04initramfs-tools: support different compression tools in mkinitramfsbert schulze
this version uses /etc/initramfs-tools/initramfs.conf to determine the compression method, checks kernel and userspace support with fallback to gzip. Since LZO didnt work for me at all with 2.6.33 I left that out for now. (closes: #533903) [ minor changes in mkinitramfs code ] Signed-off-by: maximilian attems <maks@debian.org>
2010-03-27mkinitramfs: Filter out looping or broken symlinks from the initramfsColin Watson
they cause cpio to explode (LP: #540686). [ merge from 0.92bubuntu70 ] (closes: #575157) Signed-off-by: maximilian attems <maks@debian.org>
2010-03-25mkinitramfs: allow to build initramfs for unmodular linux imagesmaximilian attems
this is untested. (closes: #415474, #433708) Signed-off-by: maximilian attems <maks@debian.org>
2010-03-24mkinitramfs: Call depmod before packing the initramfs.Scott James Remnant
init: thus drop depmod call. Don't quote modules.*map, so we actually expand it. (closes: #465760, #562561) [ merge from 0.92bubuntu57 and 0.92bubuntu58 ] Signed-off-by: maximilian attems <maks@debian.org>
2010-02-19mkinitramfs: only copy modprobe conf filesmaximilian attems
do not add packaging garbage (closes: #506533) Signed-off-by: maximilian attems <maks@debian.org>
2009-07-29mkinitramfs fix commentmaximilian attems
2009-07-29move busybox addition to a hook scriptmaximilian attems
thus export the 2 needed busybox variables, be sure to have the klibc shell for now around. Signed-off-by: maximilian attems <maks@debian.org>
2009-07-29create a klibc hook scriptmaximilian attems
we may soon no longer need it, so move it out to its own, so it can be more easily played with. Signed-off-by: maximilian attems <maks@debian.org>
2009-05-18mkinitramfs: Invoke dpkg --print-architecturemaximilian attems
Fixes: > Running update-initramfs. > update-initramfs: Generating /boot/initrd.img-2.6.29-2-amd64 > dpkg : avertissement : obsolete option > '--print-installation-architecture', please use '--print-architecture' > instead. > dpkg : avertissement : obsolete option > '--print-installation-architecture', please use '--print-architecture' > instead. While we are it nuke duplicate invocation, since DPKG_ARCH is an exported variable anyway. (closes: #529222) Reported-by: Raphaël Hertzog <hertzog@debian.org> Signed-off-by: maximilian attems <maks@debian.org>
2009-04-02mkinitramfs: Allow dots in boot and script filenames.maximilian attems
the regex was overly severe not allowing dots althoug they are useful as word ending. based on a patch in launchpad, that didn't get all occurences right, but was a good start. (LP: #305837)
2009-03-19mkinitramfs: include the modules.order file.Scott James Remnant
i've made an install of new kernel on Intrepid: 2.6.27-8-generic (32 bits) and kernel.log have a warning about load order of ehci_hcd: Warning! ehci_hcd should always be loaded before uhci_hcd and ohci_hcd, not after LP: #296710.
2009-02-17mkinitramfs: Complete postlenny cleanupmaximilian attems
the supported-host long call feature was already dropped before lenny, thus just kick it. no other long calling getopt strings yet..
2009-02-15mkinitramfs: Do not pass exit code through on pipe failureKees Cook
Since "exit 2" has a special meaning, we must "exit 1" when the find/cpio/gzip pipe fails, otherwise "update-initramfs" will potentially ignore failures (it ignores return code "2" from mkinitramfs). Signed-off-by: Kees Cook <kees@debian.org>
2009-02-13mkinitramfs: Fix new pipe construct to really work inside "${DESTDIR}"maximilian attems
trivial fix on top of previous change. afais cpio doesn't really give sensible return errors, so this fall through the cracks.
2009-02-13minitramfs: find/cpio exit codes ignored while building initramfsKees Cook
The final stage of mkinitramfs that builds the image does not verify the exit codes of find or cpio: (cd "${DESTDIR}" && find . | cpio --quiet --dereference -o -H newc | gzip >"${outfile}") || exit 1 Once bug 514936 is solved, this will be even more important, since cpio will actually return errors. Attached is a gross alternative to depending on bash... Current behavior: $ find /fail | cpio --quiet --dereference -o -H newc | gzip > /tmp/archive.gz find: `/fail': No such file or directory $ echo $? 0 Desired behavior: $ set -o pipefail $ find /fail | cpio --quiet --dereference -o -H newc | gzip > /tmp/archive.gz find: `/fail': No such file or directory $ echo $? 1 (closes: #514938) [ already useful in finding stupid mkinitramfs path errors -maks ]
2009-02-13mkinitramfs: fix cp DESTDIR destination.maximilian attems
uncovered due to tests with harden cpio failures. bug got introduced postlenny in d2791a8fa458d473ff92d0710fe4d71487c76d6b.
2009-02-05mkinitramfs: Post-Lenny cleanup.maximilian attems
no need to support callers that were unofficial and never released as such in Lenny.
2008-12-21mkinitramfs: Use cp instead of copy_exec for configs.maximilian attems
should be just a bit faster and fixes relative path for -d option. (closes: 472409)
2008-07-16mkinitramfs: only lvm2 initramfs has busybox dep.maximilian attems
thus remove warning on case of md root, closes #490875.
2008-03-16mkinitramfs: Drop gzip -9 option.maximilian attems
Doubles the speed of mkinitramfs small size loss ~ 1%. Suggested since some time by waldi and found in Ubuntu too now.
2007-09-09mkinitramfs: Add /usr/share/initramfs-tools/conf-hooks.dmaximilian attems
this allows to seperate conf files which needs to land on initramfs and those that should only be run on mkinitramfs.
2007-09-08mkinitramfs: Export MODULES, allows hook script to act accordingly.maximilian attems
this is better then passing some strange prereqs param, as the prereqs is intermixed with boot/hook scripts.
2007-08-27mkinitramfs, hooks/keymap: add trailing slash to cp destionationmaximilian attems
just make sure we really copy into a dir and not a file.
2007-08-25mkinitramfs: kill kinit.shared toomaximilian attems
2007-08-25mkinitramfs: cope when no busybox is aroundmaximilian attems
only warn on cases where we know that busybox is needed.
2007-08-16mkinitramfs: kick empty modules dirmaximilian attems
assume a s/ /\// was meant ;)
2007-06-21mkinitramfs: add patch from joeyh fixing arm bootmaximilian attems
acked by aurel32: 11:07 <aurel32> maks: I ack the fact to always add libgcc to arm, init needs libgcc1 for _Unwind_* functions
2007-06-20mkinitramfs: on wrong MODULES setting fallback to mostmaximilian attems
this setting is known to be bootable, currently we would just create an unbootable initramfs. *bad*