Not Able to connect to couchbase server - couchbase

Annoying issue...
OS : Linux
I am trying to connect to couchbase server but its causingfollowing exception. Problem is that everything was working fine and this issue has starting coming from no where. I hope its nothing to do with some port configuration or related to it...
If some one have any useful information over this, Please share with me. in the mean time, I am also looking into the issue.
Exception Stack Trace :
2014-11-16 07:57:00.946 WARN com.couchbase.client.CouchbaseConnection: Problem handling Couchbase IO
java.io.IOException: Invalid argument
at sun.nio.ch.DevPollArrayWrapper.poll0(Native Method)
at sun.nio.ch.DevPollArrayWrapper.poll(DevPollArrayWrapper.java:170)
at sun.nio.ch.DevPollSelectorImpl.doSelect(DevPollSelectorImpl.java:68)
at sun.nio.ch.SelectorImpl.lockAndDoSelect(SelectorImpl.java:69)
at sun.nio.ch.SelectorImpl.select(SelectorImpl.java:80)
at net.spy.memcached.MemcachedConnection.handleIO(MemcachedConnection.java:398)
at com.couchbase.client.CouchbaseConnection.run(CouchbaseConnection.java:288)
I tried connecting to the same couchbase server from a sample program from my local windows box, It worked as expected.

Got the reason. I was using -d64 option while calling my java program. unfortunately, the couchbase sdk I am using was only supporting 32 bit.
I removed the -d64 option and it ran fine.

Related

"Arithmetic operation resulted in an overflow." getting this error in ASP.Net after converting to the Azure project

I am working on an asp.net application. Now I am working on to move it to windows azure server. After converting the project to the windows azure project it gets started to give me errors in accessing the database. I am able to access the data but the problem occurs where-ever I am selecting longblob type column and bit columns.
When running the application as normal asp.net application everything works perfectly but when I run it as the azure application from my visual studio, it starts to give "Arithmetic operation resulted in an overflow." when filling the data-table. After doing some research for this I found that this type of error occurs in when there are some special type of columns are selected in the select command. In my case the special data types are "longblob" and bit[1] in the mySQL database table.
Please suggest a solution to make this work in windows azure environment too.
This is a known issue for Hybrid Connection to access SQL server.
Please follow the temporary fix mentioned here https://blogs.msdn.microsoft.com/waws/2016/05/17/hybrid-connection-error-with-sql-server-system-overflowexception-arithmetic-operation-resulted-in-an-overflow/
I am having the same issue today as of last night. The application has not been updated in weeks. Everything I have read indicates it has something to do with using an int32 and the int being too large but the page the application is crashing on is not using an int in the code behind. I disabled all SQL on the page and it still crashes. I think this is something on the Azure side. Putting in a ticket with them. I'll keep you updated.
Here is what fixed it for me.
My Azure Web App was using the Azure Hybrid Connection to access my on-site SQL server. The server running the HCM also runs Azure Backup. One of my admins had updated the Azure Recovery Agent on that server.
After trying all sorts of things, uninstalling the most recent update to the Azure Recovery Services Agent is what resolved the issue. My Web App was able to access my on-site dbs without issue.
I had the same error when using an Azure hybrid connection with an onsite SQL Server. I did not have the Azure backup agent installed on the local server, however I did have Windows Server 2012 set to automatically update and there were a lot of updates which were pushed out on May 10 2016.
At this stage, I'm not sure which update specifically caused the problem, but I have narrowed it down to either 3146978, 3146751, 3146604, 3145384, 3144850, 3142026, 3135998, 3134179, 3125424, 3103616 or 3145432.
If you're running into issues with Azure Hybrid Connections, try uninstalling KB3142036 from the server which runs the Hybrid Connection Manager. Seems to have solved the SQL Server connection issues for me.

JSF Hosting for testing

i just finish a web application with JSF 2.2, Hibernate 4.3, Primefaces 5.0, Tomcat 7.0.65 and MySQL 5.7.
i want to know if there any free host to try the result (i try it on localhost, works good) but i want to try it in web.
i try it in openshift but doesn't work (don't know exactly the issue).
and i tested on jelastic but not working, i found an error in tomcat log (... not support selectOneMenuView)
any idea, suggestion ?
maybe with a plan hosting for only one month (just for testing) and not expensive, it can be helpful/option
To answer your original question: Jelastic is probably the best "out of box" option. CloudBees has a Java EE 7 offering as well. If you want a more DIY solution, setup a TomEE, WildFly, or Payara server on DigitalOcean.
If you would like help solving the problem, post information about your localhost environment, the actual piece of code that isn't working, and the stack trace and we'll be able to pinpoint what's not working. Usually "not found" and "not supported" errors indicate something wrong with you Maven build.

Chrome error "Server has a weak ephemeral Diffie-Hellman public key" for internal sites

