Solved

use mysqlbinlog to read from remote server binlog files -- what is wrong?

Posted on 2008-06-18
3
884 Views
Last Modified: 2013-12-16
Hi anyone _EVER_ able to get mysqlbinlog to remotely read a server's binlog?
I have read http://dev.mysql.com/doc/refman/5.0/en/mysqlbinlog.html
and the command I use is:
=====================
mysqlbinlog --read-from-remote-server  --database=mydbname --start-datetime="2008-06-11 00:00:00" --stop-datetime="2008-06-16 23:59:59" -hremotehost -umyusername -pmypassword -rmyresult.txt
====================
remote host running default 3306.
and if I ssh to the server then I can read it successfully for that time period, by specifying the path & name of input binlogs.
however it did not give me result, but poping me the manpage of mysqlbinlog.
It looks like the format I am using is wrong womewhere.
Do I need to specify binlog path when reading remotely? --I don't think it makes sense in this way.
so where is wrong?
0
Comment
Question by:loadover
3 Comments
 
LVL 77

Accepted Solution

by:
arnold earned 500 total points
ID: 21815564
You are not listing the log_filenames where it should look.
Presumably when you are on the local machine you are in the directory where the log files are when you run the command.

Try this where /var/mysql/log is the location for the binlog files.
mysqlbinlog --read-from-remote-server  --database=mydbname --start-datetime="2008-06-11 00:00:00" --stop-datetime="2008-06-16 23:59:59" -hremotehost -umyusername -pmypassword -rmyresult.txt /var/mysql/log/*

Open in new window

0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
Fine Tune your automatic Updates for Ubuntu / Debian
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

896 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now