Page 1 of 1

Hide the Grub Menu

Posted: Mon Mar 17, 2008 9:44 am
by SpudGun
I'm about to dual boot my home pc with xp/ mint, but i can only do it if i can hide the grub menu, i'm able to do this with ubuntu, but cant seem to work it out in mint, can anyone help? :mrgreen:

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 9:52 am
by lakehousetech
Why can't you boot XP from GRUB? No need to hide anything.

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 10:00 am
by SpudGun
I will be, but grub needs to be hidden from the wife, so she thinks its just an xp pc. :|

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 10:14 am
by SpudGun
If i get caught messing with linux she would want to know how i get time to do it, then i would be in the poo :oops:
Ive done it many times with ubuntu, thats easy to hide. :roll:

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 10:23 am
by linuxviolin
Edit as root /boot/grub/menu.lst and you will see a line like this:

Code: Select all

## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
#hiddenmenu
Remove the '#' before 'hiddenmenu' like this:

Code: Select all

## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
hiddenmenu
et voila[/i] :wink:

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 10:29 am
by SpudGun
Thats the bit i'm looking for, but its not in the mint grub. :shock:

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 10:35 am
by linuxviolin
Maybe you can post your menu.lst?

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 10:43 am
by SpudGun
# menu.lst - See: grub(8), info grub, update-grub(8)
# grub-install(8), grub-floppy(8),
# grub-md5-crypt, /usr/share/doc/grub
# and /usr/share/doc/grub-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
default 0

gfxmenu=/etc/grub/message.mint

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout 10

# Pretty colours
color cyan/blue white/blue

## password ['--md5'] passwd
# If used in the first section of a menu file, disable all interactive editing
# control (menu entry editor and command-line) and entries protected by the
# command 'lock'
# e.g. password topsecret
# password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/
# password topsecret

#
# examples
#
# title Windows 95/98/NT/2000
# root (hd0,0)
# makeactive
# chainloader +1
#
# title Linux
# root (hd0,1)
# kernel /vmlinuz root=/dev/hda2 ro
#

#
# Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST

### BEGIN AUTOMAGIC KERNELS LIST
## lines between the AUTOMAGIC KERNELS LIST markers will be modified
## by the debian update-grub script except for the default options below

## DO NOT UNCOMMENT THEM, Just edit them to your needs

## ## Start Default Options ##
## default kernel options
## default kernel options for automagic boot options
## If you want special options for specific kernels use kopt_x_y_z
## where x.y.z is kernel version. Minor versions can be omitted.
## e.g. kopt=root=/dev/hda1 ro
## kopt_2_6_8=root=/dev/hdc1 ro
## kopt_2_6_8_2_686=root=/dev/hdc2 ro
# kopt=root=/dev/hdb1 ro

## default grub root device
## e.g. groot=(hd0,0)
# groot=(hd1,0)

## should update-grub create alternative automagic boot options
## e.g. alternative=true
## alternative=false
# alternative=true

## should update-grub lock alternative automagic boot options
## e.g. lockalternative=true
## lockalternative=false
# lockalternative=false

## additional options to use with the default boot option, but not with the
## alternatives
## e.g. defoptions=vga=791 resume=/dev/hda5
# defoptions=quiet splash

## altoption boot targets option
## multiple altoptions lines are allowed
## e.g. altoptions=(extra menu suffix) extra boot options
## altoptions=(recovery mode) single
# altoptions=(recovery mode) single

## controls how many kernels should be put into the menu.lst
## only counts the first occurence of a kernel, not the
## alternative kernel options
## e.g. howmany=all
## howmany=7
# howmany=all

## should update-grub create memtest86 boot option
## e.g. memtest86=true
## memtest86=false
# memtest86=true

## ## End Default Options ##

title Linux Mint, kernel 2.6.22-14-generic
root (hd1,0)
kernel /boot/vmlinuz-2.6.22-14-generic root=/dev/hdb1 ro quiet splash
initrd /boot/initrd.img-2.6.22-14-generic
boot

title Linux Mint, kernel 2.6.22-14-generic (recovery mode)
root (hd1,0)
kernel /boot/vmlinuz-2.6.22-14-generic root=/dev/hdb1 ro single
initrd /boot/initrd.img-2.6.22-14-generic
boot

title Linux Mint, kernel memtest86+
root (hd1,0)
kernel /boot/memtest86+.bin
boot

### END DEBIAN AUTOMAGIC KERNELS LIST

# This is a divider, added to separate the menu items below from the Debian
# ones.
title Other operating systems:
root


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/hda1.
title Ubuntu 7.10, kernel 2.6.22-14-generic (on /dev/hda1)
root (hd0,0)
kernel /boot/vmlinuz-2.6.22-14-generic root=UUID=f9204293-71ab-413b-9742-9f8649f4d807 ro
initrd /boot/initrd.img-2.6.22-14-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/hda1.
title Ubuntu 7.10, kernel 2.6.22-14-generic (recovery mode) (on /dev/hda1)
root (hd0,0)
kernel /boot/vmlinuz-2.6.22-14-generic root=UUID=f9204293-71ab-413b-9742-9f8649f4d807 ro single
initrd /boot/initrd.img-2.6.22-14-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/hda1.
title Ubuntu 7.10, memtest86+ (on /dev/hda1)
root (hd0,0)
kernel /boot/memtest86+.bin
savedefault
boot

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 11:29 am
by linuxviolin
I'm always with Cassandra (Mint 3.0) and I have no GFXGrub but my menu.lst is like this:
## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout 9

## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
#hiddenmenu

# Pretty colours
#color cyan/blue white/blue
etc....

A 'stupid' question, what about copy and paste the line? :roll:

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 11:40 am
by Fred
To go along with linuxviolin's comment, you may need to comment out the gfxgrub line also.

Fred

Re: Hide the Grub Menu

Posted: Mon Mar 17, 2008 11:45 am
by SpudGun
Thanks guys, i've run out of time now (i'm at work) i'll give it a go tomorrow morning and let you know what happens.

Re: Hide the Grub Menu

Posted: Tue Mar 18, 2008 4:21 am
by SpudGun
Job done :D It worked, thank you for your help, i'll past the changes i made below.
-------------------------------------------------------------------------------------------------------




# menu.lst - See: grub(8), info grub, update-grub(8)
# grub-install(8), grub-floppy(8),
# grub-md5-crypt, /usr/share/doc/grub
# and /usr/share/doc/grub-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
default 0

#gfxmenu=/etc/grub/message.mint

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout 3

## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
hiddenmenu

# Pretty colours
#color cyan/blue white/blue

Re: Hide the Grub Menu

Posted: Tue Mar 18, 2008 4:24 am
by SpudGun
I can now be a secret mint user at home, without getting my arse kicked. :lol:

Re: Hide the Grub Menu

Posted: Thu Mar 20, 2008 6:35 pm
by linuxviolin
Happy to have helped. :D

But
"if you're running a recent distro which is using a recent X.Org, you might have an automatically-generated xorg.conf file as dumb as this one:

Code: Select all

Section "InputDevice"
	Identifier	"Generic Keyboard"
	Driver		"kbd"
	Option		"XkbRules"	"xorg"
	Option		"XkbModel"	"pc105"
	Option		"XkbLayout"	"us"
EndSection

Section "InputDevice"
	Identifier	"Configured Mouse"
	Driver		"mouse"
EndSection

Section "Device"
	Identifier	"Configured Video Device"
EndSection

Section "Monitor"
	Identifier	"Configured Monitor"
EndSection

Section "Screen"
	Identifier	"Default Screen"
	Monitor		"Configured Monitor"
	Device		"Configured Video Device"
EndSection
Except for the keyboard layout, can you see anything of relevance here?

No, because there is no actual information in this file, except for the keyboard!"
So if you have a problem or if you want customize something you must manually hack the practically-empty xorg.conf file! This is not a 'nice' [joke] regression on the "normal", traditional, "classical" xorg.conf? :twisted:

For some additional information you can look here for example.