Cannot connect to localhost:8082 - maven

After successful running the maven project in eclipse, I cannot connect to http://localhost:8082. It shows the below error:
connection refused
What should I do to resolve the problem?

This exception usually occurs when there is no service listening on the port you are trying to connect to. A couple of things could be happening:
You have not started your server.
Your server is not waiting to
accept connections.
You are trying to connect to the wrong port
number.

You should check your services. I think they are either stopped or not working. You can check the services:-
a) if using windows by clicking services in control panel
b) if using linux type in the command Line sudo mqsql service.
you can refer this link- https://www.cyberciti.biz/faq/how-to-find-out-if-mysql-is-running-on-linux/
2)Also check the database connection string might you have not used correct string.

Related

What is the cause of this problem "IO Error: The Network Adapter could not establish the connection" on Sql Developer?

I make a connection for connect to the Database Server (other machine).
Then I found "An error was encountered performing the requested operation:
IO Error: The Network Adapter could not establish the connection
Vendor code 17002".
Please look the picture in URL below.
I tried to make a connection but can't access but my team can access it.
My friend used TNS connection type and I did everthing similar him but can't access. I tried to use JDBC thin for connect but can't also.
I had the old connection which I can connect but why I can't connect the new connection.
You're trying to connect to a machine on a network that SQL Developer is unable to reach.
For a TNS connection,
Look at the appropriate TNSNames entry (you will have a tnsnames.ora) file, and find the IP address or network name associated with the connection you're trying to establish -
And then start by trying to ping that resource.
In this case, i'm trying to talk to a database on MY machine, on port 1521. Yours should look quite different.
If you're using a basic connection, then you can look at the connection properties and see what machine/port you're trying to communicate with.
Ping
If you can't reach that machine from your machine, there's zero chance you can connect to a database there.
So, always start with a ping.
Once you see that you can get to that machine, if you're still getting that message, the next thing to think about is blocked ports, the listener defaults to port 1521, but you'll see that in the TNS descriptor as well.
It usually happens when a another process is running on the same port or there is an absence of listener.
Go to Run>services.msc>OracleXETNSListener>Start
Try to reconnect.. Even if the error still prevail then go to cmd
Use code:
npx kill-port <portnumber>
The port number by default is 1521, but you can check the port number in database properties.
It is possible, that your connection is forbidden by the firewall -
go to Control Panel\System and Security\Windows Defender Firewall - Advanced - Outbound Rules - Add a rule. (If you have some antivirus firewall, add rules there)
Create a temporary TCP rule for your port and another rule for UDP. Allow all nets and comps.
Check the telnet connection as cmd -> telnet ->
open remote.host.address PortNumber
If you can connect now, then the problem IS in firewall - edit your new rules, setting the hosts and nets exactly.
This error is because your sqldeveloper is not able to reach the database server's sql service.
One reason could be lsnrctl is down for some reason.
If you have access to machine where database is installed.
In Windows machine, follow: https://www.youtube.com/watch?v=r9pHqOfV2f0&ab_channel=TLinaTutorials
In Linux/macOS machine: Go to $ORACLE_HOME/bin and check status of lsnrctl
execute from $ORACLE_HOME/bin lsnrctl status, if it's down. Then restart it by lsnrctl start.
Check the details of connection in command output like SID, PORT, HOST etc. and try connecting again from sqldeveloper.

ElasticSearch-Kibana Connection Error: Unable to Connect

I have an elasticsearch server with host h1 running at port 9200. And i have a separate kibana server with host h2 running on port 5601. I have configured both of them properly and then tried to see the GUI of kibana.
It says Status:Red and in the error i see "Unable to connect to Elasticsearch at h1:9200"
I ran the basic troubleshoot mentioned in the elk documentation i.e. to check whether kibana.yml's elasticsearch.url field is properly referring to h1:9200 or not and vice versa for elasticsearch.yml's fields. Everything seems to be fine. What could be any other reason for this error? How to fix the same?
Could be for a number of reasons, connectivity/network configuration usually the prime suspect - check out this troubleshooting article for possible solutions

Cannot connect to named instance of SQL Server 2008R2

I am attempting to create a new Database Project in VS2010 via the New Project Wizard, and via this article: http://msdn.microsoft.com/en-us/library/aa833432(v=vs.100).aspx
I am on the 'Configure Build/Deploy' step, and am attempting to connect to a named instance of SQL Server 2008R2 that I just installed, called DEVELOPMENT. Assuming the server name is DB-01, I am using DB-01\DEVELOPMENT as the Server name in the dialog in the screenshot below. I'm also using the remaining settings in the dialog, but it keeps giving me the following error:
A network-related or instance-specific error occurred while
establishing a connection to the SQL Server. The server was not found
or was not accessible. Verify that the instance name is correct and
that SQL Server is configured to allow remote connections. (provider:
TCP Provider, error: 0 - A connection attempt failed because the
connected party did not properly respond after a period of time, or
established connection failed because connected host has failed to
respond.)
DEV is the name of a database I created on the DEVELOPMENT instance. If I use DB-01 as the server name, which is the default instance, it connects. In the past, we've been developing from a database on the default instance, with no issues, but I'm trying to move to local, source-controlled databases. What am I missing with this not connecting?
EDIT: As a little more context, it's not the username/pw combination, or the existence of the DEV db on the instance, because I receive different errors if either of those are incorrect. It's simply not able to connect once I give it the named instance.
Figured it out:
The default instance of SQL Server (called MSSQLSERVER in some places) uses port 1433 by default for incoming connections, which was opened in Windows Firewall. This is why I was able to connect to the default instance (DB-01). If you've created a named instance of SQL Server, by default these instances use port 1434 for incoming connections. These are TCP ports for each case. Well, I have to admit that I opened TCP port 1434 in Windows Firewall and still was not able to connect to the named instance remotely, and still am not sure why this was the case. So instead, I opened up a random port (6969) in Windows Firewall, and configured the DEVELOPMENT (named) instance to accept incoming connecting over that port only. For instructions on how to configure specific SQL Server instances to use ports other than the default, see this article:
Configure a Server to Listen on a Specific TCP Port
Once I configured the instance to use port 6969, I was able to connect with no issue. Hope this helps others that are having a similar/same issue.

Couchbase server refusing network connections - any ideas what might be the issue?

I downloaded the community edition of couchbase server, and am running it on a mac system.
It's up and running according to the console:
However, when I try to test it:
$ telnet localhost 8091
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.
I've told the firewall app to allow the "Couchbase Server.app" application to accept incoming network connections, and doesn't seem to have helped.
Any ideas what might be the issue here?
Yes, telnet into Couchbase should be through 11211... http://www.couchbase.com/docs/couchbase-manual-1.8/couchbase-getting-started-testing.html
Did you try to connect to it through any of the SDK's (C/Ruby/Java/.NET/PHP/Python/Perl)? If you ever need immediate help, you can also go to IRC (freenode.net), in the #libcouchbase or #couchbase channels, or post another question here of course.
I was connecting to the server on the wrong port. To see the port to use when accessing the server, open up the relevant data bucket, and check what port it's running on. By default, it will most likely be accessible on 11211

connect to oracle through socks proxy

My application (linux and windows) connects to oracle through OCI interface. Is it possible to connect to oracle through socks proxy? or some other similar proxy method? Simple ssh tunnel is not enough as I need to access multiple services (including oracle) through single port.
Edit: I have tried configuring the proxy as suggested in the answer, but it did not work. And I could not find anywhere information, that oracle can work through socks5 proxy.
I got the same issue to get solved. Anyway the solution above cannot work. You need to tell the client to just USE the proxy for connection initialization, but the target to connect to is supposed to be the oracle database server IP and port. Other forums read there is no such possibility via tnsnames.ora. But you're supposed to be able to achieve that using the Connection Manager. Haven't found out yet how to even download and install it though...
As I see Oracle doesn't support socks proxy.
To work around this for my self I did following:
Install proxifier www.freecap.ru
Start PL/SQL Developer from freecap
As I can see - this method not always work.
PL/SQL Developer was able to connect to database only on 3-4 try.
But after successful connect - it's seems stable enough for work.
Second option - is to use Java based tools like SQL Developer.
For Java there is system options for using SOCKS5 out of the box.
-DsocksProxyHost=localhost
-DsocksProxyPort=8081
there is official doc about SOCKS in java
Yes, this is possible. Your client tnsnames.ora file (or EZConnect string) should specify the proxy host as the database host, and the proxy listening port as the port. The SERVICE_NAME or SID is whatever the SQL*Net listener on the other side of the proxy is expecting.
[Edit]
If your proxy host is listening and forwarding on 1522, you should be able to:
telnet proxyhost 1522
and see:
Trying xx.xxx.xx.xxx...
Connected to proxyhost.domain.
Escape character is '^]'.

Resources