Questions tagged [connection]

Refers to a connection used to transfer data between two endpoints, such as between a client and a web, database, web service or other server.

A connection is a session established between two communications endpoint applications.

10252 questions
147
votes
7 answers

iPhone Simulator - Simulate a slow connection?

Is there a way to slow down the internet connection to the iPhone Simulator, so as to mimic how the App might react when you are in a slow spot on the cellular network?
Chris
  • 5,485
  • 15
  • 68
  • 130
140
votes
22 answers

How to test an Internet connection with bash?

How can an internet connection be tested without pinging some website? I mean, what if there is a connection but the site is down? Is there a check for a connection with the world?
lauriys
  • 4,652
  • 7
  • 32
  • 40
135
votes
11 answers

How to grant remote access permissions to mysql server for user?

If I do SHOW GRANTS in my mysql database I get GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' IDENTIFIED BY PASSWORD 'some_characters' WITH GRANT OPTION If I am not mistaken, root@localhost means that user root can access the server…
Aufwind
  • 25,310
  • 38
  • 109
  • 154
125
votes
23 answers

MySQL connection not working: 2002 No such file or directory

I'm trying to set up WordPress. I have Apache and MySQL running, and the accounts and database are all set up. I tried to make a simple connection:
mk12
  • 25,873
  • 32
  • 98
  • 137
121
votes
14 answers

How to create a bash script to check the SSH connection?

I am in the process of creating a bash script that would log into the remote machines and create private and public keys. My problem is that the remote machines are not very reliable, and they are not always up. I need a bash script that would check…
chutsu
  • 13,612
  • 19
  • 65
  • 86
117
votes
18 answers

How to fix HttpException: Connection closed before full header was received

I have recently upgraded my flutter version in my app. But when I want to debug the application, it shows me the following error. Error connecting to the service protocol: HttpException: Connection closed before full header was received, URI =…
Juthi Sarker Aka
  • 2,217
  • 6
  • 16
  • 22
108
votes
8 answers

How to determine total number of open/active connections in ms sql server 2005

My PHP/MS Sql Server 2005/win 2003 Application occasionally becomes very unresponsive, the memory/cpu usage does not spike. If i try to open any new connection from sql management studio, then the it just hangs at the open connection dialog box.…
jagan
101
votes
15 answers

Setting up connection string in ASP.NET to SQL SERVER

I'm trying to set up a connecting string in my web.config file (Visual Studio 2008/ASP.NET 3.5) to a local server (SQL server 2008). In my web.config, how and where do I place the connection string? Here's what web.config file looks like right now:…
Ray
  • 3,409
  • 8
  • 33
  • 40
100
votes
8 answers

How to close idle connections in PostgreSQL automatically?

Some clients connect to our postgresql database but leave the connections opened. Is it possible to tell Postgresql to close those connection after a certain amount of inactivity ? TL;DR IF you're using a Postgresql version >= 9.2 THEN use the…
Stephan
  • 41,764
  • 65
  • 238
  • 329
93
votes
10 answers

Why would a "java.net.ConnectException: Connection timed out" exception occur when URL is up?

I'm getting a ConnectException: Connection timed out with some frequency from my code. The URL I am trying to hit is up. The same code works for some users, but not others. It seems like once one user starts to get this exception they continue to…
Sarah Haskins
  • 931
  • 1
  • 8
  • 3
90
votes
5 answers

How can I programmatically remove the 2 connection limit in WebClient

Those "fine" RFCs mandate from every RFC-client that they beware of not using more than 2 connections per host... Microsoft implemented this in WebClient. I know that it can be turned off with App.config:
Christian
  • 2,903
  • 4
  • 31
  • 34
88
votes
3 answers

In Java when does a URL connection close?

When does java let go of a connections to a URL? I don't see a close() method on either URL or URLConnection so does it free up the connection as soon as the request finishes? I'm mainly asking to see if I need to do any clean up in an exception…
timdisney
  • 5,287
  • 9
  • 35
  • 31
87
votes
15 answers

Instantly detect client disconnection from server socket

How can I detect that a client has disconnected from my server? I have the following code in my AcceptCallBack method static Socket handler = null; public static void AcceptCallback(IAsyncResult ar) { //Accept incoming connection Socket listener…
Smart Alec
87
votes
3 answers

How to close a mongodb python connection?

I'm doing a python script that writes some data to a mongodb. I need to close the connection and free some resources, when finishing. How is that done in Python?
lrente
  • 1,070
  • 1
  • 9
  • 27
86
votes
18 answers

Apache Server (xampp) doesn't run on Windows 10 (Port 80)

I have installed the Windows 10 Insider Program. Everything works, except Apache. When I try to start it, it says that port 80 is blocked. Is there a way to unblock it or tell Apache to use another port instead? I was using Windows 7 before. I had…
Aloso
  • 5,123
  • 4
  • 24
  • 41