Chrome seems to have released an update over the past week. This has caused at least 50 of our internal applications to throw the exception shown below. The solutions I have researched over the Internet, talk about updating the application server with a stronger cipher. However, our applications are spread out over IIS, tomcat, jboss, weblogic and websphere. Its not practical to expect all of these application servers to be updated. Is there no way to get Chrome to allow an "exception" for these sites ? Since these sites are all internal, the security is not really a concern.
Apparently, Firefox throws the same exception but there is a documented fix for that (by changing some settings in Firefox). Is anyone aware of a similar fix in Chrome.
Error
Server has a weak ephemeral Diffie-Hellman public key
ERR_SSL_WEAK_SERVER_EPHEMERAL_DH_KEY
I found a temporary workaround that should disable the security check in Chrome that is causing that error. It goes without saying that you do NOT want to use this while browsing the open web.
Try adding the following command argument to Chrome when you start it up:
--cipher-suite-blacklist=0x0088,0x0087,0x0039,0x0038,0x0044,0x0045,0x0066,0x0032,0x0033,0x0016,0x0013
I found this solution at this google forum post. Hopefully it will help!
While Maximillian's workaround might work for you at the moment, there is no supported way to add an exception.
The only safe solution is to upgrade the servers, and a less fragile workaround might be to put better proxies right in front of some of the servers.
This problem I found because of the JDK version running on App Server.
If your weblogic/apache server running on java JRockit version "1.6.0_33" & "1.6.0_45" or below you will face this issue.
A solution is to upgrade java to higher version like "1.6.0_101" and higher and restart app server.
I've solved this problem without upgrading jrockit but configuring the ssl section like this
<ssl>
<enabled>true</enabled>
<hostname-verifier xsi:nil="true"></hostname-verifier>
<hostname-verification-ignored>false</hostname-verification-ignored>
<export-key-lifespan>500</export-key-lifespan>
<client-certificate-enforced>false</client-certificate-enforced>
<two-way-ssl-enabled>false</two-way-ssl-enabled>
<ssl-rejection-logging-enabled>true</ssl-rejection-logging-enabled>
<inbound-certificate-validation>BuiltinSSLValidationOnly</inbound-certificate-validation>
<outbound-certificate-validation>BuiltinSSLValidationOnly</outbound-certificate-validation>
<allow-unencrypted-null-cipher>false</allow-unencrypted-null-cipher>
<use-server-certs>false</use-server-certs>
<jsse-enabled>true</jsse-enabled>
</ssl>
Can't tell you exactly whats makes the difference but it solved many different problems on SSL with chrome

Intermittent MySQL Connection Error in Azure Website

I'm getting the following error intermittently when making a call from my ASP.Net MVC web application which is using Dapper to query MySQL.
Unable to connect to any of the specified MySQL hosts.
The exception only occurs when my web app is published to Azure. It has worked 100% of the time when I run the code locally. I've deployed the code to a second azure website, and also get the exception there, again intermittently.
The MySQL database is running on an Azure VM (Ubuntu). This server also has some R scripts that access the database, which are being run at a set interval. I've had no connectivity issue with these either. It is just the .Net code that's struggling.
I've scoured the web, but don't feel like I've turned up anything of value. Most of the links have pointed to a connection string problem, but since it works intermittently that doesn't seem to fit my problem. Some links have referenced DNS issues, but I'm getting the same problem when I use the IP Address instead of the machine name for the DNS server.
I'm sure I need to track down more information, but I'm not sure where it would be. This is my first foray into using a MySQL db in this fashion, and I'm not familiar with config options or log files on that side of things. I feel similarly about Azure websites with database interactions too.
What can I try next?
Just to drive home the point about this error being intermittent, here's a screenshot from the Runscope job that's hitting the page (thus triggering the MySQL query) every 5 minutes:
I was able to fix (or perhaps "circumvent") this problem by adding the --skip-host-cache flag to our mysql configuration file. I still don't fully understand what the root of the problem is, but we haven't had any issues with MySQL connectivity from the Azure website since adding that.

ipython notebook kernel runs, but no connection

My company makes me rotate my laptop each year.
I am trying to re-install ipython with notebook (it worked just fine like this before).
According to the command prompt, everything is hunky dory.
[NotebookApp] The IPython Notebook is running at: //127.0.0.1:8888
[NotebookApp] Use Control-C to stop this server and shut down all kernels.
But, Chrome can't connect to //127.0.0.1:8888/
I have a suspicion that it is a versioning problem with tornado, but was wondering if anybody else had faced similar issues?
The problem was not with ipython, but rather with the antivirus that had been set by a company policy to block localhost servers. This was resolved by a call to the IT department to ask them to remove the offending business rule from my computer.
It is worth noting two things:
(1.) ipython notebook --debug
this provides a lot more detail on what is happening behind the scenes, and provides a place to start problem solving from (although dont be thrown by the config error, that is a red herring)
(2.) in the command line this is what a successful connection looks like:
[NotebookApp] Kernel started: 77bb1680-ef54-4bf2-b9be-dc49dab639d7
[NotebookApp] Connecting to: tcp://127.0.0.1:52601
[NotebookApp] Connecting to: tcp://127.0.0.1:52603
[NotebookApp] Connecting to: tcp://127.0.0.1:52600
[IPKernelApp] To connect another client to this kernel, use:
[IPKernelApp] --existing kernel-77bb1680-ef54-4bf2-b9be-dc49dab639d7.json
In my instance all i got was:
[NotebookApp] Kernel started: 77bb1680-ef54-4bf2-b9be-dc49dab639d7
This will tell you that there was a problem connecting through to the client.