MySQL Remote Connection Problem After A Heavy Usage

Aug 8, 2008

I have 2 identical Fedora8 boxes with Apache 2.2.8, MySQL 5.0.45 and PhP 5.2.4. I use one as the Web+DB server (say box A), and the other (box B) just as the Web server connecting to the DB server on box A. I use this 2 machine configuration to test a LAMP based-Web application. I have a client program on other machines that can emulate a massive web workload to these 2 servers; it can emulate hundreds to thousands of users using the application simultaneously.

Before running the test, the connection to the DB server from both boxes seem fine. Using the mysql client program on either box A or B trying to connect to the DB, the connection goes through instantly. In the /etc/my.cnf file, I have max_connections=4096 and max_user_connections=4096. Note that the web app uses one single db user to connect to the db. To allow remote connection, I inserted one record into the user table of the mysql db whose the host field's value is '%' (allow connection from all remote hosts).

After running the test (which I found out that many requests sent to box B failed), mysql client program on box A is still able to connect to the db instantly; but the one on box B has a problem: it takes extremely long (5 - 10 minutes or even more) to establish the connection, it doesn't time out, just takes that long. I believe that's the cause for the failure of requests to box B.

View 1 Replies


ADVERTISEMENT

Host For Remote MySQL Connection

Feb 21, 2008

I have developed a desktop system that uses MySQL data.

I want to use a host to access the data but my current provider only allows access to MySQL data via a web server.

Can anyone suggest a host that would provide direct connection to a MySQL database?

View 11 Replies View Related

Allow User To Remote Mysql Connection

Aug 15, 2008

how to allow user to remote mysql connection from his localhost ( in linux server with WHM )

my user wants to connect to the mysql from his localhost

View 7 Replies View Related

Cpanel Mysql Remote Connection USE EXIST DB

Jun 29, 2009

A have set up a cpanel with remote mysql server.

My demo config:

cpanel:

centos VPS with cpanel WHM (demo)

mysql:

debian VPS

the configuration is OK, it works.

We have got 200 customers, and we will to change to cpanel.

The MYSQL server is on a solaris zone. It is possible to make the remote connecting with it. I will import the 200 users MYSQL databases to cpanel, with privileges (user settings). The mail/web dir a will import manuali to cpanel server(copy-paste-setuser:group).

View 0 Replies View Related

Heavy Mysql Process

Jun 5, 2008

on my top process am having this one as shown in the attachement image

its consuming time+ of 746:21:95
on the Process Manager that mysqld process is using the command

/usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/host.theplanet.host.pid --skip-external-locking

is that process normal? and what is cousing it? should i kill it?

View 5 Replies View Related

Remote Desktop Connection

Oct 27, 2009

I signed up for a windows VPS.

The directions I recieved were "Please use remote desktop to connect to your server."

So I entered the ip address into the remote desktop connection window and it doesn't connect. Where do I go from here? I searched and can't find any relevant info.

View 10 Replies View Related

Allow User Remote Connection

Aug 13, 2008

how to allow users to remote mysql from localhost ( in linux server with WHM )

my user wants to connect to mysql from his localhost

View 0 Replies View Related

Remote Connection To Domain Fails

Jun 17, 2009

I have an Ubuntu 8.04 server with 2 nerwork cards eth0 and eth1. I am using only eth0. The server is behind a 2-wire router. I have setup the router with the public IP addresses.

On the server I have setup an IP alias on eth0 as eth0:0. I have 3 domains which i will call foo1.com foo2.com and foo3.com. The server pc is assigned to a static public address on the router as 217.xx.xx.100 this same ip also used to setup the virtual host for foo1.com

Quote:

<VirtualHost 217.xx.xx.100:80>
ServerName foo1.com
ServerAlias www.foo1.com
ServerAdmin me@foo1.com
DocumentRoot /var/www/foo1/
</VirtualHost>

I have also setup and applied an ssl certificate to 217.xx.xx.100:443.

Now eth0:0 is assigned to 217.xx.xx.101 and used as below

Quote:

<VirtualHost 217.xx.xx.101:80>
ServerName foo2.com
ServerAlias www.foo2.com
ServerAdmin me@foo2.com
DocumentRoot /var/www/foo2/
</VirtualHost>

<VirtualHost 217.xx.xx.101:80>
ServerName foo3.com
ServerAlias www.foo3.com
ServerAdmin me@foo3.com
DocumentRoot /var/www/foo3/
</VirtualHost>

When I am on the router I can access all the domains via the browser and can also get FTP, and ssh connection to the server. However when I leave the range of the server and connect to the net via another router, I loose ftp and ssh access to the server as well as not able to browse www.foo1.com. However www.foo2.com and www.foo3.com I can browse.

View 3 Replies View Related

Remote Desktop Connection For Linux

Apr 25, 2008

My hoster told me to use PuTTY, a terminal, to install something called a vnc. I tried to install it ,but gets rejected everytime I connect.(I was using realvnc and connecting through a tunnel) Is there another way to get to the GUI or something like that?

I am using Vista and trying to connect to Linux (Debian)

View 6 Replies View Related

Windows And Linux Remote Desktop Connection

May 25, 2009

I know we can get remote Desktop connection only on those servers based on Windows 2003 OS or Windows 2008 OS.

But what about Linux? Can I have such remote desktop connection on CentOS 5?

Another question is, what is nxclient?
[url]

Im bit confused. Can I get remote desktop connection of Linux OS ( CentOS ) on my Windows XP by using this software?

[url]

View 7 Replies View Related

Spam/phishing Emails By Remote Connection (hacked)

Apr 23, 2009

One day, you noticed that someone remotely connectted your computer and an application sends spam/phishing emails bu using your IP. What do you do?

Of course, I stopped the program and blocked remote connection for a while and changed my password... I any way, i have to connect my computer remotely... What do you advice?

By the way, i have more than 1000 email accounts on my computer. Hacker left me a gift, but I don't need them))

View 9 Replies View Related

Failcnt Error #422: Cannot Initialize Connection To Remote Host

Dec 23, 2008

my site is working fine for somedays and suddenly its stoped and hanged and also my PPP is not working , and file manager in PPP its give me this error
VZAgent returns error #422: "Cannot initialize connection to remote host"
and the suppord admin said I have problem in failcnt

[root@server ~]# cat /proc/user_beancounters
Version: 2.5
uid resource held maxheld barrier limit failcnt
1592: kmemsize 18353610 18355203 65536000 65536000 0
lockedpages 0 0 256 256 0
privvmpages 166455 171964 262144 262144 119810
shmpages 4885 4885 131072 131072 0
dummy 0 0 2147483647 2147483647 0
numproc 150 150 600 600 0
physpages 101554 108439 0 2147483647 0
vmguarpages 0 0 196608 196608 0
oomguarpages 101554 108439 196608 196608 0
numtcpsock 141 141 600 600 0
numflock 7 8 300 330 0
numpty 1 1 16 16 0
numsiginfo 0 1 384 384 0
tcpsndbuf 2350036 2625064 32768000 36864000 0
tcprcvbuf 2310144 2129920 32768000 36864000 0
othersockbuf 32976 573000 32768000 36864000 0
dgramrcvbuf 0 4284 1024000 1024000 0
numothersock 32 32 600 600 0
dcachesize 642510 653661 8192000 8192000 0
numfile 2636 2663 20000 20000 0
dummy 0 0 0 0 0
dummy 0 0 0 0 0
dummy 0 0 0 0 0
numiptent 228 228 700 700 0

I want to know what is my ram site and why that all errors?

View 6 Replies View Related

My Screen Is Too Wide For "Remote Desktop Connection

Dec 17, 2007

I am trying to access my server remotely using Windows' Remote Desktop Connection. It functions perfectly, but it does not go full screen because my local screen res is 1680x1050 ...

Does anyone know any other remote desktop applications which work better in this way?

I know I could just change the local res settings but it is a bit of a nuisance and looks really weird if I set it to something non-wide-screen...

View 1 Replies View Related

Ping Doesnt Work Until Remote Desktop Connection Is Made

Nov 14, 2007

I have a remote XP PC: 172.16.1.5 OpenVPN connection with route added for 192.168.2.0/24 to go via the VPN

Now on the other end the network consists of:

I have a OpenVPN server inside the lan on 192.168.2.245
Its default gateway is 192.168.2.1

I have 3 Windows Servers, 192.168.2.246, 247 and 248. All gateways are set to 192.168.2.1.

I have a ethernet router on the network, 192.168.2.1, it has a route added for 192.168.0.0/16 to go via 192.168.2.245, and route added for 172.16.0.0/24 to go via 192.168.2.245 also). the 192.168.0.0/16 is incase any other LANs are connected at a later date, if computers saw any packets not on the the 192.168.2.x subnet they would be routed to the default gateway which would then pass them to the OpenVPN router.

The trouble is, i can remotely connect and ping to the OpenVPN router fine and also the ethernet router, however when i ping any of the Windows boxes it times out. But i can open up Remote Desktop and connect to the windows box without problem, infact if i am running 'ping 192.168.2.246 -t' it will suddenly come alive but only after the RDP connection is made.

Is this something funny with the routing? I want to keep the OpenVPN server internal to the network and i appreciate it is hitting the ethernet router then being passed to the OpenVPN but something is weird as it fires up RDP fine but not ping. No firewalls are enabled on any of the boxes. If i log into ssh on the OpenVPN router or ethernet router i can ping from that to the windows boxes fine.

Its as if a ICMP redirect is issued, and all is well after the 1st connection. Not too sure but could anyone be kind enough to enlighten me?

View 1 Replies View Related

MySQL Connection

Jun 8, 2007

I have a database server – mysql.xx.com which is the main MySQL server in H-Sphere.

I've created a database from mysqladmin interface.

I can use the database without a problem but when I’m trying to access the database from another server that I’ve just installed, the PHP application says that it can not connect to the database.

Another thing is that if I move the php app with the same configuration file under a shared account under another H-Sphere server, it's working perfectly.

I’ve read the H-Sphere documentation about an option to enable remote access to the mysql server which I can’t find anymore under our H-Sphere 2.5 Patch 8.

I’ve done a lot of searching to see how can I make that PHP application to connect to mysql.xx.com but it seems that although I’ve run the command grant all …. Command for that database, it still doesn’t work.

One final thing – from that new server if I run "mysql –h mysql.xx.com –u user –p" I can connect to the database and do a use database, show tables etc.

From iptables on mysql.xx.com I see that it accepts connections from outside.

This issue of not getting that PHP application to connect to mysql.xx.com can be related to the fact that H-Sphere is using the server or what should I try further?

View 14 Replies View Related

MySQL Connection Fluctuates

Oct 1, 2009

I'm trying to diagnose where my problem is coming from.

I have a site hosted with Integra Telecom. The site is connecting remotely to a MySQL database hosted on Media Temple.

My problem is that the site's connection to the MySQL database seems to be fluctuating throughout the day. Sometimes the site is up, sometimes it's down.

When it was down, I got the error: "Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)"

So is the problem with Integra Telecom or is my problem with Media Temple?

View 4 Replies View Related

Mysql Persistent Connection

Nov 3, 2009

Currently mysql.max_persistent and mysql.max_links are set to -1 which means unlimited

to optimize mysql, should i keep this unlimited or is it good to limit this? If i have to limit it, what is the best value that I can put there?

View 4 Replies View Related

Windows - MySQL Too Many Connection..

Jul 15, 2008

I have win2003 server and running plesk 8.4, there is a website on it and it gives me error with mysql max_connection even I set the limit 1 million or 10000 no matters.

View 3 Replies View Related

Zymic.com MySQL Connection

Mar 18, 2008

We have a front end server for the website Zymic.com (a free web hosting community), a mysql server and a main server for hosted websites. The problem lies between establishing a connection from the Zymic.com server to the database server - to sum it up, the connection just "hangs". We have never had this problem before, never edited anything which would cause a problem, its completely spontaneous.

My administrator has spent endless hours trying to debug the problem, here are some notes he gave me:

1. Ping to the mysql machine works fine.

2. Telnet to port 3306 of the mysql machine works great too – meaning NOT a network issue.

3. Strace on the connection shows it hangs when it calls the server and waits endlessly for response.

4. The mysql machine listens to the IP and port 3306 and connects great to the hosting server via SSH.

5. It's NOT a max connection issue but something to do with the mysql socket itself.

