Refracta Development, Scripts, etc.
Post a reply
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: Refracta Installer not working

Tue Jun 04, 2013 3:32 pm

Booted into it using the grub in the mbr, ran 'update-initramfs -u' and 'update-grub' again, got to the menu for the grub that's in the partition using 'configfile' and it boots normally. If I use 'chainloader +1' it brings me to a grub command line.
dzz, can you give me the quick tutorial on what kind of logging you suggest? (a one-liner, maybe?)
dzz

- dzz
- Posts: 647
- Joined: Wed Apr 27, 2011 11:53 am
- Location: Devon, England

## Re: Refracta Installer not working

Tue Jun 04, 2013 5:09 pm

> If I use 'chainloader +1' it brings me to a grub command line

Same here.. but look at this line:

Code:
  `chroot /target /bin/bash grub-install --root-directory=/target --recheck --no-floppy --force
  `

Code:
  `man grub-install
  #snip
  --boot-directory=DIR
  install GRUB images under the directory DIR/grub instead of the
  /boot/grub directory
  `

Assuming "boot-directory" means "root-directory" (this is sid) it will do just that!
And I saw it happen, when I run the installer's grub code chunk manually. The grub files went to /target/grub! The installer's cleanup deletes that with rm -rf (watch out, that one can bite)
After running the code (as chroot) without --root-directory=/target it now chainloads to the normal menu and boots.

> can you give me the quick tutorial on what kind of logging you suggest? (a one-liner, maybe?)

Code:
  `if [ "$DEBUG" = "yes" ]; then set -x; fi`

maybe set $DEBUG (or not) in the conf file. Turn it off during the rsync else maybe a monster log
I still suspect VastOne's problem is grub* =>2.00 .. all this is another matter.
dzz

- dzz
- Posts: 647
- Joined: Wed Apr 27, 2011 11:53 am
- Location: Devon, England

## Re: Refracta Installer not working

Tue Jun 04, 2013 6:31 pm

In case it helps (I needed to do this anyway) here is a (untested as a real patch) diff of my modified installer from original:
EDIT diff updated 06/06/2013 and tested (only here and one time)

Code:
  `147a148,151
  > if [ -n "$DEBUG" ]; then
  > set -x
  > fi
  >
  149a154
  > echo -e "Starting debug log... \n"
  154c159
  < grubversion=$(dpkg -l | grep ii | grep -v doc | awk '$2 ~ "grub-[glp]" { print $2}')
  ---
  > grubversion=$(dpkg -l | grep ii |grep -v bin | grep -v doc | awk '$2 ~ "grub-[glp]" { print $2}')
  158c163
  < # function to exit the script if there are errors
  ---
  > # function to exit the script if there are errors with override option
  161,163c166,170
  < yad --title="Error" --window-icon=error \
  < --text="Exit due to error: $?
  < See $error_log for details."
  ---
  > yad --question --title="Error" --window-icon=error --button="Continue":0 --button="Exit now":1 \
  > --text="Error detected: $?
  > \nSee $error_log for details. \n\nThis may not be fatal.. Press \"Continue\" to proceed anyway"
  >
  > if [[ $? -ne 0 ]] ; then
  164a172
  > fi
  799c807
  < fi
  ---
  > fi
  915a924,930
  > if [ -n "$DEBUG" ]; then
  > # rsync might make a monster debug log, turn off logging till done
  > echo -e "\nPausing debug log for system copy.. \n"
  > set +x
  > fi
  >
  >
  933a949,954
  > if [ -n "$DEBUG" ]; then
  > set -x
  > echo -e "resuming debug log.. \n"
  > fi
  >
  >
  1164c1185
  < chroot /target /bin/bash grub-install --root-directory=/target --recheck --no-floppy --force $grub_partition
  ---
  > chroot /target /bin/bash grub-install --recheck --no-floppy --force $grub_partition
  1276a1298,1301
  >
  > # update $errorlog in the installation..
  > echo -e "\nInstallation complete.. updating log and cleaning up.. \n"
  > cp $error_log /target$error_log`

