When using wlst with a WebLogic 10.3.5.0 release I am puzzled by the following situation and hoping for an answer.
Given a standard wlst command to connect to a server
connect('weblogic','welcome1','t3s://localhost:7002')
it connects as expected to the AdminServer in my domain and presents the following prompt:
Connecting to t3s://localhost:7004 with userid weblogic ...
Successfully connected to Admin Server 'AdminServer' that belongs to domain 'base_domain'.
wls:/base_domain/serverConfig>
However, if I perform the following command
import wlstModule as wlst
wlst.connect('weblogic','welcome1','t3s://localhost:7002')
I get the following response
Successfully connected to Admin Server 'AdminServer' that belongs to domain 'base_domain'.
wls:/offline>
The situation I have is I have a common module for connecting the AdminServer and whilst the connection is successful, any other functions revolving around requiring a serverRuntimeConfig(), etc, do not work as it thinks it is not connected.
Does anybody have any idea on the correct mechanism for using the second approach for connecting and what else needs to occur to retain the connection state when using the imported wlstModule.
After struggling with this very problem, I seem to have found the answer.
after you start with java org.python.util.jython, you get a prompt.
>>>
here you can do
import wlstModule as wlst
hencefort you should use the wlst all the time!!
wlst.connect()
a = wlst.cmo.getServers()
print (a)
greetings,
Saulius
Related
I have a weblogic domain (i.e. server1) that manages multiple managed servers (i.e. server2) on remote machines on which the admin server does not reside. I am trying to use WLST in online mode to dynamically pack the domain on the Admin Server into a JAR and transfer it to the managed server, but it fails due to CIE ConfigHelper service not being availble. I've tried to find a reference to this service with no lunck.
Here is the log of the output:
Initializing WebLogic Scripting Tool (WLST) ...
Welcome to WebLogic Server Administration Scripting Shell
Type help() for help on available commands
Connecting to t3://admin:7001 with userid admin ...
Successfully connected to Admin Server "wladmin_server" that belongs to domain "qa".
Warning: An insecure protocol was used to connect to the
server. To ensure on-the-wire security, the SSL port or
Admin port should be used instead.
Location changed to serverRuntime tree. This is a read-only tree with DomainMBean as the root.
For more help, use help('domainConfig')
CIE ConfigHelper online service is not available.
Disconnected from weblogic server: wladmin_server
I'm doing this based on the following link https://docs.oracle.com/middleware/1212/wls/WLSTG/domains.htm#WLSTG406 , but it just doesn't seem to work.
I am using Weblogic 12c (12.1.3) running on RH Linux.
Thanks.
pack and unpack scripts are working for us in similar scenario.
On admin server machine where domain is already created ,You can use this to pack/create managed server template :
$WL_HOME/common/bin/pack.sh -domain=${DOMAIN_HOME} \
-template=${DOMAIN_NAME}_managed_template.jar \
-template_name="${DOMAIN_NAME}" \
-template_author="YOU" \
-template_desc="${DOMAIN_NAME}-managed-template" \
-managed="true" \
-log=logs/pack_managed_${DOMAIN_NAME}.log
Then copy managed server template to different machines and unpack there:
$WL_HOME/common/bin/unpack.sh \
-domain=$DOMAIN_HOME \
-template=${DOMAIN_NAME}_managed_template.jar \
-overwrite_domain="true" \
-app_dir=$DOMAIN_HOME/../applications \
-log=logs/${DOMAIN_NAME}_creation.log
I have also encountered the same problem on my weblogic (ver 12.1.3). The problem seems to appear only when the weblogic server is started using wlst.
When I started the weblogic using startWeblogic.sh file and run the domain template wlst script the error(CIE ConfigHelper online service is not available.) has disappeared, and I can see that the template is created successfully.
It seems like a bug in weblogic wlst.
I've downloaded Aginity Workbench for Redshift, version 4.3.
I'm receiving the error message
The Connection is not open
I selected my server endpoint by using this document: http://docs.aws.amazon.com/redshift/latest/gsg/rs-gsg-connect-to-cluster.html
example from link: examplecluster.userid.us-west-2.redshift.amazonaws.com
Port is 5439
I noticed right away that I could select a database from the dropdown. If I supply the database name I still get the error message "The connection is not open", does anybody know what I'm missing? Thanks.
lowercase loginid should fix your issue.
This could be several things.
Does the instance require SSL connections? If so, select 'require' for the SSL mode in the connection setup.
Also, the link doesn't typically contain a 'userid' (examplecluster.userid.us-west-2.redshift.amazonaws.com). You can get the endpoint from the configuration tab in AWS management console for the redshift instance. The page looks just like the image referenced in the doc here.
http://docs.aws.amazon.com/redshift/latest/gsg/rs-gsg-connect-to-cluster.html
The Connection is not open is the error at beginning stage, so could you please check if there are any firewall issue. run the command from your computer:
telnet examplecluster.userid.us-west-2.redshift.amazonaws.com 5439
If can't, you need check the security group setting on that redshift cluster instance and open inbound port 5439 to public or your own IP address.
I am trying to port an application from WebLogic to JBoss EAP 6.2.
When running the standalone server in JBoss, in the admin console there is a button and in the command line interface there is a command line option to check the data source connection.
/subsystem=datasources/data-source=myds:test-connection-in-pool
These options do not appear to exist in either place when running the "domain" server. Am I missing something? Is there some further setting I must make to enable it? I tried a technique which is sometimes an analog in the domain server and it doesn't work here.
/profile=full/subsystem=datasources/data-source=myds:test-connection-in-pool
JBoss docs are much weaker for "domain" model than for "standalone".
You are absolutely correct that while running the standalone server in JBoss, in the admin console there is a button and in the command line interface there is a command line option to check the data source connection butThese options do not appear to exist in either place when running the "domain" server.
You still can use the command line of jboss-eap-6.x to test the configured data source connection in domain server. You need to navigate to $JBOSS_HOME/bin/ and execute script: jboss-cli.sh
Connect to the domain server controller with: connect :PORT_NO and execute the following commands:
For XA-DataSource:
/host=$Host_Controller_Name/server=$Server_Name/subsystem=datasources/xa-data-source=DataSource_JNDI_Name:test-connection-in-pool
For Non-XA-DataSource:
/host=$Host_Controller_Name/server=$Server_Name/subsystem=datasources/data-source=DataSource_JNDI_Name:test-connection-in-pool
I'm trying to connect to an admin server in WLST using config and key files. There are no error messages but I am prompted for a username and password. These files were created (by another developer who is long gone[1]) with the storeUserConfig() command. My call to connect looks something like this: connect(userConfigFile=configFile, userKeyFile=keyFile, url='t3://somehost:7031')).
Is there some restriction in using these files, such as it can only be used on the host where created, or it needs access to the domain's boot.properties file?
Note: I'm trying to connect to an admin server on a different host and non-standard port (e.g. not 7001). The server I am running WLST on and the remote host are the same version of Weblogic.
Some of the things I have tried:
verified that these files appear correct, the key file being binary data and the config file having a line for "weblogic.management.username={AES}..." and "weblogic.management.password={AES}...".
verified that there is a server on the specified port by entering a known login and password that is successful
specified the admin server in the connect parameter
turn on debug(true); the only output is <wlst-debug> connect : Will check if userConfig and userKeyFile should be used to connect to the server and another line giving the path to the userConfig file
turn on Python logging in jython with -Dpython.verbose=debug; nothing relevant to decryption operation
Munging the key or the config files generates no error messages and behaviour as above
[1]: These files are still used today by other existing WLST scripts. However, these scripts are so convoluted and deliberately obfuscated that they are very difficult to reverse-engineer how connect() is being called.
You do not need to access to the domain's boot.properties file. You just need to make sure the configFile and keyFile pointing to the right files. FYI, here is one of the commands we are using:connect(userConfigFile='./user.secure',userKeyFile='./key.secure',url='t3://somehost:7001')
Have you check the network connectity that might be having a firewall in between that troubling you, check the traceroute from the script machine to the Remote machine. Recently I have faced simalar issue. once the routing table updated with allow the WL admin server port everything got set.
Hope this could helps you!
I had this problem too. In a script, I exported the Linux variables userConfigFile and userKeyFile. Then I connected by running:
url='t3://localhost:7002'
userConfigFile='$userConfigFile'
userKeyFile='$userKeyFile'
connect(userConfigFile=$userConfigFile, userKeyFile=#userKeyFile, url=url)
That all worked in a script, but would not work interactively. I changed to doing the following:
url='t3://localhost:7002'
userConfigFile='/users/me/weblogic-2014/weblogic-admin-WebLogicConfig.properties'
userKeyFile='/users/me/weblogic-2014/weblogic-admin-WebLogicKey.properties'
connect(userConfigFile=userConfigFile, userKeyFile=userKeyFile, url=url)
And that worked interactively.
I want to get the process in a remote system using vb.net for that i have use getProcess() method. when i am trying to execute the code it is showing an error like "Couldn't connect to remote machine" .i know there should have certain privilege to use this.but i don't know how to set the privileges and what all are it. if any one knows please help me
sorry for my bad english.
The information from this blog post might be helpful:
Here is a list of common errors I had while working with the
System.Diagnostics.Process class. I listed all solutions that worked
for me.
Solution 1: Open MMC (Start/Run/mmc), add the Services snap-in and
enter the name of the machine you are trying to connect to. This
should give the exact reason it’s failing.
Solution 2: The inner exception could give you more information.
Solution 3: You need server permission.
Solution 4: Common on Windows 7 and Vista, start the Remote Registry
service.