Guest Agent wrongly uses trove-guestagent.conf.sample directly

Bug #1176102 reported by Nikhil Manchanda
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Trove Integration
Fix Released
Low
Nikhil Manchanda

Bug Description

The guest agent should use it's own config file and not modify the sample conf and use it.

Changed in reddwarf-integration:
importance: Undecided → Medium
importance: Medium → Low
assignee: nobody → Nikhil (slicknik)
Revision history for this message
Sushil Kumar (sushil-kumar2) wrote :

I would say probably this was done as a workaround because /etc/trove-guestagent.conf was not getting created due to another bug => https://bugs.launchpad.net/trove/+bug/1265184

summary: - Guest Agent wrongly uses reddwarf-guestagent.conf.sample directly
+ Guest Agent wrongly uses trove-guestagent.conf.sample directly
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to trove-integration (master)

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

Changed in trove-integration:
assignee: Nikhil Manchanda (slicknik) → Sushil Kumar (sushil-kumar2)
status: New → In Progress
Revision history for this message
Sushil Kumar (sushil-kumar2) wrote :

As per Bug trove-guestagent uses trove-guestagent.conf.sample directly placed inside the rsync'd trove code from host.

This piece of code comes from the "trove-guest" service start-up file inside trove-integration, where the configuration file is mapped to sample file.

Now while doing a research found that code is already available in _create_server in trove.taskmanager.models, which is used to create an instance in our case, to create the file "/etc/trove-guestagent.conf" but this method was not able to work because of a false evaluating condition "if os.path.isfile(CONF.get('guest_config')):".

Problem was because guest_config was derived from "pybasedir" as '$pybasedir/etc/trove/trove-guestagent.conf.sample' in trove.common.cfg, however the correct location for the etc was the parent of pybasedir.

So to resolve the bug,

1. We need to first correct the guest_config default location, in trove, which would help taskmanager to read the conf file and send the contents to nova for guest-instantiation. (https://review.openstack.org/64539)

2. Correct the service start-up file in trove-integration to point to the built-up conf file in /etc. (https://review.openstack.org/64543)

Changed in trove-integration:
assignee: Sushil Kumar (sushil-kumar2) → Nikhil Manchanda (slicknik)
milestone: none → juno-1
Revision history for this message
Dan Nguyen (daniel-a-nguyen) wrote :

Good bug description! Thanks for filing/fixing.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to trove-integration (master)

Reviewed: https://review.openstack.org/88478
Committed: https://git.openstack.org/cgit/openstack/trove-integration/commit/?id=fd1c113d05b27217e3d3f8ef804ffc3bd58fa9ba
Submitter: Jenkins
Branch: master

commit fd1c113d05b27217e3d3f8ef804ffc3bd58fa9ba
Author: Nikhil Manchanda <email address hidden>
Date: Thu Apr 17 18:08:00 2014 -0700

    Trove guestagent should not use sample conf

    Fixed the trove guestagent to use the config file from
    /etc/trove/trove-guestagent.conf instead of using the sample
    conf from the trove/etc directory.

    Closes-bug: 1176102
    Change-Id: I7c55198d6d93f5e909c3b3d9085c08d88561f376

Changed in trove-integration:
status: In Progress → Fix Committed
Amrith Kumar (amrith)
Changed in trove-integration:
status: Fix Committed → Fix Released
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.