Re: [packer] grub config being overwritten when starting an image created with packer (Openstack/Packer/CentOS)

17 views
Skip to first unread message
Message has been deleted

Rickard von Essen

unread,
Aug 29, 2019, 5:57:28 PM8/29/19
to packe...@googlegroups.com
Could you provide some more details? What's the underlying virtualization system? Is this PV or HVM VM's? Etc 

On Thu, Aug 29, 2019, 19:34 Matt Faraday <matt.f...@gmail.com> wrote:
Hi All,

I'm facing a strange issue, where I've modified /etc/default/grub in my image to change GRUB_CMDLINE_LINUX to add some extra flags. If I do this to an already running instance, it's fine, a reboot and the changes persist.

I'm creating images using packer, and if I make this change when creating an image, when the instance starts those changes are not there, despite packer making the change and then creating the image.

Any idea what is over-writing this ? Can't seem to find any info online, and other people suggest making changes to the kernel boot parameters in the same way as I'm doing. I am also running grub2-mkconfig -o /boot/grub2/grub.cfg as well after making the change.

OS is CentOS 7.

Example output from packer (it does a cat /etc/default/grub for me to show what it is)

[0;32m openstack: GRUB_TIMEOUT=1 [0m
[0;32m openstack: GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)" [0m
[0;32m openstack: GRUB_DEFAULT=saved [0m
[0;32m openstack: GRUB_DISABLE_SUBMENU=true [0m
[0;32m openstack: GRUB_TERMINAL="serial console" [0m
[0;32m openstack: GRUB_SERIAL_COMMAND="serial --speed=115200" [0m
[0;32m openstack: GRUB_CMDLINE_LINUX="console=tty0 crashkernel=auto console=ttyS0,115200 net.ifnames=0 biosdevname=0 audit=1"

but after starting the image ....

[root@kernel4-nic-test-2471ee92 cloud]# cat /etc/default/grub

GRUB_TIMEOUT=1
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
GRUB_DEFAULT=saved
GRUB_DISABLE_SUBMENU=true
GRUB_TERMINAL="serial console"
GRUB_SERIAL_COMMAND="serial --speed=115200"
GRUB_CMDLINE_LINUX="console=tty0 crashkernel=auto console=ttyS0,115200"


Does anyone know what is overwriting this ? 

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/packer/issues
IRC: #packer-tool on Freenode
---
You received this message because you are subscribed to the Google Groups "Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/packer-tool/ad7247f8-3b6f-482e-864b-8d165be39933%40googlegroups.com.
Message has been deleted

Rickard von Essen

unread,
Sep 4, 2019, 4:34:05 PM9/4/19
to packe...@googlegroups.com
So my question was if you are using PV (para-virtualized) or HVM (hardware assisted virtualization).

(and you can run OpenStack with many different underlying virtualization systems). 

On Fri, Aug 30, 2019, 11:38 Matt Faraday <matt.f...@gmail.com> wrote:
Hi

It's openstack, so KVM.
These are VMs.



On Thursday, 29 August 2019 22:57:28 UTC+1, Rickard von Essen wrote:
Could you provide some more details? What's the underlying virtualization system? Is this PV or HVM VM's? Etc 

To unsubscribe from this group and stop receiving emails from it, send an email to packe...@googlegroups.com.

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/packer/issues
IRC: #packer-tool on Freenode
---
You received this message because you are subscribed to the Google Groups "Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages