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

Third party coding for initramfs-tools



Hi,

I have initramfs-tools 0.60, and tried to write a 3rd party script for
it.
It's actually quite simple:
----------------------------------------------------------------------------
gandalf:~$ cat /etc/mkinitramfs/scripts/local-bottom/copypwd 
#!/bin/sh

mount -no remount,rw ${rootmnt}
# Not totally certain if it's needed but I got a RO error once
sleep 1
cat /.cppwd > ${rootmnt}/.cppwd
mount -no remount,ro ${rootmnt}
----------------------------------------------------------------------------

Unfortunately, I lost hours of debugging and rebooting because the initrd
would die in reduce_prereqs with
panic "PANIC: Circular dependancy.  Exiting."
BTW, it's "dependency"

count_unsatisfied would parse the output of my copypwd script, see one
line of output, within with i=1, and die on 1 -eq 1

I have no idea why my script seems to go through some module loading
dependency checker, but it's very counter intuitive that if my script
outputs anything, it gets picked up by reduce_prereqs and kills the boot
entirely.

My stuff works now because I spend hours of tracking this problem down
and removed the 'echo "I'm here"' in my script, but if this could be
readily documented, or even better, if third party scripts could output 
things without killing the whole boot in some weird way, that would be
appreciated :)

Thanks
Marc
-- 
"A mouse is a device used to point at the xterm you want to type in" - A.S.R.
Microsoft is to operating systems & security ....
                                      .... what McDonalds is to gourmet cooking
Home page: http://marc.merlins.org/



Reply to: