Bug 1076066 - [GSS] (6.3.0) Can't promote --backup slave HC to master and reload without moving domain.cached-remote.xml
Summary: [GSS] (6.3.0) Can't promote --backup slave HC to master and reload without mo...
Alias: None
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: Domain Management
Version: 6.2.2
Hardware: Unspecified
OS: Unspecified
Target Milestone: DR5
: EAP 6.3.0
Assignee: Brian Stansberry
QA Contact: Petr Kremensky
Russell Dickenson
Depends On:
Blocks: 1082478
TreeView+ depends on / blocked
Reported: 2014-03-13 13:08 UTC by Brian Stansberry
Modified: 2018-12-04 17:46 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
In previous versions of JBoss EAP 6, a bug prevented a slave Host Controller that has been reconfigured to act as Master from loading the cached domain configuration upon restart. This was because the newly promoted Master loads the configuration from the 'domain/configuration/domain.xml' file instead of the 'domain/configuration/domain.cached-remote.xml' file. In this release of the product, if a slave HostController started with the `--backup` option is reconfigured to act as master and is then reloaded to pick up that change, the 'domain.cached-remote.xml' file it was maintaining when running as a backup will automatically be detected and used.
Clone Of:
: 1082478 (view as bug list)
Last Closed: 2014-06-28 15:43:28 UTC
Type: Bug

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat One Jira Issue Tracker WFLY-3108 Major Closed Can't promote --backup slave HC to master and reload without moving domain.cached-remote.xml 2018-03-30 05:41:54 UTC

Description Brian Stansberry 2014-03-13 13:08:53 UTC
Description of problem:

The prescribed method for promoting a slave HostController to act as the master fails unless a file named domain.xml with the correct content exists in the slave's domain/configuration dir.

How reproducible:

Always, unless extra steps are taken.

Steps to Reproduce:
1. Start the slave with --backup so a local copy of the domain config is maintained (in file domain.cached-remote.xml).
2. Stop the existing master.
3. Use the cli to connect to the slave
4. /host=<slavename>:write-local-domain-controller
5. reload --host=<slavename>

Actual results:

If there is no domain/configuration/domain.xml file on the slave HC system, the following error occurs:

2014-03-13 09:54:04,829 ERROR [org.jboss.as.host.controller] (Controller Boot Thread) JBAS010932: Caught exception during boot: org.jboss.as.controller.persistence.ConfigurationPersistenceException: JBAS014676: Failed to parse configuration
at org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:112) [wildfly-controller-8.0.1.Final-SNAPSHOT.jar:8.0.1.Final-SNAPSHOT]
at org.jboss.as.host.controller.DomainModelControllerService.boot(DomainModelControllerService.java:514) [wildfly-host-controller-8.0.1.Final-SNAPSHOT.jar:8.0.1.Final-SNAPSHOT]
at org.jboss.as.controller.AbstractControllerService$1.run(AbstractControllerService.java:256) [wildfly-controller-8.0.1.Final-SNAPSHOT.jar:8.0.1.Final-SNAPSHOT]
at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_45]
Caused by: java.io.FileNotFoundException: /Users/bstansberry/tmp/WF801/slave/domain/configuration/domain.xml (No such file or directory)
at java.io.FileInputStream.open(Native Method) [rt.jar:1.7.0_45]
at java.io.FileInputStream.<init>(FileInputStream.java:146) [rt.jar:1.7.0_45]
at org.jboss.as.controller.persistence.XmlConfigurationPersister.load(XmlConfigurationPersister.java:100) [wildfly-controller-8.0.1.Final-SNAPSHOT.jar:8.0.1.Final-SNAPSHOT]
... 3 more

(The above stack trace is from WildFly, but EAP has the same thing.)

OR:, if a domain.xml file exists but does not reflect the current domain config (e.g. it's the original file we shipped) then the slave HC will end up incorrectly adopting that config. 

Expected results:

Additional info:

Comment 3 Petr Kremensky 2014-03-24 09:50:40 UTC
Verified on EAP 6.3.0.DR5.

Both cases are now working (no domain.xml on slave, domain.xml on slave doesn't reflect current domain configuration).

Comment 7 Scott Mumford 2014-05-14 02:27:32 UTC
Refactored release note text to publishable format.

Note You need to log in before you can comment on or make changes to this bug.