MySQL 5.1 : The Second Major Release of MySQL 5

learn more… | top users | synonyms

3
votes
1answer
1k views

Take individual MySQL database offline

MySQL does not have any SQL commands or internal mechanisms for making an individual database unavailable / offline moving an individual database Thtis being the case, how can you take an ...
1
vote
1answer
29 views

MySQL After Update Trigger apparently not running

I have the following After Update trigger on a MySQL table: CREATE DEFINER = 'root'@'localhost' TRIGGER phpbb_rathermenacing.phpbb_bbdkp_memberlist_AUPD AFTER UPDATE ON ...
1
vote
1answer
2k views

statistics State in MySQL Processlist

I have a busy MySQL Server having query SELECT sys_sess_state, index_state, timeout_lvl, last_queued_dt, last_polled_wait_dt, create_id, create_dt, modify_id, modify_dt FROM PQR_AM_SYSTEM_SESSION ...
1
vote
1answer
101 views

How big is a tmp table?

I've got an RDF table in MySQL 5.1 with the MyISAM engine. Here's the table definition: CREATE TABLE `node` ( `id` bigint(20) NOT NULL AUTO_INCREMENT, `graph` varchar(100) CHARACTER SET latin1 ...
0
votes
1answer
22 views

I'm trying to restore single database from mysqldump all-databases with different name

I'm running mysql-server-5.1.73-3.el6_5.x86_64: mysql> SELECT VERSION(); +------------+ | VERSION() | +------------+ | 5.1.73-log | +------------+ 1 row in set (0.00 sec) mysql> I created ...
0
votes
1answer
20 views

How to restore MySQL database from Files

Primary hard disk where MySQL (version 5.1) was installed is crashed and I had to re install entire OS. I have all the files including ibdata1 file. How do I go about recreating and attaching database ...
0
votes
1answer
37 views

MySQL: How turning off the logging affect the performance?

OS: RHEL5 DB: MySQL 5.1.73 community edition DB size: ~1GB I have setup a testing environment and turned off all logging - general logs, binary logs, slow query logs etc. I am using Oracle ...
0
votes
1answer
68 views

MySQL 5.1: change datadir variable value in my.cnf

Below is my system configuration: OS: RHEL5 MySQL: 5.1.73 Default datadir=/var/lib/mysql/ But, the above directory has space crunch. So, I decided to change the path. I found /u000 directory has ...
0
votes
1answer
34 views

MySQL 5.1: How to rollback partitioned table

I have partitioned a table on the basis of one flag column have value either 0 or 1. Now, I want to roll back these tables. How can I do this?
0
votes
1answer
96 views

Whether to use or not to use: DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP

In one Database table, created_at & updated_at are defined as: `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP `updated_at` timestamp NOT NULL DEFAULT ...
0
votes
1answer
229 views

How to configure my.cnf for Mysql 5.1, which is using too much CPU?

I am new Database engineer. I am having trouble in my server which is using too much CPU on database query(simple count statement). I have googled about it, so i found out it depends on system ...
0
votes
1answer
42 views

Extract one MySQL database from a FULL MYSQL Server backup file

I have a small shared windows server on which i'have installed MySQL 5.1 engine for hosting my user's mysql databases. I backup the complete MySQL databases each day by running this script as batch ...
0
votes
1answer
43 views

Insert into a view derived from a table with a discriminator field

I am in a situation in which I have a base table with some fields and a discriminator field which could have one out of a specific set of values. From that base table, I have derived many views, one ...
0
votes
1answer
53 views

How to avoid/prevent Aborted Connections in mysql

We are using MySQL Version 5.1.73. Database is getting huge number of connections around 600 at one time. I observed Aborted Connections are getting increased from Global Status variables. So I ...
0
votes
1answer
132 views

How can i import 150GB database after deleting ibdata1,logfile in MYSQL?

I have 150GB database and my ibdata1 file size is 240GB so i want shrink the ibdata1 file so for that i have to export the DB and then drop the tables and then stop mysql, delete the ibdata1 file and ...
0
votes
1answer
217 views

MySQL: Prevent DROP TABLE and TRUNCATE TABLE on Slaves

Can someone tell me how to prevent the following commands DROP TABLE <tbl-name>; TRUNCATE TABLE <tbl-name>; from being replicated to slaves?
0
votes
1answer
377 views

The total number of locks exceeds the lock table size, even after increasing buffer pool size

I am trying to partition a table with 200 million records in it. This table already exists: CREATE TABLE linkmap_ntoken ( target_nToken varchar(200) NOT NULL, ntoken_hashcode int(15) NOT NULL, ...
0
votes
1answer
95 views

Help interpreting a MySQL execution plan

I'm trying to understand a slow query. The SELECT has been running (at this moment) for almost 18000 seconds (output from a SELECT on PROCESSLIST): id: 22 time: 17870 ...
0
votes
1answer
494 views

Why does max_connections in my.ini not match concurrent connections in Mysql instance config wizard?

MySQL 5.1.x | Windows Server 2003 Can someone please clarify why max_connections in my.ini is much larger than the manual value I specify in the Concurrent Connections Dialogue? For example, if I ...
1
vote
0answers
43 views

MySQL 5.1 High Cpu usage on CentOS 6

I am running MySQL 5.1 on a CentOS 6 server with 16G ram. I got also apache on it. MySQL is constantly using too much cpu. top - 17:40:36 up 112 days, 12:13, 1 user, load average: 1.24, 1.72, 1.82 ...
1
vote
0answers
30 views

Merge/combine two queries with different dates

I have one query that runs a SUM statement based on daterange 1, and worked fine, and another query that run same SUM statement, but on a different date range. I would like to merge/combine the two ...
1
vote
0answers
67 views

MySQL: Sometimes query failed to use index

I have a complex query including join of 4-5 tables. 1 months back, I have optimized this query and it was using the index. Also, two months back, index of all tables had been rebuilt by just export ...
1
vote
0answers
203 views

why is this query taking so long?

+----+-------------+-----------+----------+---------+------+----------+--------------------------------------------------------+ | Id | User | Host | db | Command | Time | State | ...
1
vote
0answers
159 views

Fulltext search returning too many rows

Server: MySQL 5.1.66-0+squeeze1 My problem: I have two databases with the same tables. One is for the testing environment and one for production. When I perform a MATCH AGAINST on the prodution ...
1
vote
0answers
163 views

Database instance keeps restarting

From the past few days, our MySQL database instance has crashed and had to be restarted a few times. My MySQL version is 5.1.57-log. The CPU and memory usage was way below 50% during the crash time. I ...
1
vote
0answers
36 views

How does MySQL 5.1 use indexes?

I've read the docs for MySQL v5.1.x on how about the indexes are used, but I'm not sure I understood it properly. Suppose having the following MySQL table: CREATE TABLE IF NOT EXISTS ...
0
votes
0answers
14 views

Get upcoming Birthdays including Jan 1st

I currently have a script that can get up-and-coming birthdays within "x" number of days: SELECT * FROM persons WHERE datediff(date_add(birthday, INTERVAL (YEAR(curdate()) - YEAR(birthday)) YEAR), ...
0
votes
0answers
10 views

Change MAMP to use a lower Mysql 5.1 version

I need to have the same development environment for my PHP program. My clients test server is running on Mysql 5.1 while my local is using MAMP running Mysql 5.5. How do downgrade my mysql database ...
0
votes
0answers
38 views

MySQL replication working, but data is out of date

I'm trying to figure out why even though SHOW SLAVE STATUS isn't reporting any errors, nothing is replicating (see below): both nodes are running: mysql> SELECT VERSION(); +------------+ | ...
0
votes
0answers
20 views

Text comparison select query needed that finds most whole word matches within larger string

I have a database of products, many with similar names. For example... iPhone 5s (GSM model) A1533 iPhone 5s (GSM model China) A1518 iPhone 5s (GSM model China) A1530 iPhone 5c (GSM model) ...
0
votes
0answers
15 views

Replication is broken because of events in wrong order in binlog

I have a master-master replication which is used rather like a master-slave because of replication breaks from time to time. It is always broken on the same table. To find the reason on this problem I ...
0
votes
0answers
8 views

Large data migration from DBO to DBO - memory & time efficient?

I need to migrate data from one database (Mysql vendor, used as Alfresco DB) to custom designed Mysql DB used for reporting. Both DB's are on same DB host. My initial idea was to use view as data ...
0
votes
0answers
14 views

Can it Possible to do Mysql Active - Active Replication between Redaht linux 6.4X and Ubuntu 12X?

I have small doubt regarding Mysql Active-Active Replication. Can it Possible to do Mysql Master-Master (Active-Active) replication in Mysql between Redhat Linux and Ubuntu? Thanks & regards, ...
0
votes
0answers
34 views

mysql logs same query multiple times or is it application problem?

I have temporarily switched on logging on the server. The site is used in the US and local time there was 4 in the morning so not many people are using it at that time. What I did was delete any logs ...
0
votes
0answers
18 views

Analize Query in MySQL Server 5.1

I try use MySQL Workbench 6 to analyze the cost, but they don't show the cost of query. How i get this costs?
0
votes
0answers
33 views

Switching from Windows to LINUX server with lower configuration

As of now, My application is running on dedicated windows DB server which configuration is below: RAM 8.00 GB Processor Intel(R) Xeon(R) CPU X5460 @3.16GHz, OS Windows Server ...
0
votes
0answers
39 views

MySql - multi-column index using only null values from one column

I have a Innodb table with a index that looks at 3 columns. ColA is integer and always has a value. ColB is varchar and always has a value. ColC is datetime and sometimes has a value (NULL). My ...
0
votes
0answers
41 views

MySQL grant select not working properly 5.1.73-log

I have created new users with GRANTS SELECT but this is not applied and still user have full privileges and can still DELETE, DROP, INSERT. SHOW GRANTS for dbreader; GRANT SELECT ON *.* TO ...
0
votes
0answers
43 views

MySQL Server constantly crashes

my apologies for having already posted on this issue, but it has moved on so far I feel a new question is the only way to go. First a little history - I have a MySQL server which runs a few small ...
0
votes
0answers
30 views

On replicating all tables of a given database except for those starting with some pattern

I'd like a slave to replicate all tables of a given database except for those starting with some pattern, eg. those with names starting with 'nc' (non-critical, redundant denormalized tables). So I ...
0
votes
0answers
137 views

Best way to select rows containing a substring

I've a table named comments where comment is a field where comment will be stored. Now I want to find -1 within that comment. the -1 should be independent. That is, it should not be joined with ...
0
votes
0answers
16 views

MySQL: How logging is useful in performance improvement

My application is facing performance hit. Its a MySQL-5.1.55 version. I am using Windows 2008 dedicated server with 8 GB for the database. There is only one database in this whole system. Till now, I ...
0
votes
0answers
32 views

MySQL: system variables and status variables related with Disk I/O

How disk I/O is related with MySQL performance improvement. I have a MySQL-5.1.58 based Intranet application equipped with Windows 2008 server and 8 GB RAM. Even, When my application face performance ...
0
votes
0answers
144 views

MySQL: how to determine key_len and its role in performance improvement of a query

I have a query, below is the structure of the table: CREATE TABLE `jos_tag_rules_fields` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(255) NOT NULL DEFAULT '', `label` varchar(255) ...
0
votes
0answers
183 views

MySQL: How to get locked tables list at a time

Is there any way or any query exist in mysql which list down all the locked tables at a time. I have dedicated Windows 2008 DB server with 8GB memory. In my MySQL5.1 based application, suddenly we get ...
0
votes
0answers
160 views

MySQl: slow query is not using index in joining

Below is the configuration of my DB server: Apache version : Apache/2.2.22 (Win32) mod_ssl/2.2.22 OpenSSL/0.9.8 PHP version : 5.3.13 MySQL version : mysqlnd 5.1.11 Windows Server 2008 Standard ...
0
votes
0answers
62 views

Understanding how MySQL indexes work

I'm reading this page but I can't get past the following parts: When all tables are processed, MySQL outputs the selected columns and backtracks through the table list until a table is found ...
0
votes
0answers
853 views

MySQL: High sort_buffer_size setting value

Thing is I was getting plenty of 131104 20:10:36 [ERROR] /usr/sbin/mysqld: Sort aborted with 256M and rather erratic behaviour in my load test. Now at sort_buffer_size = 1024M ...
0
votes
0answers
54 views

Accidentally I had deleted a database from production server working with MySQL

I have its backup as a full and an incremental backup took using enterprise backup. Is it possible to restore a specific database or else what should I do as an immediate action?
0
votes
0answers
65 views

InnoDB data back in 3 months after OS shutdown

I've got an interesting issue last week that after shutting down an instance of mine, all data were back in 3 months (like a big rollback), even though there is no sign of crashing, recovery crash ...