Project

General

Profile

Actions

Bug #10740

closed

Audits created during DB migration of ptables to templates

Added by Dominic Cleal almost 9 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
DB migrations
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

When migrating over #7096, audits are created due to the update of ptable_id on hosts and host groups.

2015-06-09T14:47:28 [sql] [I] Migrating to MigratePtablesToTemplates (20150514114044)
-- migrating partition table Kickstart default
...
2015-06-09T14:47:30 [sql] [D]   Host::Managed Load (0.2ms)  SELECT "hosts".* FROM "hosts" WHERE "hosts"."type" IN ('Host::Managed') AND "hosts"."id" = 168 LIMIT 1
2015-06-09T14:47:30 [sql] [D]    (0.1ms)  SELECT MAX("audits"."version") AS max_id FROM "audits" WHERE "audits"."auditable_id" = 168 AND "audits"."auditable_type" = 'Host'
2015-06-09T14:47:30 [sql] [D]   SQL (0.3ms)  INSERT INTO "audits" ("action", "associated_id", "associated_name", "associated_type", "auditable_id", "auditable_name", "auditable_type", "audited_changes", "comment", "created_at", "remote_address", "request_uuid", "user_id",
 "user_type", "username", "version") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)  [["action", "update"], ["associated_id", nil], ["associated_name", nil], ["associated_type", nil], ["auditable_id", 168], ["auditable_name", "test.example.com"], ["auditable_type
", "Host"], ["audited_changes", "---\nptable_id:\n- 12\n- 86\n"], ["comment", nil], ["created_at", Tue, 09 Jun 2015 13:47:30 UTC +00:00], ["remote_address", nil], ["request_uuid", nil], ["user_id", nil], ["user_type", nil], ["username", nil], ["version", 7]]

Related issues 2 (0 open2 closed)

Related to Foreman - Feature #7096: Partition Tables should just be a kind of Provisioning TemplatesClosedMarek Hulán08/14/2014Actions
Related to Foreman - Bug #14965: Migration error in foreman_bootdisk upgrading from 6.1 to 6.2ClosedMartin Bacovsky05/09/2016Actions
Actions

Also available in: Atom PDF