Set "$DEBUG" in the conf file.
Last edited by dzz on Thu Jun 06, 2013 12:04 am, edited 1 time in total.
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: Refracta Installer not working

Wed Jun 05, 2013 9:22 pm

Just tested again with all your changes and with grub-pc-2.00-14. First time, grub was installed to mbr, second time with grub in partition. It works fine. Unfortunately, I forgot to save the error log before rebooting into the system, so I only have the beginning part. It works using 'chainloader +1' or 'configfile /boot/grub/grub.cfg'.
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: Refracta Installer not working

Wed Jun 05, 2013 11:34 pm

Works for me in vsido. I downloaded the iso (32-bit), boot the iso in virtualbox, installed refractainstaller 9.0.8 base and gui packages using gdebi. Installed the deb for yad 0.21-something with dpkg. Then installed to hard drive using refractainstaller-yad with the above modifications and selecting the following options:
change username
change hostname
use uuid
put grub in partition
No errors during the install, no fatal errors on booting the installed system if I use 'configfile /boot/grub/grub.cfg, but if I use 'chainloader +1' it hangs at "Booting the kernel."
Here's the installer script I used. Copy it to /usr/bin/refractainstaller-yad (assuming you already installed the 9.0.8 base and gui packages first.)
https://gist.github.com/fsmithred/5717881
@dzz - the rsync output didn't show up in the error log. That's without trying to exclude it. (didn't run the patch, made manual edits.)
dzz

- dzz
- Posts: 647
- Joined: Wed Apr 27, 2011 11:53 am
- Location: Devon, England

## Re: Refracta Installer not working

Wed Jun 05, 2013 11:59 pm

> I forgot to save the error log before rebooting into the system, so I only have the beginning part

you won't, unless, at the end just before cleanup, you add:

Code:
  `cp $error_log /target$error_log`

> the rsync output didn't show up in the error log. That's without trying to exclude it. (didn't run the patch, made manual edits

good to know thet, I expected it would make the log unreadable but didn't try!
We got a good balance here, with the "basic" and "expert" options. Leaves the way open for experimentation with sid (and other distros) while keeping the "mainstream" happy too.
Anyway I updated the diff (2 posts back) after a few tweaks and another (flawless) sid snapshot test install
VastOne

- VastOne
- Posts: 9
- Joined: Wed May 29, 2013 1:52 am

## Re: Refracta Installer not working

Fri Jun 07, 2013 2:27 am

Thanks fsmithred, I will make sure I have everything you have and test it again... I appreciate it.
I apologize for my delays, a good friend of mine has been ill and I was called in to help
VastOne

- VastOne
- Posts: 9
- Joined: Wed May 29, 2013 1:52 am

## Re: Refracta Installer not working

Sat Jun 08, 2013 2:35 pm

@fsmithred
Worked with the new setup and followed exactly as you outlined in your previous post making sure I had the same files and followed this:
change username
change hostname
use uuid
put grub in partition
At user change I got the same error, but this time I noticed that it 'may be no critical'... Instead of exiting at that point like I did in the past, I proceeded/continue... I saw the same error one more time and I proceeded/continue again and the installer continued on as it should have
I am now rebooting to see if it is all correct
VastOne

- VastOne
- Posts: 9
- Joined: Wed May 29, 2013 1:52 am

## Re: Refracta Installer not working

Sat Jun 08, 2013 3:03 pm

System installed with no issues, but the user I created specifically for the install was not created
The original LiveCD user (vsido) was all that was there as a user
dzz

- dzz
- Posts: 647
- Joined: Wed Apr 27, 2011 11:53 am
- Location: Devon, England

## Re: Refracta Installer not working

Sat Jun 08, 2013 11:56 pm

> System installed with no issues, but the user I created specifically for the install was not created
> The original LiveCD user (vsido) was all that was there as a user

That was the whole idea of the full log discussed earlier, to debug anything like that (which may not actually be an installer bug but caused by some new change, a bug in sid, or system misconfiguration), if using with sid or a Debian "variant". So what do you see from the relevant bit of your full log? It should show exactly what went wrong.
Post a reply
Jump to:

Powered by phpBB © phpBB Group.

phpBB Mobile / SEO by Artodia.