Page 42 of 94 FirstFirst ... 3240414243445292 ... LastLast
Results 411 to 420 of 931

Thread: Grub 2 Basics

  1. #411
    Join Date
    Oct 2008
    Location
    ExodusHair<Čubura
    Beans
    3,880
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: Grub 2 Basics

    Quote Originally Posted by cmcginty View Post
    I fixed this by removing the /boot/grub/grubenv file.
    man grub-editenv

  2. #412
    Join Date
    Nov 2009
    Beans
    4

    Re: Grub 2 Basics

    That worked! Gee if they could have just put that in there in the first place I wouldn't have to rant about it! Thanks again. Next I'll be exploring the graphical aspect of grub2.

    Quote Originally Posted by drs305 View Post
    I am the first to agree that the "saved" function could only be designed by geeks.

    As I understand it, "GRUB_DEFAULT=saved" only enables two commands to work: grub-set-default and "grub-reboot".

    To get the last selected OS to be 'saved' and used on future boots, you have to use "GRUB_SAVEDEFAULT=true".

    Have you tried that second setting?

    Glad you like the guide.

  3. #413
    Join Date
    Apr 2010
    Beans
    1

    Re: Grub 2 Basics

    Nice guide, overengineered software. I will kill the xxxxxxx Koala and install Debian instead tonight. Grub2! Not even the man pages are correct.

    /Sid

  4. #414
    Join Date
    Dec 2006
    Beans
    78

    Re: Grub 2 Basics

    see below
    Last edited by cmcginty; April 6th, 2010 at 04:08 AM.

  5. #415
    Join Date
    Dec 2006
    Beans
    78

    Exclamation Re: Grub 2 Basics

    Quote Originally Posted by cmcginty View Post
    Hi, this bug is still biting me. How can I prevent grub2 from writing to my partitions that are supposed to be read-only. I know grub2 is trying to do the "smart" thing here. But there should be some way to disable this.
    Quote Originally Posted by zika View Post
    man grub-editenv
    Zika, I don't see how grub-editenv will stop grub from writing to the partition. Is there a variable that will prevent this?

  6. #416
    Join Date
    Jun 2008
    Beans
    65

    Re: Grub 2 Basics

    I've got the resolution to work. I've also edited the 05_debian_theme correctly (update-grub finds the correct image file) however the image still does not appear for me. I was wondering if "use_bg = false" should be "use_bg = true" because right now both instances that call "use_bg =" is "use_bg = true" I was wondering if that messed up the loops within the code.

    Edit: Just tried it after setting the first "use_bg = true" to "use_bg = false". This is the one right before the for loop where we enter the image file name and directory. No dice. I don't think its the "use_bg"
    Last edited by ghostier; April 6th, 2010 at 07:29 AM.

  7. #417
    Join Date
    Aug 2008
    Location
    South East Montana
    Beans
    6,153

    Re: Grub 2 Basics

    Quote Originally Posted by ghostier View Post
    I've got the resolution to work. I've also edited the 05_debian_theme correctly (update-grub finds the correct image file) however the image still does not appear for me. I was wondering if "use_bg = false" should be "use_bg = true" because right now both instances that call "use_bg =" is "use_bg = true" I was wondering if that messed up the loops within the code.

    Edit: Just tried it after setting the first "use_bg = true" to "use_bg = false". This is the one right before the for loop where we enter the image file name and directory. No dice. I don't think its the "use_bg"
    Mine works fine like this:
    Code:
    #!/bin/bash -e
    
    source /usr/lib/grub/grub-mkconfig_lib
    
    # this allows desktop-base to override our settings
    f=/usr/share/desktop-base/grub_background.sh
    if test -e ${f} ; then
      source ${f}
    else
      WALLPAPER="/usr/share/images/desktop-base/menu.png"
      COLOR_NORMAL="white/black"
      COLOR_HIGHLIGHT="black/white"
    fi
    
    set_mono_theme()
    {
      cat << EOF
    set menu_color_normal=black/black
    set menu_color_highlight=red/white
    EOF
    }
    
    # check for usable backgrounds
    use_bg=false
    if [ "$GRUB_TERMINAL_OUTPUT" = "gfxterm" ] ; then
      for i in /boot/grub/`basename ${WALLPAPER}` ${WALLPAPER} ; do
        if is_path_readable_by_grub $i ; then 
          bg=$i
          case ${bg} in
            *.png)        reader=png ;;
            *.tga)        reader=tga ;;
            *.jpg|*.jpeg)    reader=jpeg ;;
          esac
          if test -e /boot/grub/${reader}.mod ; then
            echo "Found background image: `basename ${bg}`" >&2
            use_bg=true
            break
          fi
        fi
      done
    fi
    
    # set the background if possible
    if ${use_bg} ; then
      prepare_grub_to_access_device `${grub_probe} --target=device ${bg}`
      cat << EOF
    insmod ${reader}
    if background_image `make_system_path_relative_to_its_root ${bg}` ; then
      set color_normal=${COLOR_NORMAL}
      set color_highlight=${COLOR_HIGHLIGHT}
    else
    EOF
    fi
    
    # otherwise, set a monochromatic theme for Ubuntu
    if ${use_bg} ; then
      set_mono_theme | sed -e "s/^/  /g"
      echo "fi"
    else
      set_mono_theme
    fi
    I am wondering if you downloaded the images package and if that is screwing with it. The default file is /usr/share/images/desktop-base (there is a package called desktop-base that will give you the image called for by default if you like people to think that you are booting Debian).

    I believe the "bg=false" is in reference to not finding the image.

    If you have the images package installed leave the selected image in the .../images/grub file but copy it to the .../images/desktop-base file too.

    I had to do that early on in 9.10-testing but I thought that was ironed out back then. Might be worth a try.

    I never liked the images anyway so I edit my own with gimp and just put them in the desktop-base file with, as you can see, complex names.
    Dell 480 XPS 3G ram Quad Core 2.40GHz, Radeon HD 2400 PRO, Audigy1, 3x320G HDD, 320G External, Debian Testing for use, Debian Squeeze for secure use, Debian Sid for FUN

  8. #418
    Join Date
    Jun 2008
    Beans
    65

    Re: Grub 2 Basics

    hmm I dont think moving the images from 05_debian_theme installation will be useful because I am using my own images which I've put in both folders. Just tried your code and edited your image path to my own, updated grub, terminal says it found the image then reboot to check but still monochrome. =/

    EDIT: Just took a closer look at your code. "f=/usr/share/desktop-base/grub_background.sh" from line 6 caught my eye. I don't have such directory. What is that path for? In fact, I just searched my file system for grub_background.sh and couldn't find it.
    Last edited by ghostier; April 6th, 2010 at 08:11 AM.

  9. #419
    Join Date
    Aug 2008
    Location
    South East Montana
    Beans
    6,153

    Re: Grub 2 Basics

    I am headed to bed and am not on that platform now. I will see where that bugger is tomorrow.
    Dell 480 XPS 3G ram Quad Core 2.40GHz, Radeon HD 2400 PRO, Audigy1, 3x320G HDD, 320G External, Debian Testing for use, Debian Squeeze for secure use, Debian Sid for FUN

  10. #420
    Join Date
    Jan 2007
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Grub 2 Basics

    Quote Originally Posted by ghostier View Post
    EDIT: Just took a closer look at your code. "f=/usr/share/desktop-base/grub_background.sh" from line 6 caught my eye. I don't have such directory. What is that path for? In fact, I just searched my file system for grub_background.sh and couldn't find it.
    In the default G2 install, the path is "/usr/share/images/desktop-base/" and there is no "grub_background.sh" file.

    Since G2 is now finding your image, it might be time for you to post your 05_debian_theme and /etc/default/grub files for us to see if we can find the problem.
    GRUB2

    Retired.

Page 42 of 94 FirstFirst ... 3240414243445292 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •