Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    MYSQL




Slow Table Access On Local Machine


I'm running MySQL 4.1.7-nt on my laptop, and I'm accessing it through ODBC
(MyODBC-3.51.10-x86-win-32bit).

I'm developing a .NET web application, but I don't think that's relevant.

I already had the application running OK on my desktop, and when I created the
same environment on the laptop, retrieving trivial amounts of data (5 rows) from
a table is taking 6 seconds. Updates the same. IN otherwords any table access
takes 5 or six seconds. (Table only has about twenty rows in it).

I can connect to the database on the laptop from the desktop (i.e - application
runs on desktop, retrieves data from laptop - works fine, not noticeably slower
than local on desktop.

If I connect the other way - application on laptop, database on desktop, it runs
just as slowly as locally.

The effect is the same whether I connect to 127.0.0.1 or via the machine name. Code:




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Connecting On A Local Machine
I have recently installed Mysql on my local machine. I can access Mysql through the
Mysql Command line client. But I can't connect through mysql_connect.php script. I have always used mysql through our hosting company with no problem. This is the first time I have installed it on my machine. When running the script I recieve the following error

Could not connect to MySQL: Can't connect to MySQL server on 'localhost' (10061

BACKUP DATA TO LOCAL MACHINE
Is there an easy way I can backup / copy MySql tables to my desktop PC. It would be neet if I could query these backups once of my desktop PC with MS Access.

Nightly Backups To My Local Machine
I have a MySQL database on one of my sites with shared hosting company which has nightly DB backups. However I would like to have a nightly copy for myself on my local machine.

Is there a way to automatically expoxt the entire MySQL database and FTP it to my local machine nightly?

Do i just need an FTP program that provides scheduling or are there other ways?

How To Insert Machine (local) Time In Mysql
This is a problem I encountered in mysql: how do I insert local (machine) time?

To do this in MS Access, just put now(). I tried this in mysql, it does not work.

see graph(the red chinese characters means the same thing as above.)

Importing MySQL Database To Local Machine
I have exported a MySQL Database from a remote server using PHPMYADMIN, saved on my local XP machine as an sql file to insert (with name _DB_.sql) but am not sure how to get this to run on my local XP machine which is running MySQL locally; When I view the file on Notepad it appears to be executable in some way as it includes CREATE command etc.

I tried the following from MySQL command line SOURCE C:/Program files/MySQL/_DB_sql but can't see any evidence of the database having been created on my local machine.

Dumping My Live Database And Then Putting It On My Local Machine Problem..
I have tried copying the dumped sql code in mysql query browser once dumped from live and it doesn't execute it, i have to extract it line by line and that would take forever to do this all, is there an easier way to do this or can someone run me through the basics on how to achieve this?

i have on my live site: 4.0.25 (patched)
and on my desktop computer : 5.0

Would this be part of the reason? i don't know..

Access MySQL From Another Machine
how do I make MySQL server accessible from the network to other web
servers. Right now I have the MySQL server and the web Server all on
the same server. But I want to have a server that is solely responsible
for MySQL and 3 others servers that are responsible for web page serving
via Apache. The web servers need to be able to access the MySQL database.

|-----| |----| |----|
|Web | |Web | |Web |
|-----| |----| |----|
! ! !
!!!!!!!!!!!!!!!!!!!! |
|----|
|My- |
|SQL |
|----|


Slow Db Access
I have worked with a few mysql dbs on different servers but i have recently been asked to work with one on nicnames. It seems horribly slow. Working in phpMyAdmin (which i had to install myself) it takes ages when i want to do anything. View the table structure, view the data..etc. Any way i can test the speed so that i can compare it against another server i work with and proove there is a speed issue and take it to nicnames cus it is crazy and is going to affect the speed of the website!!

MS ACCESS Frontend SLOW
Having fought my way through getting ODBC running with Access and MySql, I now find its like watching paint dry when I go to look at a table with Access, including scrolling down/doing a query. Is this the best I will get??? or have I missed something.

Access Frontend Searching Slow
I am running mysql on a gentoo linux box and I am using it to store data for my family. I am interested in migrating them from an access database to mysql while still using access as a frontend. However while doing preliminary testing I realized that searching through access was very slow, e.g. the <ctrl + f> find method takes a few minutes to procure a single match.

The database has two tables, one table containing personal information, with about 500 records and 9 fields, and the second containing sales records, with about 1000 records and 5 fields, linked together by a id number relationship.

Access is set up with two forms, one for entering new personal information, and another form for entering a sale. In the sale form, I link data from the personal information table while hiding the id number because its easier to recognize a name rather than an id number.

What my ideal goal is for them to <ctrl + f>, enter in the last name of the person, and proceeed to enter in a new sale without the process taking 5+ minutes. Is there an alternative to the find command that we can use to speed up the data.

The machine on which the server is running has VERY limited system resouces, a pentium III 550 mhz processor, 256 megs ram, and a 20 gig hdd, but somehow, I know the problem is with the way that I am trying to find data rather than the limited resources of the serving machine.

Why Is Text Driver Access/Excel (DAO) Is Slow?
I'm using the Access/Excel (DAO) driver to connect to (*.csv) files, but every time I change the location of the file, it takes around 30 seconds before the change is made...

Any idea about this? Could it be because of the Access/Excel (DAO) driver? If i'm using (*.csv) files with this driver, is there a conversion that could take that long?

How To Allow Access To MySQL From Another Computer On Local Network?
when I am trying to connect from MySQL Studio on Windows XP, I get error
"Host '192.168.0.100' is not allowed to connect to this MySQL server"

Local Host On Windows Allowing Remote Access
We have MySQL running on a server in the US (we are in NZ) the response times to queries can vary, so i have installed MySQL on my Windows XP PC. i can transfer data across overnight using a scheduled task, this allows me to query yesterdays data much quicker - it is used for trends so up to date in not important - the problem i have is this

I want others within the company to be able to connect to my PC to run their own queries against my data. i do not know how to set up the ODBC connections on their PCs to 'talk' to mine. I can set them up to connect to the US with no problem but not to my PC.

Very Slow Table Update
I have two tables. One is really a subset of the other. However, they came in different data files and I would like to pull data from one and put it into the other. However, it is VERY slow!

Once the tables are setup I will only read from them and perform operations. I will never update or insert. However, I can't get things setup to that point. Code:

Optimize Table With LOCAL Arg
I am running mysql 4.0.16. Optimize table does not work with LOCAL or
NO_WRITE_TO_BINLOG options, and gives me mysql error. Any ideas?

Large Table, Slow Query Question
I have a table with ~800,000 records. I need to grab random rows from the table based on certain criteria. The problem is that average lowest subset to grab the random row is around 200k. Here is what I'm trying to do:

There are 4 columns: data,n1,n2, and n3. I need to get the value of the data column based on criteria using the n1-n3 columns.

The most common query is SELECT data FROM table WHERE n1 = ?

The problem is that n1 can be only 1 of 5 possiblities. When the table is finished being populated there will be roughly 1.5 million records and 250k for each value of n1. Of course, I have an index on each n column.

Right now with just the 800k records it can take over a second, sometimes multiple seconds to run the following in order to get a random row from that subset:

SELECT COUNT(1) AS total FROM table WHERE n1 = 3;
index = random number from 1 to total
SELECT data FROM table WHERE n1 = 3 LIMIT index,1;

How can I speed this up? I need it to take less than half a second if possible. Thank you.

How To Download To Local Client From A Large Table
I have been trying to download a large text file (17 MB) from my large table using all sorts of scripts etc. The best so far has been using -

"SELECT * INTO OUTFILE 'tmp imes.csv' FIELDS TERMINATED BY ',' LINES TERMINATED BY '
' FROM tbl_times";

This is fine on my test server - because it is 'local'... but what I need is the syntax to get it to work in the real environment and save the file to a client machine. Ideally to give them the choice of where it will be saved.

How Do You Get A Local Text File Into A Mysql Table?
If you have a local text file in notepad, how do you get the data into table EMAILS2 in my myslq database?

Do you need to upload the whole file and then run the query

LOAD DATA INFILE emails2.txt to TABLE EMAILS2?

Why LAN Clients Frozes While A Slow Networked Client Downloads A Big Table
With MySQL 4.1 I think from a day to another something changed in the working of our server.

When a remote agent with very slow Internet connection downloads 60.000 rows query lets say downloads the whole "products" table, all of the other fast LAN clients stop responding until the big download finishes. It is possible, that they would like to change the "products" table while the remote client downloads it...

But! There is no lock to the table, just its a simple "SELECT a,b,c,d FROM table ORDER BY a" query..

Can it happen because of that the table becomes bigger and bigger, and now MySQL can't copy it to in the RAM, and let others live, and now it stops other clients instead?

Slow Select Using Count(distinct) In A Table Bigger Than 100000 Records
Recently I started using MYSQL in my enterprise. I made a table which has around 100000 records. The problems is that it is really slow.. Im trying to do a query in which I get the number of distinct users per day.

This is my query:

select date(startedDate) as mydate, count(distinct(Users)) as users from Mytable
group by mydate

It is really simple and it does it correctly but it takes one minute.. One minute is not too much time but i need to insert around 10 000 000 records and thats what worries me.....

Can't Access Table
I ran a php script to delete about 4 million rows from a table with about 10 million rows. Waited for a while (20 minutes?) and it seemed to be stuck so I killed the script. Now I can't access the table (although I can access others in the database). What can I do to unlock or free up the table again? Would restarting mysql do it? Is there a way to do it without restarting mysql?

mysql version: 3.23.58

Cant Access Table
i have managed to set up a login system using mysql with no trouble. now i want to insert data from the mySQL table to a webpage, i have made the following PHP code (passwords and so on ive left out :) but there right):

<?php
mysql_connect("host", "user", "pass")or die("cannot connect");
echo "Connected to MySQL<br /><hr />";
mysql_select_db("members") or die (mysql_error());
echo "Connected to Database<br /><hr />";
?>

i tested the first part and it connects to the database, however when i connect to the table it comes up with:

Access denied for user 'user'@'%' to database 'members'

i dont know whats wrong? the only thing ive seen is in my mySQL database it says No Privileges on the main screen could this be it? its a college created account so they could be blocking me.

Importing Table From Access
I've got a problem when I try and import a table into a MySQl database using MyPHP Admin and the Import CSV using LOAD DATA option.

For some reason only the last record gets imported, although there are almost 700 records in the table. I regular import data into two other tables using the same method without problems, so I'm pretty sure I've got all the right parameters set up when exporting the original MS Access table as a CSV .txt file.

Transfer Access Table
I am working on a client's site that is on a server hosted in Germany. Communicating with the hosting company is not possible, but I have been given access to phpMyAdmin and can access the database for the client. I have an Access database that has one table in particular with Data that I would like to transfer over to the mySQL database. Is this possible? I am now downloading a program that will convert the databases, but what about getting table a from DB A to DB B?

Two Versions On Same Machine
I had MySQL 4.2 - working fine. I saw version 5 is now stable so I downloaded and installed but did not run it (I think!). Carried on with 4.2.

Then one day MySQLAdmin and Query would not log me on. I checked via the cmd line utility and when I typed in the password the window dissappeared!

I opened MySQLAdmin again and reconfigured the log-on o 3307 (I remember this was default when I installed 5.0). OK, the server must be running. So keep with 5.0 as I managed to restore one of my schemas. I wanted a later version which is only in the 4.1 directories and copied it across BUT 5.0 does not see it. But when I go to stop and restart the 5.0 server in Admin as soon as I go to the server tab to do this it stops automatically! AND will not restart.

Speed From Second Machine Bad
I am new to MySQL (mysql-4.1.7-win) with MySql ODBC (MyODBC-3.51.10-x86-win-32bit) and (vb 6 with service pack 5 or Access 2003) to connect via adbc to MySQL.
My seccond machine are terribly slow and would like to know if there are any suggestions.

Load On My DS Machine
I've got dedicated server , 30mbp/s line, and solving very strange issue, my hosting told me i burn about 2.8mb per sec., so i get a lot of traffic, i don't use mysql very often, i use mysql only for special cases, no more than 5 requests at same time.
i'm checking top function via telnet console, and i can see sometimes huge loads on server, from 0,8-1 it skips to 20, then 30, 50, 100, somewhere between 20-30 it crashes mysql, and i can't connect , sometimes it went to 150 load, and then it slowly going back to normal.

Backing Up A Table ... But Being Able To Access The Backup
I am making a database that has ordering information on it. When someone places in order it gets approved or not. When a order is placed, I want to backup the data(where it still can be accessed) and the orgainl database cleared so more orders can be placed(new ones)That way the old orders and the new orders do not get mixed up. So what I want to do is back up the orginal database and still beable to access it. Does anyone know if that is possble?

Access Denied On Individual Table
Trying to insert records into 2 tables of the same DB, using
Coldfusion query. It works on the first table, but on the second table
I get 'access denied', although I'm providing the same
username/password. When removing the username/password from the query
for the second table, it works! I'm confused, because the table should
have inherited the DB privileges (no table privileges set).

OLE Object From MS Access To A MySQL Table
I don't know which forum (MySQL or MS Access) that can help me, so I decided to put my thread on both. Sorry for the inconvenience.

I want to copy a table from MS Access to a MySQL table.

1.
The problem is, one of the fields in the Access table has data type of OLE Object. What would be the equivalent of OLE Object data type in MySQL?

2.
Quite often that I lost connection to mySQL Server when I'm trying to acess tables in my MS Access that are connected (through) ODBC) to MySQL (Error #2013). Is there a way to fix this?

Error Accessing MS Access Table
In order to perform a hetrogeneous join (I think that's what they're called)
between MySQL and another database, I've created an Access database
containing linked tables from each datasource.

I create the linked tables without any problems, clicking on "save password"
before selecting the desired tables. I can then access both tables fine from
within the Access GUI.

The problem starts when I then try to access this data from my ASP.NET web
application - classic ASP works fine but .NET gives me...

ERROR [HY000] [Microsoft][ODBC Microsoft Access Driver] ODBC--connection to
'MyDSN' failed.

From then on, the Access database remains locked (.LDB file in the same
directory) and I get a similar error when I run my ASP page, which
previously worked.

Migrating My Mysql DB From One Machine To Another
We are moving our mysql db from one machine to another -- both linux. Origin machine is running mysql 3.23, destination machine is running mysql 4.1.

Can we simply copy all *.MYD / *.MYI / *.frm files from one machine to the other and have things work?

Or do we *NEED* to do a text dump of the tables, and reload each one individually on the new machine?

How To Go About Re-installing MySQL On A New Machine?
I have MySQL installed and a database already built and loaded with data that is collected nightly from the mainframe database.

I am currently running on NT and will be loading a new image onto the machines to change the operating system to Windows2000.  From what I understand, I will need to copy all files I want to keep, including my database.

My question is, once the new image is on, I will need to re-install MySQL, is it as easy as just copying back the MySQL directory back onto the machine and the database still work?  If not, can someone tell me what the general process is to do this without losing the database and any issues that I am going to run into?

Can't Connect From Remote Machine
I am writing some code in ASP3 on an XP windows machine. I am trying to connect to a linux machine which is Redhat 7.3 that is hosting my MySQL database. I am use this code to connect.

objConn.Open "Driver={mySQL};Server=http://4.7.165.99;Port=3306;Option=131072;
Stmt=;Database=DB name;Uid=User Id;Pwd=MyPassword;"

This is the Error message I keep getting:

Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

I have been looking all over the web, and can't find how to fix this issue, can anyone help me?

Transferring Mysql Db To Another Machine
i am working from home creating a db and i need to transfer the db to another machine (the other machine is not at home) how do i go about it.

Anyway To Run 2 Instances Of MySQL On The Same Machine?
I was wondering if there is anyway I can run 2 instances of MySQL Server on the same machine, the reason is I have one machine and I want to be able to simulate my program which really talks between 2 systems accessing their own MySQL server datas but I dont have 2 machines with me all the time to do this, it would be great If I could somehow manage this.

Connect To MySql From Another Machine
I have RHEL 4.0 installed on a x86 box, and am using the standard MySql server that comes with RHEL 4 (MySql version 4.1.12). I tried downloading the Administrator tool, but had problems installing it. (This issue has already been reported at http://forums.mysql.com/read.php?34,65093,65093#msg-65093).

I have an Administrator install on a Windows machine, and I want to use it to connect to the MySql server on the RHEL box, but get the error that says: Host '<my_machine>' is not allowed to connect to this MySql Server. Can I use the Windows Administrator tool to connect to a MySql server on Linux? (same network and sub-net)

During the RHEL install, the firewall option has been disabled, so that's not an issue. I think I need to add an entrry somewhere in the MySql db that allows other machines to connect, but am unsure of how to add it, and what the syntax looks like.

MySQL 4.0.x On Multiprocessor Machine
IBM server with dual Xeon processors. I intend to install MySql 4.0.19 on them. Anybody know any issues about this combination?

When Should I Scale Out From One LAMP Machine?
I just have one server that runs Apache, MySQL, PHP. It handles
requests fine and never had problems. When should I think about a small
step into scaling? By maybe having an independent MySQL server? How
many QPS (Querys Per second) (approx) on the MySQL DB will it be
optimal for me to have MySQL on a seperate maybe more powerful machine?
The current server has 1GB Ram and intel duo core processors..

Connect To Another Machine With SQL-Server
just installed a mysql server, database and user on one machine [1] (debian-linux)

Now I want to connect to the database from another machine [2]. Actually I am sure that I have to configure connectors or named pipes. But I can't find these topics in the manual.

When starting mySQL as user on the server everything is ok. When starting mySQL as user on the client computer [2] I get

ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

actually '/var/run/mysqld/mysqld.sock' is not existing. What do I have to put into that one? Or rather into /etc/mysql/my.cnf

Usinq MySQL And MS-SQL On The Same Machine?
I want to try MySQL but I already have Microsoft SQL Server on my machine. Can
they reside on the same PC or will they mess eachother up?

And why does the name of this newsgroup start with 'mailing.'?

Usinq MySQL And MS-SQL On The Same Machine
I want to try MySQL but I already have Microsoft SQL Server on my machine. Can
they reside on the same PC or will they mess eachother up?
And why does the name of this newsgroup start with 'mailing.'?

Move SQL Files On Same Machine
How do you move the directory where MySQL files reside and inform the local MySQL server of this? I'd like to be able to move my data files to different locations on my hard drive AND move them to another machine when I have to use them on the road.

Moving Database To New Machine
I'm trying to relocate my site to a new host and I'm having a lot of trouble moving the database.

I did the export for the old host/database with phpmyadmin. It saved to a txt/sql file with no problems.

When I try to import it into the new host/database I get all kinds of syntax errors.

Then I realized, after purchasing the new host that:

Old host/db = MySQL version 5.0.24a
New host/db = 4.0.27

Is there any way to convert a 5.0 db to 4.0?

Installing MySQL On My Machine
Can I install MySQL on my local home machine?

Connecting To MySql On An XP Machine
I have worked with mySql on my localhost and it does fine. Now I am going to try and login to it from another XP machine. Both machiens are Windows XP Pro SP2. What do I need to type at the command prompt to login to mysql on the other XP machine?

Create Dsn On Linux Machine
i am raghvendra. i am working on linux. i am using a php4 with apache 2 on linux machine. i want to create a dsn on linux machine. but i donot know how can i do this. my database is on remote windows machine.

Trouble With Export Of Access Table Into Mysql
I exported some tables out of access into mysql and I cant edit and records under mysql root account through mysql's query browser. I can edit from mysql command line using same credentials while working localy on the mysql server. Wondering why Query broswers Edit button is greyed out.

Configure 2 Sites To Access One User Table
I have two databases on the same server with different domains. I would like both sites to access the same user database table. They have the same fields.

I thought that it might just be done with an mysql command, which will point one table to the other.


Copyright © 2005-08 www.BigResource.com, All rights reserved