Bug 1152965
| Summary: | Updating JBoss ON to 3.2.3 throws an exception: "Failed to resolve host '127.0.0.1 10.33.63.237': Failed to create URI" | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [JBoss] JBoss Operations Network | Reporter: | bkramer <bkramer> | ||||
| Component: | Installer, Launch Scripts, Upgrade | Assignee: | Michael Burman <miburman> | ||||
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Filip Brychta <fbrychta> | ||||
| Severity: | urgent | Docs Contact: | |||||
| Priority: | high | ||||||
| Version: | JON 3.2.3 | CC: | fbrychta, loleary, lzoubek, miburman, vladimir.manolov | ||||
| Target Milestone: | CR01 | ||||||
| Target Release: | JON 3.3.1 | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2015-02-27 19:58:15 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Attachments: |
|
||||||
This is because the apply-updates script is not parsing the bind address from rhq-server.properties correctly:
This is very bad:
JBOSS_BIND_ADDRESS=`grep "jboss.bind.address.management" "$INSTALL_PATCH_HOME"/bin/rhq-server.properties | cut -d'=' -f 2`
This would match
jboss.bind.address.management=blah,
# jboss.bind.address.management needs to be set
# Please set jboss.bind.address.management to something
#jboss.bind.address.management=127.0.0.1
The result will be multiple lines and values being assigned to JBOSS_BIND_ADDRESS.
This should do the work:
JBOSS_BIND_ADDRESS=`awk -F\= '/^jboss.bind.address.management/ {print $2}' rhq-server.properties`
Tested on Linux and SunOS 5.11.
Moving into CR01 target milestone as missed ER01 cutoff. Created attachment 985583 [details]
Add caret to the beginning of the grep command
Moving to ON_QA as available to test with latest CP build: http://download.devel.redhat.com/brewroot/packages/org.jboss.on-jboss-on-parent/3.3.0.GA/16/maven/org/jboss/on/jon-server-patch/3.3.0.GA/jon-server-patch-3.3.0.GA.zip *Note: jon-server-patch-3.3.0.GA.zip maps to CR01 build of jon-server-3.3.0.GA-update-01.zip. Verified on Version : 3.3.0.GA Update 01 Build Number : ab9ebbd:884011b |
Description of problem: Trying to update to JBoss ON 3.2.3 using ./apply-update.sh script, in some cases will throw the exception and the following is the output: ********************************************************* $ ./apply-updates.sh /opt/jboss/jon-server-3.2.0.GA Successfully detected server [/opt/jboss/jon-server-3.2.0.GA] to be upgraded. Proceeding... Proceeding with application of patch '03' to /opt/jboss/jon-server-3.2.0.GA Successfully detected agent [/opt/jboss/rhq-agent] to be upgraded. Proceeding... Proceeding with application of patch '03' to /opt/jboss/rhq-agent Verifying that all [Server] component(s) are stopped... Successfull verified that [Server] is already shut down. Archiving legacy files. This list is cumulative and may attempt to remove files handled by earlier updates. Moving the following files to [./.old] for server and/or [./.old-agent] for agent: See './update.log' for more archive details. Applying the update contents. Applying additional JON Server updates... Starting JON Server... Starting JBoss CLI and applying patches... org.jboss.as.cli.CliInitializationException: Failed to connect to the controller at org.jboss.as.cli.impl.CliLauncher.initCommandContext(CliLauncher.java:280) at org.jboss.as.cli.impl.CliLauncher.main(CliLauncher.java:240) at org.jboss.as.cli.CommandLineMain.main(CommandLineMain.java:34) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.jboss.modules.Module.run(Module.java:270) at org.jboss.modules.Main.main(Main.java:411) Caused by: org.jboss.as.cli.CommandLineException: Failed to resolve host '127.0.0.1 10.33.63.237': Failed to create URI at org.jboss.as.cli.impl.CommandContextImpl.connectController(CommandContextImpl.java:796) at org.jboss.as.cli.impl.CommandContextImpl.connectController(CommandContextImpl.java:766) at org.jboss.as.cli.impl.CliLauncher.initCommandContext(CliLauncher.java:278) ... 8 more Stopping the JON Server... You have successfully extracted patch contents into (JON server) and/or (JON agent) installation folder(s). You should do the following as is necessary: i)Closely follow the remainder of the instructions delivered with this update. ii)restart your server(s)* iii)restart agents and request agent updates *NOTE: for HA environments you may need to repeat the steps here for each server before patch application is complete. ********************************************************* Version-Release number of selected component (if applicable): JBoss ON 3.2 and applying update 03 How reproducible: Sometimes (this is strange thing - the issue does not happen every time - from 5 installation maybe 3 will throw above exception) Steps to Reproduce: 1. Install JBoss ON 3.2.0 GA where values of jboss.bind.address and jboss.bind.address.management properties are set to IP address different then the default ones in rhq-server.properties file. So, something like: **************************************************** ... jboss.bind.address=<my_own_IP_address> # By default only local management connections #jboss.bind.address.management=127.0.0.1 jboss.bind.address.management=<my_own_IP_address> ... **************************************************** 2. Unzip jon-server-3.2.0.GA-update-03.zip and use ./apply-update.sh to update JBoss ON 3.2.0 GA installation Actual results: Update is not finished correctly and exception is thrown: ********************************* ... Caused by: org.jboss.as.cli.CommandLineException: Failed to resolve host '127.0.0.1 10.33.63.237': Failed to create URI ... ********************************* Expected results: Update is properly done and no exception is thrown Additional info: We had similar issue raised for update 01 - see Bugzilla https://bugzilla.redhat.com/show_bug.cgi?id=1096740 but this was fixed in 3.2.2