Cobbler fail to edit profile kernel option

Bug #1324200 reported by Simon Monette
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Committed
Medium
Matthew Mosesohn
5.0.x
Fix Committed
Medium
Matthew Mosesohn

Bug Description

When trying to edit a ks profile with cobbler on fuel 5.0 only the first argument of the --kopts parameter is taken,
Example:

#Current setting
[root@fuel ~]# cobbler profile report --name bootstrap |grep Kernel
Kernel Options : {'url': 'http://10.20.0.2:8000/api'}

#Edit profile
[root@fuel ~]# cobbler profile edit --name bootstrap --kopts "url=http://10.20.0.2:8000/api biosdevname=0 console=ttyS0,115200"

# Profile afterward:
[root@fuel ~]# cobbler profile report --name bootstrap |grep Kernel
Kernel Options : {'url': 'http://10.20.0.2:8000/api'}

If I invert the order of the parameters, again only the first argument will be taken,
Exemple:

#Edit profile
[root@fuel ~]# cobbler profile edit --name bootstrap --kopts "console=ttyS0,115200 url=http://10.20.0.2:8000/api biosdevname=0"

# Profile afterward:
[root@fuel ~]# cobbler profile report --name bootstrap |grep Kernel
Kernel Options : {'console': 'ttyS0,115200'}

I searched the cobbler documentation and the syntax did not appear to have change since the last release.
These commands worked with Fuel 4.1.

Thank you.

description: updated
Revision history for this message
Andrew Woodward (xarses) wrote :

in 5.0 we added a field on the settings page to change the kernel options for the entire cluster so that they may be able to best suite your needs. This value can only apply after the bootstrap is complete, so may not be a good option for you.

Can you validate if you can change the setting from the cobbler web ui? https://<fuel node>/cobbler_web (cobbler:cobbler)

Revision history for this message
Andrew Woodward (xarses) wrote :

Confirmed works in 4.1 and not in 5.0

Changed in fuel:
importance: Undecided → High
status: New → Confirmed
Revision history for this message
Andrew Woodward (xarses) wrote :

Confirmed that it works correctly inside the docker container.

As a workaround do

$ dockerctl shell cobbler

and then run commands in there.

Please feel free to ping here or on IRC if you still have issues.

Changed in fuel:
importance: High → Medium
assignee: nobody → Matthew Mosesohn (raytrac3r)
Revision history for this message
Simon Monette (simon-monette) wrote :

Yes editing the profile with cobbler_web worked!

I was aware of the nice addition of the kernel options field in the setting page.
But as you pointed out it only take effect once everything is installed.

Having access to the serial port (the only I/O available on nodes) during bootstrap and the install phase helps a lot went issues occur.

Revision history for this message
Matthew Mosesohn (raytrac3r) wrote :

This is related to docker shell and the alias I added as a helper for making the transition easier. Quoting strings doesn't work with the current code:
  lxc-attach --name "$id" -- $command

It strips quotes. I need to reparse params and force-quote each parameter. It's just something we didn't catch in time for 5.0.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-library (master)

Fix proposed to branch: master
Review: https://review.openstack.org/96479

Changed in fuel:
status: Confirmed → In Progress
Changed in fuel:
milestone: none → 5.1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-library (master)

Reviewed: https://review.openstack.org/96479
Committed: https://git.openstack.org/cgit/stackforge/fuel-library/commit/?id=bafa771b4ccd9df266cc2238810b67c6cc7aa995
Submitter: Jenkins
Branch: master

commit bafa771b4ccd9df266cc2238810b67c6cc7aa995
Author: Matthew Mosesohn <email address hidden>
Date: Thu May 29 18:43:42 2014 +0400

    Fix quote handling for dockerctl shell

    Change-Id: I300af9959c89660595be37e1cecc998529ce7718
    Closes-Bug: #1324200

Changed in fuel:
status: Confirmed → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-library (stable/5.0)

Fix proposed to branch: stable/5.0
Review: https://review.openstack.org/96487

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-library (stable/5.0)

Reviewed: https://review.openstack.org/96487
Committed: https://git.openstack.org/cgit/stackforge/fuel-library/commit/?id=85167259ad73efd3eecb9ebb13eae3b25de85ad4
Submitter: Jenkins
Branch: stable/5.0

commit 85167259ad73efd3eecb9ebb13eae3b25de85ad4
Author: Matthew Mosesohn <email address hidden>
Date: Thu May 29 18:43:42 2014 +0400

    Fix quote handling for dockerctl shell

    Change-Id: I300af9959c89660595be37e1cecc998529ce7718
    Closes-Bug: #1324200
    (cherry picked from commit bafa771b4ccd9df266cc2238810b67c6cc7aa995)

Dmitry Pyzhov (dpyzhov)
no longer affects: fuel/5.1.x
Changed in fuel:
milestone: 5.0.1 → 5.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.