Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I want to change the menu on a Suse 12 Enterprise system.
I edit the /etc/default zip12grub.conf file execure grug2-mkconfig. Then reboot the system and no changes occur. The zip12grub.conf seems like the correct file to update so I am at a loss as to what the correct process would be.
cat zipl2grub.conf
## This is the template for '@zipldir@/config' and is subject to
## rpm's %config file handling in case of grub2-s390x-emu package update.
Generating grub configuration file ...
Found linux image: /boot/image-3.12.39-47-default
Found initrd image: /boot/initrd-3.12.39-47-default
Found linux image: /boot/image-3.12.28-4-default
Found initrd image: /boot/initrd-3.12.28-4-default
done
reboot
Storage cleared - system reset.
zIPL v1.24.1-38.17 interactive boot menu
0. default (grub2)
1. grub2
2. skip-grub2
Note: VM users please use '#cp vi vmsg <input> <kernel-parameters>'
Please choose (default will boot in 16 seconds):
Booting default (grub2)
Thank you for you reply.
The menu item Iwant to change is as follows:
[test-grub2]
target = @zipldir@
ramdisk = @zipldir@/initrd,0x2000000
image = @zipldir@/image
parameters = "root=@GRUB_DEVICE@ @GRUB_CONMODE@ @GRUB_CMDLINE_LINUX@ @GRUB_CMDLINE_LINUX_DEFAULT@ "
3 = test menu grub2
I did not obtain a third menu item.
I tried these commands update-grub, update-grub2, grub-update, or grub2-update do not appear to exist. I did not find any reference to grub update commands in the Suse Administration Guide. It states to use grub2-mkconfig to update the main configuration file.
Perhaps the OP had better be more forthcoming.
That looks like the grub2 replacement for zipl - that means zLinux on system z hardware. I haven't had the opportunity to look into that, so if that is the case, I see 2 options:
i) talk to Suse for some decent doco (post a link if you get one pls) ii) go back to zipl
Edit: looks like Suse have done their normal trick, and more or less forced yast on you.
I made some progrees using mkconfig and grub2-zipl-setup. I have not found any documentation for grub2-zipl-setup but it appears to help.
My plan is to first update grub to include a new boot selection using address 15c1. I can boot off 15c1 and I now have a menu option. However, it will still attempt to use ccw-0.0.15c0-part3. I review the results in file /boot/zipl/config/after executing grub2-zipl-setup. It shows root=/dev/disk/by-path/ccw-0.0.15c0-part3 and not root=/dev/disk/by-path/ccw-0.0.15c1-part3.
Modifing /etc/default/zipl2grub.conf.in and /etc/default/grub provides a new menu selection but does not change the root= to device 15c1.
tried updating parameters= to include root=/dev/disk/by-path/ccw-0.0.15c1-part3 but only appends this information to parameters=.
The problem I am having is how does the root= get updated so I can change it to /dev/disk/by-path/ccw-0.0.15c1-part3!
I looked at grub2-install and tried grub2-install 15c1 and this did not work.
Listings:
cat zipl2grub.conf.in
## This is the template for '@zipldir@/config' and is subject to
## rpm's %config file handling in case of grub2-s390x-emu package update.
cat grub
# Modified by YaST2. Last modification on Fri Jan 23 15:29:43 EST 2015
# THIS FILE WILL BE PARTIALLY OVERWRITTEN by perl-Bootloader
# For the new kernel it try to figure out old parameters. In case we are not able to recognize it (e.g. change of flavor or strange install order ) it it use as fallback installation parameters from /etc/sysconfig/bootloader
# If you change this file, run 'grub2-mkconfig -o /boot/grub2/grub.cfg' afterwards to update
# /boot/grub2/grub.cfg.
GRUB_DISTRIBUTOR=SLES12
GRUB_DEFAULT=saved
GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=8
GRUB_CMDLINE_LINUX_DEFAULT=" hvc_iucv=8 TERM=dumb resume=/dev/disk/by-path/ccw-0.0.15c0-part2 crashkernel=204M-:102M cio_ignore=all,!ipldev,!condev"
# kernel command line options for failsafe mode
GRUB_CMDLINE_LINUX_RECOVERY="hvc_iucv=8 TERM=dumb noresume x11failsafe crashkernel=204M-:102M"
GRUB_CMDLINE_LINUX_TEST=" hvc_iucv=8 TERM=dumb resume=/dev/disk/by-path/ccw-0.0.15c1-part2 crashkernel=204M-:102M cio_ignore=all,!ipldev,!condev"
GRUB_CMDLINE_LINUX=""
# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM=0x01234567,0xfefefefe,0x89abcdef,0xefefefef
# Uncomment to disable graphical terminal (grub-pc only)
GRUB_TERMINAL=console
# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
GRUB_GFXMODE=auto
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux -- > Also tried with this option enabled!
#GRUB_DISABLE_LINUX_UUID=true
# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_LINUX_RECOVERY=true
# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"
# Skip 30_os-prober if you experienced very slow in probing them
# WARNING foregin OS menu entries will be lost if set true here
GRUB_DISABLE_OS_PROBER=true
# Set to 'y' for grub to be installed on an encrypted partition
GRUB_ENABLE_CRYPTODISK=n
SUSE_BTRFS_SNAPSHOT_BOOTING=true
GRUB_CMDLINE_XEN_DEFAULT="crashkernel=204M-:102M"
Results:
cat config
## This file was written by 'grub2-install/grub2-zipl-setup'
## filling '/etc/default/zipl2grub.conf.in' as template
## with values from '/etc/default/grub'.
## In-place modifications will eventually go missing!
I think I got things working but not seemless. I update /etc/fstab to use the new changed device address. Executed grub2-zipl-setup, grub2-mkconfig -o /boot/grub2/grub.cfg and finally mkinitrd. Not sure why mkinitrd was needed because I would have expected grub2-mkconfig to do this. To use the original address I update /etc/fstab and execute the three commands and performed earlier.
I thank everyone for their replys.
My stategy was to first create process with a new menu item with the changed IPL address. Then create the process just to update the address of the IPL volume. I was able to do this but I believe I have uncovered a couple of defects.
The change with the menu process involved changing the /etc/default/zipl2grub.conf.in, /etc/fstab, and
/etc/default/grub files. Update the bootloader and execute the grub2-zipl-setup, grub2-mkconfig and
mkinitrd commands.
The ipl address change process was much simpler. Update /etc/fstab and the bootloader then execute
the grub2-zipl-setup, grub2-mkconfig and mkinitrd commands.
The first defect is documentation for the command grub2-zipl-setup. I could not find any reference to
grub2-zipl-setup documentation. There is no zipl.conf file and this command is the replacement for the
zipl command on Suse 12. It needs to be documented.
The second is the command grub2-mkconfig. does not work as I expect it to work After using this
command I am still unable to successfully ipl a system using the grub2 menu. I am forced to bypass
this menu to successfully ipl. I can successfully ipl a system using the grub2 menu after I execute the
mkinitrd command. I believe the grub2-mkconfig command is a replacement on Suse 12 for the
mkinitrd command and should not be required on Suse 12.
I could have mis-interpreted this ipl address change process so I would greatly appreciate all reviews,
questions, and opinions on this matter.
Do you think that something may have went wrong while running 'grub2-mkconfig' and may have left you with a corrupt config file?
I looked and couldn't find any documentation on grub2-zipl setup either.
The mkinitrd cmd creates initial ramdisk images for the preloaded modules.
The grub2-mkconfig cmd should create a new configuration based on the currently running system
(what's found in/boot)
You may be right that grub2-mkconfig is the replacement for the other (mkinitrd).
The dracut world is/has taken the place of mkinitrd to generate new initrd/initramfs files for boot; this is tangentially connected to grub due to 2 new features, hostonly and dracut_rescue_image. http://initrd.org/wiki/Grub_2_Tips_%26_Tricks
Not sure if the /boot/grub2/grub.cfg or /boot/zipl/config files were corrupted. They appeared to be what I expected. I am able to replace the entire system back to the initial setup so if there is corruption it is from one of the commands and not from prior attempts to find a process. So I strongly suspect that grub2-mkconfig is not doing everything it needs to do. Thank you to everyone who replied.
Not sure if the /boot/grub2/grub.cfg or /boot/zipl/config files were corrupted. They appeared to be what I expected. I am able to replace the entire system back to the initial setup so if there is corruption it is from one of the commands and not from prior attempts to find a process. So I strongly suspect that grub2-mkconfig is not doing everything it needs to do. Thank you to everyone who replied.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.