There seems to be a problem with the payara 5 asadmin command. When you launch the command from Windows 7 cmd and the program prompts for user input and you start typing it throws an exception.
Version 4.1 works just fine.
asadmin> list-domains
CLI141: No Domains to list.
Command list-domains executed successfully.
asadmin> create-domain ioit
Enter admin user name [Enter to accept default "admin" / no password]>
Enter the admin password [Enter to accept default of no password]>
Exception in thread "main" java.io.IOError: java.io.IOException
: The parameter is incorrect
at java.io.Console.readPassword(Console.java:328)
at com.sun.enterprise.admin.cli.CLICommand.readPassword(CLICommand.java:1191)
at com.sun.enterprise.admin.cli.CLICommand.getPassword(CLICommand.java:1134)
at com.sun.enterprise.admin.servermgmt.cli.CreateDomainCommand.getAdminPassword(CreateDomainCommand.java:369)
at com.sun.enterprise.admin.servermgmt.cli.CreateDomainCommand.validate(CreateDomainCommand.java:236)
This is a known issue with Payara 5.184, which has been fixed by this PR which will be included in the next release of Payara (5.191).
Related
We have keycloak 3.2.0 working on Docker.
When we run it, we add the ARGS --server-config standalone-ha.xml
e.g
Docker run foo bar jboss/keycloak:4.5.0.Final --server-config standalone-ha.xml
Purely because we're running a few nodes to the same DB
Upgrading to 4.5, the documentation here:
https://www.keycloak.org/docs/latest/server_installation/index.html#_standalone-ha-mode
Says, also add
--server-config standalone-ha.xml
However, when i do that (From version 4.0 onwards), i get
21:12:03,574 INFO [org.jboss.modules] (main) JBoss Modules version 1.8.6.Final
java.lang.IllegalArgumentException: WFLYSRV0191: Can't use both --server-config and --initial-server-config
at org.jboss.as.server.Main.assertSingleConfig(Main.java:395)
at org.jboss.as.server.Main.determineEnvironment(Main.java:169)
at org.jboss.as.server.Main.main(Main.java:96)
at org.jboss.modules.Module.run(Module.java:352)
at org.jboss.modules.Module.run(Module.java:320)
at org.jboss.modules.Main.main(Main.java:593)
21:12:03,973 FATAL [org.jboss.as.server] (main) WFLYSRV0239: Aborting with exit code 1
Now, if i run keycloak WITHOUT --server-config, and i enter the container, PS AUX shows its running standalone-ha.xml as config.
But thats because we are migrating from a DB which has 3.2.0 previously installed.
How do i enable and constantly make sure that standalone-ha.xml gets selected by passing parameter --server-config to choose the *-ha.xml configuration?
Thanks
It is a problem in Keycloak. Using -c instead of --server-config helps.
See https://issues.jboss.org/browse/KEYCLOAK-9393 for more details.
Try to deploy an EAR file to WebSphere enterprise app, over a SOAP connection.
the command line:
call wsadmin -conntype SOAP -host %WAS_HOST% -port %WAS_PORT% -user %WAS_USER% -password !WAS_PASSWORD! -lang jython -c "AdminApp.update('%APP_NAME%', 'app', '[ -operation update -contents %EAR_FILE% -usedefaultbindings -defaultbinding.virtual.host default_host -nopreCompileJSPs -installed.ear.destination $(APP_INSTALL_ROOT)/%WAS_HOST%Network -distributeApp -nouseMetaDataFromBinary -nodeployejb -createMBeansForResources -noreloadEnabled -deployws -validateinstall warn -noprocessEmbeddedConfig -filepermission .*\.dll=755#.*\.so=755#.*\.a=755#.*\.sl=755 -noallowDispatchRemoteInclude -noallowServiceRemoteInclude -asyncRequestDispatchType DISABLED -nouseAutoLink -MapModulesToServers [[ %MODULE_NAME% %WAR_FILE%,WEB-INF/web.xml WebSphere:cell=%WAS_HOST%Network,cluster=%CLUSTER%+WebSphere:cell=%WAS_HOST%Network,node=%WEB_NODE%,server=%WEB_NODE% ]]]' )"
is issued from a build machine that is on windows. where WAS_HOST=MySrvrA.mycomp.com
when running this command, I got
WASX7209I: Connected to process "dmgr" on node eagnmncom0cbbManager using SOAP connector; The type of process is: DeploymentManager
WASX7015E: Exception running command: "AdminApp.update ...
....
exception information:
com.ibm.websphere.management.filetransfer.client.TransferFailedException
java.net.UnknownHostException: java.net.UnknownHostException: MySrvrA
the WebSphere App server is on Linux, and the /etc/hosts file has the contents:
IP-Address Full-Qualified-Hostname Short-Hostname
#
127.0.0.1 localhost
special IPv6 addresses ::1 localhost ipv6-localhost ipv6-loopback
fe00::0 ipv6-localnet
ff00::0 ipv6-mcastprefix ff02::1 ipv6-allnodes ff02::2 ipv6-allrouters
ff02::3 ipv6-allhosts
56.xxx.xxx.xxx MySrvrA.mycomp.com MySrvrA
this server can be accessible over the internet via the Full-Qualified-Hostname only.
To trouble shoot, I have
1) run a command of
call wsadmin -conntype SOAP -host %WAS_HOST% -port %WAS_PORT% -user %WAS_USER% -password !WAS_PASSWORD! -lang jython -c "print Help.help()"
this works, and it should prove that the connection from the build machine to the WAS server is good.
2) to further prove that the AdminApp.update and its resolved parameters works, I have run the AppAdmin.update in its entirety:
AdminApp.update('%APP_NAME%', 'app', '[ -operation update -contents %EAR_FILE% -usedefaultbindings -defaultbinding.virtual.host default_host -nopreCompileJSPs -installed.ear.destination $(APP_INSTALL_ROOT)/%WAS_HOST%Network -distributeApp -nouseMetaDataFromBinary -nodeployejb -createMBeansForResources -noreloadEnabled -deployws -validateinstall warn -noprocessEmbeddedConfig -filepermission .*\.dll=755#.*\.so=755#.*\.a=755#.*\.sl=755 -noallowDispatchRemoteInclude -noallowServiceRemoteInclude -asyncRequestDispatchType DISABLED -nouseAutoLink -MapModulesToServers [[ %MODULE_NAME% %WAR_FILE%,WEB-INF/web.xml WebSphere:cell=%WAS_HOST%Network,cluster=%CLUSTER%+WebSphere:cell=%WAS_HOST%Network,node=%WEB_NODE%,server=%WEB_NODE% ]]]' )
directly on the WAS server. it works, and should prove the AdminApp.update and it's options and parameters are good.
it seems to me that over a SOAP deployment, AdminApp.update truncated the WAS_HOST and does not use the Full-Qualified-Hostname.
What I am doing wrong, and how can I resolve this?
I have another machine set that are accessible from the Internet via the Short-Hostname, the same command line works perfectly over SOAP connector.
It turns out that a security restriction causes the issue.
The target WAS server is in DMZ .com, while the build machine is in the blue .xxx, file transfer from .xxx to .com is not allowed based on the security policies of the organization.
After adding the target WAS servers into the C:\Windows\System32\Drivers\etc\hosts of the build machine, the deployment goes successfully.
When starting the WildFly service it fails with the error message:
The data area passed to a system call is too small.
This is how I installed the service:
I have copied C:\wildfly-10.1.0.Final\docs\contrib\scripts\service to C:\wildfly-10.1.0.Final\bin\service.
Similar to how it was working with WildFly 8, I have installed the services with the following command:
service install /jbossuser admin /jbosspass mypassword
When starting the service using service start, the command fails with the following error message:
Using the X86-32bit version of prunsrv
The data area passed to a system call is too small.
Failed to start serviceService Wildfly starting...
ERROR: Failed to load service Wildfly configuration
Just remove the quotes around description value:
set DESCRIPTION=WildFly Application Server
See: https://issues.jboss.org/browse/WFCORE-1719
Delete the value of description in service.bat instead of "Wildfly Application Server"
**rem defaults
set SHORTNAME=Wildfly
set DISPLAYNAME=WildFly
rem NO quotes around the description here !
set DESCRIPTION="WildFly Application Server"
set CONTROLLER=localhost:9990
set DC_HOST=master
set IS_DOMAIN=false
set LOGLEVEL=INFO
set LOGPATH=
set JBOSSUSER=
set JBOSSPASS=
set SERVICE_USER=
set SERVICE_PASS=
set STARTUP_MODE=manual
set ISDEBUG=
set CONFIG=
set HOSTCONFIG=host.xml
set BASE=**
It worked for me, i think you can use a description without spaces, but i didn't try.
I observed similar error on Wildfly 11.0.0.Final.
But problem was in DISPLAYNAME option. I changed it from default and I had white spaces there and it caused same error.
I changed(Default name is just Wildfly):
set DISPLAYNAME=WildFly Application Server
to:
set DISPLAYNAME="WildFly Application Server"
And it worked. Its weird that quotes in DESCRIPTION cause error and lack of quotes in DISPLAYNAME also causes error(simple name without white spaces don't need quotes).
I'm attempting to start and stop an application on a single JVM via the wsadmin console since the Web UI for IBM BPM PS Adv. doesn't allow for that kind of operation. So, I have the following script:
https://gist.github.com/predatorian3/b8661c949617727630152cbe04f78d7e
and when I run it against the DMGR from the Cell Host, I receive the following errors.
[wasadmin#server01 ~]$ cat /usr/local/bin/Run_wsadmin.sh
#!/bin/bash
#
#
#
/opt/IBM/WebSphere/AppServer/bin/wsadmin.sh -lang jython -user serviceAccount -password password $*
[wasadmin#cessoapscrt00 ~]$ time Run_wsadmin.sh -f /opt/IBM/wsadmin/wsadmin_Restart_Application.py WPS00 CRT00WPS01 redirectResource_war
WASX7209I: Connected to process "dmgr" on node CRTDMGR using SOAP connector; The type of process is: DeploymentManager
WASX7303I: The following options are passed to the scripting environment and are available as arguments that are stored in the argv variable: "[WPS00, CRT00WPS01, redirectResource_war]"
WASX7017E: Exception received while running file "/opt/IBM/wsadmin/wsadmin_Restart_Application.py"; exception information: com.ibm.websphere.management.exception.ConnectorException
org.apache.soap.SOAPException: [SOAPException: faultCode=SOAP-ENV:Client; msg=Read timed out; targetException=java.net.SocketTimeoutException: Read timed out]
real 3m21.275s
user 0m17.411s
sys 0m0.796s
So, I'm not specifying the connection types, and using the default, which is SOAP. However, upon reading about the other Connection Types, none of them seem any better, but I attribute that to IBM Documentation vagueness. Is there an option to increase the timeout wait periods, or turn it off, or is there a better connection type?
Also running this directly on the wsadmin console, it seems that it is hanging up on gathering the application manager string.
[wasadmin#server01 ~]$ Run_wsadmin.sh
WASX7209I: Connected to process "dmgr" on node CRTDMGR using SOAP connector; The type of process is: DeploymentManager WASX7031I: For help, enter: "print Help.help()"
wsadmin>appManager = AdminControl.queryNames('cell=CRTCELL,node=WPS00,type=ApplicatoinManager,process=CRT00WPS01,*')
WASX7015E: Exception running command: "appManager = AdminControl.queryNames('cell=CRTCELL,node=WPS00,type=ApplicationManager,process=CRT00WPS01,*')"; exception information:
com.ibm.websphere.management.exception.ConnectorException
org.apache.soap.SOAPException: [SOAPException: faultCode=SOAP-ENV:Client; msg=Read timed out; targetException=java.net.SocketTimeoutException: Read timed out]
wsadmin>
You can increase timeout value in {profile}/properties/soap.client.props
com.ibm.SOAP.requestTimeout=180
If you want to turn off timeout, modify com.ibm.SOAP.requestTimeout=0
Or if you want longer timeout you can modify the value 180 to something else.
Also about your query command, I noticed that you have a typo on the MBean type, you had type=ApplicatoinManager, it should be type=ApplicationManager
HERE YOU GO -- I had the same issue. I want to override the timeout prop temporarily. This worked like a champ. Make sure you follow below steps exactly.I did some mistakes and the prop did not passed, I figured out and it works.
Copy the soap.client.props file from /properties and give it a new name such as mysoap.client.props.
Edit mysoap.client.props and update the value of com.ibm.SOAP.requestTimeout as required
Create a new Java properties file soap_override.props and enter the following line:
com.ibm.SOAP.ConfigURL=file:/mysoap.client.props
Pass soap_override.props into wsadmin using the -p option: wsadmin -p soap_override.props...
REFERENCE:
https://www.ibm.com/developerworks/community/blogs/timdp/entry/avoiding_wsadmin_request_timeouts_the_neat_way32?lang=en
The following is the syntax I use to start my HSQL database before running junit tests.
java -cp ./hsqldb.jar org.hsqldb.server.Server --database.0 file:mydb --dbname.0 xdb
What is the syntax to stop this database from the command line?
Thank you. I made progress but now get this error.
I get this error when attempting to shutdown.
Failed to get a connection to 'jdbc:hsqldb:file:C:\My Projects\Libraries\junit\m
ydb;shutdown=true' as user "SA".
Cause: Database lock acquisition failure: lockFile: org.hsqldb.persist.LockFile#
74715985[file =C:\My Projects\Libraries\junit\mydb.lck, exists=true, locked=fals
e, valid=false, ] method: checkHeartbeat read: 2014-01-31 19:06:52 heartbeat - r
ead: -9919 ms.
My START command.
java -cp ./hsqldb.jar org.hsqldb.server.Server --database.0 file:mydb --dbname.0 xdb
My sqltool.rc
# A personal, local, persistent database
urlid xdb
url jdbc:hsqldb:file:C:\My Projects\Libraries\junit\mydb;shutdown=true
username SA
password
My STOP command.
java -jar sqltool.jar --sql 'SHUTDOWN;' xdb
I resolved the issue, need to use localhost in my sqltool.rc file.
My START command:
java -cp ./hsqldb.jar org.hsqldb.server.Server --database.0 file:mydb --dbname.0 xdb
My sqltool.rc:
urlid xdb
url jdbc:hsqldb:hsql://localhost/xdb;shutdown=true
username SA
password
My STOP command:
java -jar sqltool.jar --sql "SHUTDOWN;" xdb
You can use SQLTool which is a command line utility supplied as a jar with HSQLDB. There is an example for Unix, but you can use a similar command in other operating systems.
http://hsqldb.org/doc/guide/unix-chapt.html#uxc_shutdown
Also see the Utilities Guide for more information:
http://www.hsqldb.org/doc/2.0/util-guide/index.html