kie server in Jboss EAP 7.4.0 localhost:8080/kie-server/services/rest/server' as failed due to Connection refused (Connection refused) - redhat

On running the command $EAP_HOME/bin/standalone.sh -c standalone-full.xml -b I'm getting error like
12:06:15,197 INFO
[org.kie.server.controller.websocket.client.WebSocketKieServerControllerImpl]
(KieServer-ControllerConnect) Kie Server points to non Web Socket
controller 'http://localhost:8080/business-central/rest/controller',
using default REST mechanism 12:06:15,198 WARN
[org.kie.server.services.impl.controller.DefaultRestControllerImpl]
(KieServer-ControllerConnect) Exception encountered while syncing with
controller at
http://localhost:8080/business-central/rest/controller/server/default-kieserver
error Connection refused (Connection refused) 12:06:19,805 WARN
[org.kie.server.client.impl.AbstractKieServicesClientImpl]
(Thread-125) Marking endpoint
'http://localhost:8080/kie-server/services/rest/server' as failed due
to Connection refused (Connection refused) 12:06:19,805 WARN
[org.kie.server.client.impl.AbstractKieServicesClientImpl]
(Thread-125) Cannot invoke request - 'No available endpoints found'
12:06:24,812 WARN
[org.kie.server.client.impl.AbstractKieServicesClientImpl]
(Thread-125) Marking endpoint
'http://localhost:8080/kie-server/services/rest/server' as failed due
to Connection refused (Connection refused) 12:06:24,812 WARN
[org.kie.server.client.impl.AbstractKieServicesClientImpl]
(Thread-125) Cannot invoke request - 'No available endpoints found'
on bind address, business central is running but I cannot find any execution server
but when I run the same command without bind address like
./standalone.sh -c standalone-full.xml
All are working properly
What would be the issue when using bind address
I'm using
rhpam 7.12.0
jboss eap 7.4.0
I've done default configuration. And I didn't change any configuration

Related

Connection Refused and Cannot connect to Controller Error

I am getting an error when i try to stop services
Failed to connect to the controller: The controller is not available at localhost:9990: java.net.ConnectException: WFLYPRT0053: Could not connect to http-remoting://localhost:9990. The connection failed: WFLYPRT0053: Could not connect to http-remoting://localhost:9990. The connection failed: Connection refused
when i try to start services, i get below error and need to restart the server multiple times to resolve it. need a solution to avoid errors during start and stop services. we use keycloack sercurity as well
2020-02-11 19:21:01,191 WARNING [com.lgc.dsl.admin.security.controllers.DSSecurity] (default task-12) Connect to localhost:8880 [localhost/IP] failed: Connection refused (Connection refused)
2020-02-11 19:21:09,462 WARN [org.kie.server.services.impl.controller.DefaultRestControllerImpl] (KieServer-ControllerConnect) Exception encountered while syncing with controller at http:localhost:port/dsbpm-console/rest/controller/server/dsbpm-kieserver error Error while sending PUT request to localhost:port/dsbpm-console/rest/controller/server/dsbpm-kieserver response code 405
Default kie server is not showing up in the server section
2020-02-11 19:21:01,191 WARNING [com.lgc.dsl.admin.security.controllers.DSSecurity] (default task-12) Connect to localhost:8880 [localhost/IP] failed: Connection refused (Connection refused)
2020-02-11 19:21:09,462 WARN [org.kie.server.services.impl.controller.DefaultRestControllerImpl] (KieServer-ControllerConnect) Exception encountered while syncing with controller at http:localhost:port/dsbpm-console/rest/controller/server/dsbpm-kieserver error Error while sending PUT request to localhost:port/dsbpm-console/rest/controller/server/dsbpm-kieserver response code 405
Check if you have 'dsbpm-console' for 'org.kie.server.controller' property, like as:

JBoss EAP on Eclipse does not have jndi service

I was trying to follow some EJB tutorial, most of them started talking about JNDI, and I am having trouble to get the service running on the JBOSS AS.
I have tried both the community and EAP version of JBoss in Eclipse, but both fails.
So now whenever I run lines like BeanRemote beanRemote = (BeanRemote) context.lookup("somecontext"); it throws these error.
javax.naming.CommunicationException: Could not obtain connection to any of these urls: localhost and discovery failed with error: javax.naming.CommunicationException: Receive timed out [Root exception is java.net.SocketTimeoutException: Receive timed out] [Root exception is javax.naming.CommunicationException: Failed to connect to server localhost:1099 [Root exception is javax.naming.ServiceUnavailableException: Failed to connect to server localhost:1099 [Root exception is java.net.ConnectException: Connection refused: connect]]]
Caused by: javax.naming.CommunicationException: Failed to connect to server localhost:1099 [Root exception is javax.naming.ServiceUnavailableException: Failed to connect to server localhost:1099 [Root exception is java.net.ConnectException: Connection refused: connect]]
Caused by: javax.naming.ServiceUnavailableException: Failed to connect to server localhost:1099 [Root exception is java.net.ConnectException: Connection refused: connect]
Caused by: java.net.ConnectException: Connection refused: connect
well of course it is caused by the port not opened, but I think its because the Jboss server is not providing the service, although its web port and admin port 8080 and 9990 is working fine.
I am using eclipse Oxygen 4.7.0, I have downloaded the Red Hat JBoss developer Studio. I added the server via the "New Server" wizard, then downloaded the server runtimes within the wizard. However there just seems no way to configure jndi, nor can I find any file that is related to jndi or jnp in the downloaded path. The XML configuration showed that only Management 9990 and Web 8080 port is open.
I don't understand why is this not enabled by default, and I don't know what to do. Is JNDI configurable somewhere in the management console? please help
Turns out method of linking to jndi changed in EAP 7 from EAP 5
this articles shows the correct method.
jndi.properties has been changed to jboss-ejb-client.properties, and the standard config now becomes
endpoint.name=client-endpoint
remote.connectionprovider.create.options.org.xnio.Options.SSL_ENABLED=false
remote.connections=default
remote.connection.default.host=yourhostaddress
remote.connection.default.port = 8080
remote.connection.default.connect.options.org.xnio.Options.SASL_POLICY_NOANONYMOUS=false
and context lookup string has been changed to
ejb:<app-name>/<module-name>/<distinct-name>/<bean-name>!<fully-qualified-classname-of-the-remote-interface>

WildFly management via reverse proxy fails with XNIO000816: Redirect encountered establishing connection

I have Wildfly 10 running on a docker swarm cluster. All HTTP requests go to a Load Balancer (traefik). In traefik (btw. labels in docker stack yml, it works perfectly) app.wildfly.my.swarm on port 80 redirects to the Wildfly container's 8080 port and admin.wildfly.my.swarm on port 80 redirects to port 9990. In my browser everything is working fine.
But if I try to use the maven wildfly plugin for remote deployment it fails with:
[ERROR] Failed to execute goal org.wildfly.plugins:wildfly-maven-plugin:1.2.1.Final:deploy (default-cli) on project automat: Failed to execute goal deploy. java.net.ConnectException: WFLYPRT0053: Could not connect to remote+http://admin.wildfly.my.swarm:80. The connection failed: XNIO000816: Redirect encountered establishing connection -> [Help 1]
Only if I open the management port directly it works.
Is there anywhere configuration needed to be able to deploy remotely with maven wildfly plugin to wildfly which is behind a proxy?
EDIT:
If trying to connect with CLI:
./bin/jboss-cli.sh
You are disconnected at the moment. Type 'connect' to connect to the server or 'help' for the list of supported commands.
[disconnected /] connect admin.wildfly.my.swarm
The controller is not available at admin.wildfly.my.swarm:9990: java.net.ConnectException: WFLYPRT0053: Could not connect to http-remoting://admin.wildfly.my.swarm:9990. The connection failed: WFLYPRT0053: Could not connect to http-remoting://admin.wildfly.my.swarm:9990. The connection failed: Connection refused
[disconnected /] connect admin.wildfly.my.swarm:30000
Authenticating against security realm: ManagementRealm
Username: admin
Password:
Warning! There were errors trying to load extensions. For more details, please, execute 'extension-commands --errors'
[standalone#admin.wildfly.my.swarm:30000 /]
Port 30000 is auto-assigned by swarm.

JBoss EAP 6.1 not able to shutdown with command

I am not able to shutdown jboss server with the below command.
Command :
JBOSS_HOME/bin/jboss-cli.sh --connect controller=$SERVER_IP_ADDRESS:$SERVER_PORT command=:shutdown
Each time I was killing the server to restart which is not a good process to do. as we are moving to PROD environment we should use shutdown command to stop the server instead of killing
I am getting the below error. Please help.
Server Log :
jboss#devkopmdmh01.corp.ybusa.net::/usr/local/prod/jboss/jboss-eap-6.1/jboss-as/bin > ./shutdownMDM.sh
org.jboss.as.cli.CliInitializationException: Failed to connect to the controller
at org.jboss.as.cli.impl.CliLauncher.initCommandContext(CliLauncher.java:280)
Caused by: org.jboss.as.cli.CommandLineException: The controller is not available at 10.0.15.162:8080
at org.jboss.as.cli.impl.CommandContextImpl.tryConnection(CommandContextImpl.java:951)
... 8 more
Caused by: java.io.IOException: java.net.ConnectException: JBAS012144: Could not connect to remote://10.0.15.162:8080. The connection timed out
at org.jboss.as.controller.client.impl.AbstractModelControllerClient.executeForResult(AbstractModelControllerClient.java:129)
... 11 more
Caused by: java.net.ConnectException: JBAS012144: Could not connect to remote://10.0.15.162:8080. The connection timed out
at org.jboss.as.protocol.ProtocolConnectionUtils.connectSync(ProtocolConnectionUtils.java:131)
... 13 more
The JBoss CLI is attempting to connect to the native management endpoint for the running JBoss and send a shutdown command. It looks like it's trying to send to 10.0.15.162:8080 which is not the right port (most likely).
Take a look in your bin/jboss-cli.xml file which should contain the host and port to connect to. For example:
<default-controller>
<host>localhost</host>
<port>9999</port>
</default-controller>

Connection timeout to local JBoss 7.2.0 on osx

I'm attempting to connect to a locally deployed JBoss 7.2.0 on osx, but I get the following error message when trying to connect with the CLI:
$ bin/jboss-cli.sh
You are disconnected at the moment. Type 'connect' to connect to the server or 'help' for the list of supported commands.
[disconnected /] connect
The controller is not available at localhost:9999: java.net.ConnectException: JBAS012144: Could not connect to remote://localhost:9999. The connection timed out: JBAS012144: Could not connect to remote://localhost:9999. The connection timed out
[disconnected /]
Netstat shows:
tcp4 0 0 127.0.0.1.9999 *.* LISTEN
and the server log states:
16:24:37,118 INFO [org.jboss.as.remoting] (MSC service thread 1-3) JBAS017100: Listening on 127.0.0.1:9999
In addition to which, I can telnet to 127.0.0.1:9999 (though the connection dies due to incorrect packet size, which I presume is as intended).
I've verified that standalone.xml states 127.0.0.1 as the correct binding address and 9999 as the correct port for management-native.
Is there anything I've missed, or any other way to trouble shoot?
Yeah, a bug in OpenJDK turned out to be it.