Here is a test from another site on the server to the mysql server:
[url]

Code:
<?php
mysql_connect('75.126.138.74', 'wkscript', 'PASSWORD') or die(mysql_error());
mysql_select_db('domains_data') or die('SELECT ERROR : ' . mysql_error());
?>

View 10 Replies View Related

LiteSpeed - Connection To Mysql

Dec 21, 2008

I have setup LiteSpeed and I have got a problem with php and mysql.

It seems php can't connect to mysql. At every script which use mysql(like phpbb3, phpbb2 etc) I getting errors

SQL ERROR [ mysql4 ] Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) [2002]
phpBB : Critical Error
Could not connect to the database

View 5 Replies View Related

Lost Connection To MySQL

Dec 7, 2007

MySQL Error : Lost connection to MySQL server during query

I get this error around 10 times a day and the MySQL server goes down

Here are my.cnf contents

Quote:

[mysqld]
safe-show-database
old_passwords
back_log = 75
skip-innodb
max_connections = 650
key_buffer = 48M
myisam_sort_buffer_size = 64M
join_buffer_size = 1M
read_buffer_size = 1M
sort_buffer_size = 2M
table_cache = 3000
thread_cache_size = 128
wait_timeout = 90
connect_timeout = 10
tmp_table_size = 64M
max_heap_table_size = 64M
max_allowed_packet = 64M
net_buffer_length = 16384
max_connect_errors = 10
thread_concurrency = 4
read_rnd_buffer_size = 786432
bulk_insert_buffer_size = 8M
query_cache_limit = 3M
query_cache_size = 48M
query_cache_type = 1
query_prealloc_size = 262144
query_alloc_block_size = 65536
transaction_alloc_block_size = 8192
transaction_prealloc_size = 4096
default-storage-engine = MyISAM

[mysqld_safe]
nice = -5
open_files_limit = 8192

[mysqldump]
quick
max_allowed_packet = 16M
[myisamchk]
key_buffer = 64M
sort_buffer = 64M
read_buffer = 16M
write_buffer = 16M

[mysqlhotcopy]
interactive-timeout

View 3 Replies View Related

Mysql 100% CPU Usage

May 18, 2007

After running for a while mysql suddenly starts using 100% CPU and my site goes down due to apache waiting with 150 sleeping processes.

Here is the top stats

PHP Code:

top - 00:20:47 up 12:01,  2 users,  load average: 1.11, 1.04, 0.95
Tasks: 200 total,   2 running, 198 sleeping,   0 stopped,   0 zombie
Cpu(s):100.0%us,  0.0%sy,  0.0%ni,  0.0%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Mem:   1004152k total,   618132k used,   386020k free,   118436k buffers
Swap:  2000084k total,        0k used,  2000084k free,   282372k cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
 2011 mysql     18   0  177m  43m 5684 S 99.9  4.5  86:51.60 mysqld
14877 root      15   0  2360 1216  860 R  0.3  0.1   0:00.11 top
    1 root      15   0  1948  648  556 S  0.0  0.1   0:00.97 init 

ps ax | grep apache -c
152

On restarting mysql everything goes back to normal.

Can someone tell me how I could go about rectifying this?

I'm sure the server can take the load, coz before this the site was on a way slower machine and worked flawlessly.

View 11 Replies View Related

Seeing Mysql Usage

May 11, 2007

is there any way to find out which users are most intensively using mysql? i've installed mytop which gives me some info, but the only user it shows connected is me (i.e. localhost) with no break down of what tables are being used etc.

also in whm i can see mysql has consuming quite a bit of memory/cpu, but it doesn't show me individual users; just the service as a whole.

View 3 Replies View Related

Mysql Has 182% Cpu Usage

Dec 20, 2007

I am using lighttpd php and mysql.

How to lower the cpu usage?

What's the best way to monitor mysql usage?

Quote:

