Re: Mysql database replication

2002-08-14 Thread Gerald Clark

I highly recommend you update the slave to the same version as the master.


Mark D. Wallace wrote:

 I'm trying to set up a replication database and cannot get the slave 
 to parse the log files on the master.
 The slave is connecting to the master as indicated in the log file.

 I have tried to connect directly to the master database from the mysql 
 client on the slave and have no problem using the replication username 
 and password.

 The master server is mysql-3.23.37-pc-linux-gnu-i686
 The slave server is mysql mysql-3.23.51-pc-linux-gnu-i686
 From the Mysql site, these two are compatible as a slave master pair.

 The error message from the slaves error log reads.


 14:28:38 Slave: connected to master '[EMAIL PROTECTED]:3306', 
 replication started in
 log 'FIRST' at position 4

 020813 14:28:38 Could not parse log event entry, check the master for 
 binlog corruption
 This may also be a network problem, or just a bug in
 the master or slave code.

 (WHAT IS THE NAME OF THE LOG FILE THE SLAVE IS TRYING TO READ 
 mysql.log?)

 020813 14:28:38 Error running query, slave aborted. Fix the problem, 
 and re-start the slave thread with
 mysqladmin start-slave. We stopped at log 'FIRST' position 4

 020813 14:28:38 Slave thread exiting, replication
 stopped in log 'FIRST' at position 4


 WHAT is log 'FIRST' at position 4 referencing?


 Thanks for any help you can provide.

 Mark Wallace


 -
 Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail 
 [EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php





-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Mysql database replication

2002-08-13 Thread Mark D. Wallace

I'm trying to set up a replication database and cannot get the slave to 
parse the log files on the master.
The slave is connecting to the master as indicated in the log file.

I have tried to connect directly to the master database from the mysql 
client on the slave and have no problem using the replication username and 
password.

The master server is mysql-3.23.37-pc-linux-gnu-i686
The slave server is mysql mysql-3.23.51-pc-linux-gnu-i686
 From the Mysql site, these two are compatible as a slave master pair.

The error message from the slaves error log reads.


14:28:38 Slave: connected to master '[EMAIL PROTECTED]:3306', 
replication started in
log 'FIRST' at position 4

020813 14:28:38 Could not parse log event entry, check the master for 
binlog corruption
This may also be a network problem, or just a bug in
the master or slave code.

(WHAT IS THE NAME OF THE LOG FILE THE SLAVE IS TRYING TO READ mysql.log?)

020813 14:28:38 Error running query, slave aborted. Fix the problem, and 
re-start the slave thread with
mysqladmin start-slave. We stopped at log 'FIRST' position 4

020813 14:28:38 Slave thread exiting, replication
stopped in log 'FIRST' at position 4


WHAT is log 'FIRST' at position 4 referencing?


Thanks for any help you can provide.

Mark Wallace


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




MySql Database Replication Question

2002-03-07 Thread Thi Cao

All,

How can I notify an application running on the slave server that the slave
database has just updated itself by means of replication.  The reason I ask
is that I know MySql currently doesn't support triggers, but my application
needs to be notified when an update on the slave has just taken place.  Once
again, thanks for your time.

Thi

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: MySql Database Replication Question

2002-03-07 Thread Jeremy Zawodny

On Thu, Mar 07, 2002 at 08:37:00AM -0600, Thi Cao wrote:
 All,
 
 How can I notify an application running on the slave server that the
 slave database has just updated itself by means of replication.  The
 reason I ask is that I know MySql currently doesn't support
 triggers, but my application needs to be notified when an update on
 the slave has just taken place.  Once again, thanks for your time.

Hm, that's a little unusual.   Could the application look at the
output of SHOW SLAVE STATUS once in a while, maybe?
-- 
Jeremy D. Zawodny, [EMAIL PROTECTED]
Technical Yahoo - Yahoo Finance
Desk: (408) 349-7878   Fax: (408) 349-5454   Cell: (408) 685-5936

MySQL 3.23.47-max: up 28 days, processed 988,263,631 queries (407/sec. avg)

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: MySql Database Replication Question

2002-03-07 Thread Thi Cao

Jeremy,

I'm not sure I follow.  What information from that command would the app be
looking for specifically.  Maybe you're saying the app should look at the
position of the master's binary log file.  Is that what you suggest?

Thi

-Original Message-
From: Jeremy Zawodny [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 07, 2002 10:42 AM
To: Thi Cao
Cc: MySQL
Subject: Re: MySql Database Replication Question


On Thu, Mar 07, 2002 at 08:37:00AM -0600, Thi Cao wrote:
 All,
 
 How can I notify an application running on the slave server that the
 slave database has just updated itself by means of replication.  The
 reason I ask is that I know MySql currently doesn't support
 triggers, but my application needs to be notified when an update on
 the slave has just taken place.  Once again, thanks for your time.

Hm, that's a little unusual.   Could the application look at the
output of SHOW SLAVE STATUS once in a while, maybe?
-- 
Jeremy D. Zawodny, [EMAIL PROTECTED]
Technical Yahoo - Yahoo Finance
Desk: (408) 349-7878   Fax: (408) 349-5454   Cell: (408) 685-5936

MySQL 3.23.47-max: up 28 days, processed 988,263,631 queries (407/sec. avg)

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: MySQL Database Replication

2002-03-07 Thread ds

On Wed, 2002-03-06 at 14:26, Thi Cao wrote:
 When I grant privileges as follows, the slave gets updated:
 
 GRANT FILE ON *.* to repl@'%' identified by 'some_password';
 
 Could someone please tell me why I must grant the FILE privilege on all
 databases for the repl (slave) to be able to update one particular database?

MySQL Manual:
4.2.7 Privileges Provided by MySQL:

The file privilege gives you permission to read and write files on the
server using the LOAD DATA INFILE and SELECT ... INTO OUTFILE
statements. Any user to whom this privilege is granted can read or write
any file that the MySQL server can read or write.

4.10.3 How To Set Up Replication
2.  Set up special a replication user on the master with the FILE 
privilege and permission to connect from all the slaves. If the user is
only doing replication (which is recommended), you don't need to grant
any additional privileges. For example, to create a user named repl
which can access your master from any host, you might use this command:
GRANT FILE ON *.* TO repl@% IDENTIFIED BY 'password';


 
 Thi Cao wrote:
  
  Hello everyone,
  
  This is my first attempt at MySQL database replication.  Can't seem to get
  it to work yet.  The problem reported in the error log of the slave server
  is as follows:
  
  Error reading packet from server:  Access denied for user
 'repl@slave_host'
  (Using password: YES) (read_errno 0,server_errno=1045)
  
  I believe it has something to do with the way I granted privileges to the
  user repl.  I did the following:
  
  GRANT FILE ON dbname.* to repl@'%' identified by 'some_password';
  
 
 Did you do a FLUSH PRIVILIGES after that?  That is needed in some cases.


You don't need to flush privileges when using grant/revoke commands.


-- 
dsoares
(sql)

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: MySQL Database Replication

2002-03-07 Thread Thi Cao

ds,

If I understand you correctly, that also means that the user repl can access
the mysql database where all the privilege info is stored and see the
permissions, passwords, and such.  Yes/No?

Thi


-Original Message-
From: ds [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 07, 2002 11:02 AM
To: Thi Cao
Cc: MySQL
Subject: RE: MySQL Database Replication


On Wed, 2002-03-06 at 14:26, Thi Cao wrote:
 When I grant privileges as follows, the slave gets updated:
 
 GRANT FILE ON *.* to repl@'%' identified by 'some_password';
 
 Could someone please tell me why I must grant the FILE privilege on all
 databases for the repl (slave) to be able to update one particular
database?

MySQL Manual:
4.2.7 Privileges Provided by MySQL:

The file privilege gives you permission to read and write files on the
server using the LOAD DATA INFILE and SELECT ... INTO OUTFILE
statements. Any user to whom this privilege is granted can read or write
any file that the MySQL server can read or write.

4.10.3 How To Set Up Replication
2.  Set up special a replication user on the master with the FILE 
privilege and permission to connect from all the slaves. If the user is
only doing replication (which is recommended), you don't need to grant
any additional privileges. For example, to create a user named repl
which can access your master from any host, you might use this command:
GRANT FILE ON *.* TO repl@% IDENTIFIED BY 'password';


 
 Thi Cao wrote:
  
  Hello everyone,
  
  This is my first attempt at MySQL database replication.  Can't seem to
get
  it to work yet.  The problem reported in the error log of the slave
server
  is as follows:
  
  Error reading packet from server:  Access denied for user
 'repl@slave_host'
  (Using password: YES) (read_errno 0,server_errno=1045)
  
  I believe it has something to do with the way I granted privileges to
the
  user repl.  I did the following:
  
  GRANT FILE ON dbname.* to repl@'%' identified by 'some_password';
  
 
 Did you do a FLUSH PRIVILIGES after that?  That is needed in some cases.


You don't need to flush privileges when using grant/revoke commands.


-- 
dsoares
(sql)

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: MySQL Database Replication

2002-03-07 Thread Luc Foisy

rep1 would gain FILE access to all ( not sure what the really entails )
it would not have SELECT access, so can not read from it

mind you if they have enough info to get in with rep1 access, then they
could just replicate everything on thier own server and read till thier
hearts content

-Original Message-
From: Thi Cao [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 07, 2002 12:04 PM
To: Thi Cao
Cc: MySQL
Subject: RE: MySQL Database Replication


ds,

If I understand you correctly, that also means that the user repl can access
the mysql database where all the privilege info is stored and see the
permissions, passwords, and such.  Yes/No?

Thi


-Original Message-
From: ds [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 07, 2002 11:02 AM
To: Thi Cao
Cc: MySQL
Subject: RE: MySQL Database Replication


On Wed, 2002-03-06 at 14:26, Thi Cao wrote:
 When I grant privileges as follows, the slave gets updated:
 
 GRANT FILE ON *.* to repl@'%' identified by 'some_password';
 
 Could someone please tell me why I must grant the FILE privilege on all
 databases for the repl (slave) to be able to update one particular
database?

MySQL Manual:
4.2.7 Privileges Provided by MySQL:

The file privilege gives you permission to read and write files on the
server using the LOAD DATA INFILE and SELECT ... INTO OUTFILE
statements. Any user to whom this privilege is granted can read or write
any file that the MySQL server can read or write.

4.10.3 How To Set Up Replication
2.  Set up special a replication user on the master with the FILE 
privilege and permission to connect from all the slaves. If the user is
only doing replication (which is recommended), you don't need to grant
any additional privileges. For example, to create a user named repl
which can access your master from any host, you might use this command:
GRANT FILE ON *.* TO repl@% IDENTIFIED BY 'password';


 
 Thi Cao wrote:
  
  Hello everyone,
  
  This is my first attempt at MySQL database replication.  Can't seem to
get
  it to work yet.  The problem reported in the error log of the slave
server
  is as follows:
  
  Error reading packet from server:  Access denied for user
 'repl@slave_host'
  (Using password: YES) (read_errno 0,server_errno=1045)
  
  I believe it has something to do with the way I granted privileges to
the
  user repl.  I did the following:
  
  GRANT FILE ON dbname.* to repl@'%' identified by 'some_password';
  
 
 Did you do a FLUSH PRIVILIGES after that?  That is needed in some cases.


You don't need to flush privileges when using grant/revoke commands.


-- 
dsoares
(sql)

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: MySQL Database Replication

2002-03-06 Thread Thi Cao

Yes, I did flush the privileges when nothing else worked but that didn't do
the trick either.  Thanks for trying.

-Original Message-
From: James Housley [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, March 05, 2002 6:00 PM
To: Thi Cao
Cc: MySQL
Subject: Re: MySQL Database Replication


Thi Cao wrote:
 
 Hello everyone,
 
 This is my first attempt at MySQL database replication.  Can't seem to get
 it to work yet.  The problem reported in the error log of the slave server
 is as follows:
 
 Error reading packet from server:  Access denied for user
'repl@slave_host'
 (Using password: YES) (read_errno 0,server_errno=1045)
 
 I believe it has something to do with the way I granted privileges to the
 user repl.  I did the following:
 
 GRANT FILE ON dbname.* to repl@'%' identified by 'some_password';
 

Did you do a FLUSH PRIVILIGES after that?  That is needed in some cases.

Jim
-- 
/\   ASCII Ribbon Campaign  .
\ / - NO HTML/RTF in e-mail  .
 X  - NO Word docs in e-mail .
/ \ -
[EMAIL PROTECTED]  http://www.FreeBSD.org The Power to Serve
[EMAIL PROTECTED]  http://www.TheHousleys.net
[EMAIL PROTECTED]  http://www.SimTel.Net
-
Studies show that 1 out of every 4 Americans suffer some form of
mental illness.  So look at your three best friends, if they
are okay it is YOU!

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: MySQL Database Replication

2002-03-06 Thread Thi Cao

When I grant privileges as follows, the slave gets updated:

GRANT FILE ON *.* to repl@'%' identified by 'some_password';

Could someone please tell me why I must grant the FILE privilege on all
databases for the repl (slave) to be able to update one particular database?

Thanks everyone.

Thi

-Original Message-
From: James Housley [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, March 05, 2002 6:00 PM
To: Thi Cao
Cc: MySQL
Subject: Re: MySQL Database Replication


Thi Cao wrote:
 
 Hello everyone,
 
 This is my first attempt at MySQL database replication.  Can't seem to get
 it to work yet.  The problem reported in the error log of the slave server
 is as follows:
 
 Error reading packet from server:  Access denied for user
'repl@slave_host'
 (Using password: YES) (read_errno 0,server_errno=1045)
 
 I believe it has something to do with the way I granted privileges to the
 user repl.  I did the following:
 
 GRANT FILE ON dbname.* to repl@'%' identified by 'some_password';
 

Did you do a FLUSH PRIVILIGES after that?  That is needed in some cases.

Jim
-- 
/\   ASCII Ribbon Campaign  .
\ / - NO HTML/RTF in e-mail  .
 X  - NO Word docs in e-mail .
/ \ -
[EMAIL PROTECTED]  http://www.FreeBSD.org The Power to Serve
[EMAIL PROTECTED]  http://www.TheHousleys.net
[EMAIL PROTECTED]  http://www.SimTel.Net
-
Studies show that 1 out of every 4 Americans suffer some form of
mental illness.  So look at your three best friends, if they
are okay it is YOU!

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




MySQL Database Replication

2002-03-05 Thread Thi Cao

Hello everyone,

This is my first attempt at MySQL database replication.  Can't seem to get
it to work yet.  The problem reported in the error log of the slave server
is as follows:

Error reading packet from server:  Access denied for user 'repl@slave_host'
(Using password: YES) (read_errno 0,server_errno=1045)


I believe it has something to do with the way I granted privileges to the
user repl.  I did the following:

GRANT FILE ON dbname.* to repl@'%' identified by 'some_password';

In the slave config file, I have the correct password to connect to the
master, so I don't believe that that is the problem.  Also included in the
config file is replicate-do-db=dbname.

If someone has any idea of what I can or should do, your help would be much
appreciated.  If not, thanks for your time.

Thi


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: MySQL Database Replication

2002-03-05 Thread James Housley

Thi Cao wrote:
 
 Hello everyone,
 
 This is my first attempt at MySQL database replication.  Can't seem to get
 it to work yet.  The problem reported in the error log of the slave server
 is as follows:
 
 Error reading packet from server:  Access denied for user 'repl@slave_host'
 (Using password: YES) (read_errno 0,server_errno=1045)
 
 I believe it has something to do with the way I granted privileges to the
 user repl.  I did the following:
 
 GRANT FILE ON dbname.* to repl@'%' identified by 'some_password';
 

Did you do a FLUSH PRIVILIGES after that?  That is needed in some cases.

Jim
-- 
/\   ASCII Ribbon Campaign  .
\ / - NO HTML/RTF in e-mail  .
 X  - NO Word docs in e-mail .
/ \ -
[EMAIL PROTECTED]  http://www.FreeBSD.org The Power to Serve
[EMAIL PROTECTED]  http://www.TheHousleys.net
[EMAIL PROTECTED]  http://www.SimTel.Net
-
Studies show that 1 out of every 4 Americans suffer some form of
mental illness.  So look at your three best friends, if they
are okay it is YOU!

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: MySQL Database Replication

2001-05-24 Thread Jeremy Zawodny

On Sat, May 19, 2001 at 01:18:42PM -0500, David Gullett wrote:
 
 I have 10 or so MySQL servers in the field, all writing data to a
 database of the same name.  I would like to set up replication from
 all masters back to a single slave server and have each master write
 to a different database.  Is there an easy way to do this, short of
 running multiple instances of MySQL on the slave server?

Currently, each slave can only have a single master. So you're looking
at multiple slave instances.

If you don't need completely real-time replication, you might consider
rsync or something similar.

Jeremy
-- 
Jeremy D. Zawodny, [EMAIL PROTECTED]
Technical Yahoo - Yahoo Finance
Desk: (408) 349-7878Fax: (408) 349-5454Cell: (408) 439-9951

MySQL 3.23.29: up 5 days, processed 35,090,354 queries (79/sec. avg)

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




MySQL Database Replication

2001-05-19 Thread David Gullett


I have 10 or so MySQL servers in the field, all writing data to a database
of the same name.  I would like to set up replication from all masters back
to a single slave server and have each master write to a different database.
Is there an easy way to do this, short of running multiple instances of
MySQL on the slave server?

Thanks,

David Gullett
Circuits Maximus, LLC.


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php