Welcome, Guest. Please login or register.
Did you miss your activation email?

Author Topic:  aufs boot bug  (Read 14261 times)

ian_s

  • Guest
aufs boot bug
« on: 2012/01/28, 21:45:33 »
This is only relevant to live and or perstant mode ie. fromiso, fromhd, and frugal install (poor mans install)

There is a bug in the initrd0.686 /scripts/fll script which means that the aufs boot code is not working with the siduction style squashfs file.

Using the aufs boot code should restore the previous /fll structure of /fll/aufs/ /fll/siduction/ /fll/source_drive/ directories and use aufs instead of device mapper style.

I have created a solution that works ( but because of incomplete knowledge of the deeper working of the fll script) I have only been only been able to solve by adding a force_aufs boot code which should not be unnecessary.

In what format should I post my patch, is a
"diff -Naur original/scripts/fll force_aufs/scripts/fll > force_aufs_patch.txt" style Ok.

the patch file is 40 lines long it adds 8 lines and changes 4 lines of the original fll script.

ian_s

Offline devil

  • Administrator
  • User
  • *****
  • Posts: 4.870
aufs boot bug
« Reply #1 on: 2012/01/28, 22:37:08 »
sure, thats fine.

greetz
devil

ian_s

  • Guest
aufs boot bug
« Reply #2 on: 2012/01/29, 00:30:23 »
With these changes to the fll script you can boot the siduction style squashfs must use BOTH, aufs and force_aufs boot codes.

this will boot into live siduction in aufs style there will be directories /fll/aufs /fll/siduction /fll/your-media-drive and an additional /fll/siductionforce_aufs directory which will hold the ext4 sparse siduction.686 file

As I said above I need to know how to test for the new style squashfs file from inside the fll script and then it would work properly as should be using just aufs boot code for aufs style and none or dmsetup for current style boot.


Code: [Select]

--- original/scripts/fll 2012-01-04 11:29:12.000000000 +0000
+++ force_aufs/scripts/fll 2012-01-28 15:32:03.000000000 +0000
@@ -511,6 +511,11 @@
  toram)
  FLL_TORAM="yes"
  ;;
+ force_aufs)
+ # force aufs when dm style squashfs is used (current siduction)
+ # Probably unnecessary, but haven't worked how to just test for dmstyle squashfs in script
+ FLL_FORCE_AUFS="${opt}"
+ ;;
  unionfs|aufs)
  # set FLL_UNION_MODULE in default/distro if needed
  # current default is dmsetup
@@ -809,10 +814,10 @@
  #
  # mount compressed filesystem, source directory: FLL_BLOCKMNT
  #
- mkdir -p "${FLL_MOUNTPOINT}"
- if [ -n "${FLL_UNION_MODULE}" ] && [ "${FLL_UNION_MODULE}" != "dmsetup" ] && fll_mount "${FSTYPE}" "${FLL_BLOCKMNT}/${FLL_IMAGE_LOCATION}" "${FLL_MOUNTPOINT}"; then
- printf "Mounted ${FSTYPE} filesystem on ${FLL_MOUNTPOINT}\n\n"
- FLL_DOMOVEMOUNT="${FLL_MOUNTPOINT} ${FLL_DOMOVEMOUNT}"
+ mkdir -p "${FLL_MOUNTPOINT}${FLL_FORCE_AUFS}"
+ if [ -n "${FLL_UNION_MODULE}" ] && [ "${FLL_UNION_MODULE}" != "dmsetup" ] && fll_mount "${FSTYPE}" "${FLL_BLOCKMNT}/${FLL_IMAGE_LOCATION}" "${FLL_MOUNTPOINT}${FLL_FORCE_AUFS}"; then
+ printf "Mounted ${FSTYPE} filesystem on ${FLL_MOUNTPOINT}${FLL_FORCE_AUFS}\n\n"
+ FLL_DOMOVEMOUNT="${FLL_MOUNTPOINT}${FLL_FORCE_AUFS} ${FLL_DOMOVEMOUNT}"
  elif [ -z "${FLL_UNION_MODULE}" ] || [ "${FLL_UNION_MODULE}" = "dmsetup" ]; then
  mkdir -p "${FLL_MOUNTPOINT}.mnt"
  if fll_mount "${FSTYPE}" "${FLL_BLOCKMNT}/${FLL_IMAGE_LOCATION}" "${FLL_MOUNTPOINT}.mnt" ; then
@@ -1015,6 +1020,10 @@
  #
  # union module specific options
  #
+ if [ "${FLL_FORCE_AUFS}" == "force_aufs" ] ; then
+ mkdir -p "${rootmnt}${FLL_MOUNTPOINT}"
+ mount -t ext4 "${rootmnt}${FLL_MOUNTPOINT}${FLL_FORCE_AUFS}/siduction.686" "${rootmnt}${FLL_MOUNTPOINT}"
+ fi
  case "${FLL_UNION_MODULE}" in
  aufs)
  FLL_UNION_OPTIONS="br:${FLL_UNION_COWMNTPNT}${FLL_UNION_COWDIR}:${rootmnt}${FLL_MOUNTPOINT}"




additional info - only have 32bit computer cannot test 64bit


ian_s

Offline devil

  • Administrator
  • User
  • *****
  • Posts: 4.870
aufs boot bug
« Reply #3 on: 2012/01/29, 01:47:01 »
thxx, we will look into this closer and swee what comes out.

greetz
devil

ian_s

  • Guest
aufs boot bug
« Reply #4 on: 2012/01/29, 03:46:04 »
Sorry, correction to above post left out /fll/cow should read:-


This will boot into live siduction in aufs style there will be directories /fll/aufs /fll/cow /fll/siduction /fll/your-media-drive and an additional /fll/siductionforce_aufs directory which will hold the ext4 sparse siduction.686 file

ian_s

  • Guest
aufs boot bug
« Reply #5 on: 2012/02/01, 12:09:27 »
A better combined patch that does not require extra force_aufs boot code is posted in

image_dir and image_name boot codes bug and a fix

ian_s