top - 10:39:48 up 10 days, 35 min, 1 user, load average: 8.22, 9.38, 8.50
Tasks: 132 total, 5 running, 127 sleeping, 0 stopped, 0 zombie
Cpu(s): 73.5%us, 22.3%sy, 0.0%ni, 2.1%id, 0.0%wa, 0.1%hi, 2.0%si, 0.0%st
Mem: 2075000k total, 1919256k used, 155744k free, 113660k buffers
Swap: 2031608k total, 56k used, 2031552k free, 1177200k cached

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
21899 mysql 20 0 200m 53m 4752 S 182 2.6 8100:18 mysqld
2548 lighttpd 20 0 20288 16m 680 S 19 0.8 878:33.76 lighttpd
9759 lighttpd 20 0 23168 7880 3048 S 10 0.4 8:50.96 php-cgi
30959 lighttpd 20 0 23164 7896 3096 S 10 0.4 11:40.95 php-cgi
9732 lighttpd 20 0 23204 7544 2664 S 8 0.4 8:59.42 php-cgi
10671 lighttpd 20 0 23248 7612 2664 S 8 0.4 4:51.95 php-cgi
9769 lighttpd 20 0 23312 8012 3048 S 7 0.4 8:55.61 php-cgi
9771 lighttpd 20 0 23104 7312 2584 S 7 0.4 8:50.33 php-cgi
10601 lighttpd 20 0 23336 8032 2996 S 7 0.4 4:56.21 php-cgi
31091 lighttpd 20 0 23064 7860 3100 S 7 0.4 11:30.69 php-cgi
9782 lighttpd 20 0 23116 7880 3060 S 7 0.4 8:57.46 php-cgi
8559 lighttpd 20 0 23396 7780 2668 R 6 0.4 6:43.16 php-cgi

View 7 Replies View Related

Max MySQL Connection On Shared Host

May 31, 2009

What is the standard number on maximum mysql connection on most shared host providers and which one give the highest number.

View 11 Replies View Related

Remove Server MySQL Connection

May 13, 2009

I bought a VPS to run a part of a application I have and it needs to connect to my database in cpanel. I have set everything up properly and allowed the remote server to connect to my server, I updated the DB connect file with the correct mysql server username and password. But when I try and run the script I get this error.

Quote:

Client does not support authentication protocol requested by server; consider upgrading MySQL client in

I'm not 100% sure what to do. I don't understand why it wouldn't work because it works perfectly on the main server with my scripts. But I get that error message on the remote server.

View 4 Replies View Related

MySQL 4.1 Vs 5.1/5.0 (memory Usage)

Nov 6, 2009

Does anyone know if MySQL 5.1 or 5.0 uses less memory than 4.1 does?

View 3 Replies View Related

MySQL Limits Usage

Apr 25, 2008

how to set MAX_CONNECTIONS_PER_HOUR for one of my CPANEL USER (like:

cpaneluser_somesubuser) for all his databases?

I tried:

Quote:

mysql> GRANT USAGE ON *.* TO 'cpaneluser_somesubuser'@'localhost' WITH MAX_CONNECTIONS_PER_HOUR 10;

View 2 Replies View Related

Lower MySQL CPU Usage

Aug 14, 2008

I'm having a problem with high MySQL CPU usage on my server, one of my sites is getting hit pretty hard right now and MySQL is just killing the box. Its averaging a load of over 20, CPU usage is around 130%.

here is my my.cnf file. is there anything in their that should be changed to help lower the CPU usage?

# The MySQL server
[mysqld]
port= 3306
socket= /var/lib/mysql/mysql.sock
skip-locking
key_buffer = 256M
max_allowed_packet = 1M
table_cache = 512
max_connections=500
sort_buffer_size = 2M
read_buffer_size = 2M
read_rnd_buffer_size = 8M
myisam_sort_buffer_size = 64M
thread_cache_size = 8
query_cache_size = 32M
# Try number of CPU's*2 for thread_concurrency
thread_concurrency = 2

[mysqldump]
quick
max_allowed_packet = 16M

[mysql]
no-auto-rehash
# Remove the next comment character if you are not familiar with SQL
#safe-updates

[isamchk]
key_buffer = 256M
sort_buffer_size = 256M
read_buffer = 2M
write_buffer = 2M

[myisamchk]
key_buffer = 256M
sort_buffer_size = 256M
read_buffer = 2M
write_buffer = 2M

[mysqlhotcopy]
interactive-timeout
Server Specs.
Pentium E 2.0Ghz
2GB ram
2x 320GB hard drives.
Cent OS 5
Cpanel

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved