Cannot Connect to Oracle Thin Database in SoapUI but can in dbVisualizer - database-connection

I've tried about every different method using the built in jdbc connections and groovy scripts.
I've tried with oracle thin drivers 14, 6, 7, and 8.
My connection string is in the format (changes where user/pass goes depending on where I use it):
jdbc:oracle:thin:#(DESCRIPTION=(LOAD_BALANCE=yes)(ADDRESS=(PROTOCOL=TCP)(HOST=host1)(PORT=1521))(ADDRESS=(PROTOCOL=TCP)(HOST=host2)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=serviceName)))
Getting below errors:
the network adapter could not establish the connection
invalid username/password
The user and pass are correct, I've retyped them many times and the same user/pass work in dbVisualizer.
Looking for any suggestions on other things to try.

It turns out we were actually used the Service Name and not the SID (We only had the service name and assumed it was the correct thing to be used.
So Service Name != SID
But we could not just plug in the Service Name and get it to work because to use the Service Name instead the connection string has to be changed and therefore the jbdc driver template had to be changed (or you could create a new one).
We changed it to:
jdbc:oracle:thin:<USER>/<PASSWORD>#//<HOST:127.0.0.1>:<PORT:1521>/<SID>
The reason we have on the end and not (or something similar) is because SoapUI only seemed to recognize as a field it would make a UI element from when creating a new connection.
After change it to this and entering in the correct information everything worked.

Related

Error while creating send handler for WCF Custom Adapter in BizTalk 2016

While trying to add the host instances to the WCF Custom Adapter as a send handler I am getting the below error messages.
I tried resetting my password and restarted and that didn't work. Also, I tried to change the domain of my machine and bring it back to the original domain but I was not able to do it because of access issues.
Can someone please suggest why this error is occurring at this stage and how can I resolve it?
The above issue is resolved now. The actual problem was with the workstation/Computer name. At the time of BizTalk configuration I had only given the workstation/computer name, but instead we should give FQDN (fully qualified domain name) like workstation1.xyzcorp.net while configuring biztalk. This resolved my issue.
Thanks.

Application Settings in Azure Portal not Overwriting Generic Values

This is my process for setting some connection strings in my Azure hosted app:
When debugging, the strings are stored in Web.Config as normal, and this is encrypted with aspnet_regiis to hide them in the version control.
At publish, these are set to some generic values in Web.Release.Config:
<add xdt:Transform="Insert" name="SPsvcUsername" connectionString="username"/>
<add xdt:Transform="Insert" name="SPsvcPassword" connectionString="password"/>
I then go into the App Service on the Azure portal and under Application Settings -> Connection Strings I add the actual values required, just using the same name, e.g. SPsvcUsername. This overwrites the generic values and everything is fine and dandy.
This has always worked since I started doing it and I have had 0 issues apart from ocasionally I would have to wait a couple of minutes for it to update.
However, today it just doesn't apply the settings that I input in Azure Portal.
When I go into the command prompt and call
more web.config
I can see that the connection string scontains the generic values username and password
What gives? Why did this suddenly stop working? Was there an update that addressed this that I haven't read about?
Any advice is much appreciated. Including anything on whether my original process actually makes any sense.
They are replaced at runtime, not in the file.
So when you access the connection string via:
string username = ConfigurationManager.ConnectionStrings["SPsvcUsername"].ConnectionString;
It will have the value from the Application Settings blade.

Umbraco installation wizard Error - Could not connect to database

I'm trying to install Umbraco on an ASP.NET environment. After I downloaded the umbraco nuget package I tried to run the installation wizard, by building and running the project. All is fine and good, if i take the default database configuration, but if I want to customize my configuration, it fails and says :
"Could not connect to database"
I'm trying to configure it to use my local SQLExpress database, but I just cannot get it working. I have both tried putting in the server information and connecting via. a connection string, via. the wizard. It produces the same error every time.
I have made a database called umbracoblog and created an admin user, with credentials. He has dbowner etc. for the database. Besides that, I have also given full permissions to IIS_IUSRS and Network Service accounts for the project and all subdirectories, and it still doesn't work.
These are some of the connection strings I have tried:
datalayer=SqlServer;Data Source=.\SQLExpress;Initial Catalog=umbracoblog;User Id=admin;Password=********;
datalayer=SqlServer;Data Source=127.0.0.1\SQLExpress;Initial Catalog=umbracoblog;User Id=admin;Password=*******;
I have also tried putting in the connectionstring into the web.config, manually, but that just makes the project load infinitely in the browser, when I run it.
It's starting to get frustrating, that I cannot even get past the configuration of Umbraco, because it look very cool. I have tried everything I was able to found online. Have anyone gone through this and know what I need to do ?
Start again - clear out and remove the umbracoDbDSN connection string entirely from your web.config and reset the umbracoConfigurationStatus AppSetting back to empty if it has been populated.
Use the Wizard to configure the database - if it's still having problems connecting then here's a few things to check:
Check the Log file here: ~/App_Settings/Logs/UmbracoTraceLog.txt - does that show up any errors?
Make sure you can connect to the database using other clients - if Umbraco can't connect to it, chances are something else won't be able to as well.
What happens if you use Integrated Authentication? If that works, then it's most likely an issue with the username and password you specified.
The password I had for the SQL Server user had a character that the installation UI didn't accept. I changed the password to remove special characters and it was able to connect to the server again. I could successfully log in through SSMS with the previous password.

DirContextOperations is null

So I have an application that works perfectly on my desktop, and also works perfectly when deployed to tomcat on a windows machine. However, when I attempt to use this application while deployed on the same version of tomcat, but on AIX, it fails to retrieve data out of LDAP.
A user is able to successfully authenticate, but the context is null. DirContextOperations is passed into my ContextMapper as null. Does anyone know what ports that need to be open to get this data or what other configuration may need to be done? Based on what I am seeing it has to be a server configuration issue somewhere.
If you are using Spring Security LDAP plugin then it will be easy to co-relate the below mentioned configuration in AIX with the app. I prepared few snapshots for the configuration so that I do not clutter the answer space here. Have a look at LDAP config in AIX and try to setup the same in AIX Server.
Now coming to the LDAP plugin, there is nothing much other than setting up a bunch of properties is required. Values for these properties will be available once the LDAP configuration is done in AIX (as mentioned in the above mentioned slide).
Note:-
After creating a standalone LDAP, you might need to add realm if the user is associated to a group. I have not mentioned the same in the slides since I do not have an active LDAP host available now.
UPDATE
Instead of using BindAuthenticator can you try switching to PasswordComparisonAuthenticator for authentication.
Using the below setting in Config forces to use PasswordComparisonAuthenticator to authenticate and return back the DirContextOperations. Can this setting be tried?
grails.plugins.springsecurity.ldap.authenticator.useBind = false
#Refer LdapAuthentication Implementations.
I am not sure if this will be the answer in your case. I was also getting null in DirContextOperations object when trying to obtain values from Active Directory.
I was trying to get ldap attributes like this as the Grails LDAP plugin Documentation states:
String mail = ctx.originalAttrs.attrs['mail'].values[0]
and all those were null. So I have changed the line above for this one instead and it works for me:
String mail = ctx.attributes.getAt('mail').values[0].toString()

IPC Remoting problem

We are receiving the following error using IPC.
"Failed to connect to an IPC Port: The system cannot find the file specified."
The issue is happening on a Windows 2003 server.
Of course it only happens in production. We are unable to reproduce this in our development environment.
The Windows service that is attempting to use IPC is running as Local System.
Is there some sort of permission that needs to be changed?
We were attempting to access the channel before it was spun up. So we would receive the 'not found' error. Wrapping the access code in some 'is it really ready' code fixed the problem.
For me DTA was working fine. But Suddenly I started getting this same error.
For me the fix was this:
-> Go To Task Manager
-> Go To Processes Tab
-> Find and kill the DTA process. For me this process is named as 'DTASHELL.exe'
Now try to launch DTA. It should work now :-)
We had this problem in production code. It was failing on a small percentage of user's systems.
The error turns out to be in the microsoft code that we were using. It generates the IPC channel using the username.
ipc://APP_USER_000:SingeInstanceIPCChannel/SingleInstanceApplicationService
with certain characters in the username, this generates an invalid channel URL, so the receiving app fails to create the channel in the first place.
our fix is to use a hash of the username, rather than the first characters in the username.
(we were using the code here: http://blogs.microsoft.co.il/blogs/arik/archive/2010/05/28/wpf-single-instance-application.aspx )
Please post the code you use to initialize the server channel and publish the object, and the client code with the uri you use when you try to access the remote object.
A common pitfall is when you initialize the channel with a dictionary, and set the name of the channel using
dic["name"] = "channelName";
//used for retrieving the channel - ChannelServices.GetChannel("channelName");
instead of
dic["portName"] = "channelName";
//used as the identifier for the named pipe -
//The client should get the object from the uri : ipc://channelName/objectName

Resources