LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-08-2014, 09:11 AM   #16
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49

Here's the show slave status from the server from the original post

Slave_IO_State: Waiting for master to send event

Then further down it has
Last_Error: Error 'Table 'Testingdb.objectcache' doesn't exist' on query
 
Old 05-08-2014, 09:13 AM   #17
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
I think I'm going to try turning off this server, see if anything breaks. I have one final question though. You said "the master will continue to log replication regardless". But what happens if none of the slaves are running to read that logged info, will those files just build up on the master, or is there some sort of auto purge setup (or that you can setup) on those files that I should check to avoid my server running out of space?
 
Old 05-08-2014, 09:14 AM   #18
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,460

Rep: Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552
Quote:
Originally Posted by rjo98 View Post
Here's the show slave status from the server from the original post

Slave_IO_State: Waiting for master to send event

Then further down it has
Last_Error: Error 'Table 'Testingdb.objectcache' doesn't exist' on query
Looks like replication was set up but broke at some point.
 
Old 05-08-2014, 09:17 AM   #19
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,460

Rep: Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552
Quote:
Originally Posted by rjo98 View Post
You said "the master will continue to log replication regardless". But what happens if none of the slaves are running to read that logged info, will those files just build up on the master, or is there some sort of auto purge setup (or that you can setup) on those files that I should check to avoid my server running out of space?
The server will indeed keep building those files up, they aren't flushed when the slaves read them either, they keep building up and building up.


Somewhere in your my.cnf there will be a expire_logs_days= directive. This specifies how long your master will keep the replication information for. https://dev.mysql.com/doc/refman/5.0...pire_logs_days
 
Old 05-08-2014, 09:31 AM   #20
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
Yeah, and seems like it was for a non-important db also just based on the name, definitely not one of the db's that worries me.

I don't see that parameter in my my.cnf though
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql

# replication
log-bin=mysql-bin
server-id=1

[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

When I look in /var/lib/mysql though, I only see 20some mysql-bin.###### files, and they're all at least 1MB, of which 9 are from this year. Should I even worry about it?
 
Old 05-08-2014, 09:32 AM   #21
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,460

Rep: Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552
From the information provided it really does look like it's unused.
 
Old 05-08-2014, 09:35 AM   #22
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
Yeah, this server does host a database we do use, but only like once a month really, so maybe that explains the small number of those files. and since they're so small, maybe i'm worrying over nothing.

I have the server from my original post turned off since it doesn't seem like much was going on there anyway, and this "real" server doesn't seem like it'll fill up with those replication files anytime soon, so unless someone screams that something isn't working, I think I'm in good shape. would you agree?
 
Old 05-08-2014, 09:38 AM   #23
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,460

Rep: Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552
The whole "turn it off and see who yells" approach to obsolete server hunting Hope it works out for you.

Personally I'd be tempted to take an image (clonezilla!!!!!!) of the slave for safety.
 
Old 05-08-2014, 09:41 AM   #24
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
Oh yeah, gotta love that old trick haha I hope it works out too :-)

I just shutdown -h the slave/server I hope we don't need anymore. Luckily I know it starts up fine, so I'm just going to let it sit there for a long time before we actually get rid of it. call me paranoid.

I never used clonezilla before. Would that let me image it and load it up on my laptop in VirtualBox or something like that?
 
Old 05-08-2014, 09:44 AM   #25
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,460

Rep: Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552Reputation: 1552
clonezilla will create a set of files that are exact images of the disk partitions. In the past I've created a Citrix XenServer virtual machine from clonezilla images, I'm sure using VirtualBox is an option too.
 
Old 05-08-2014, 09:46 AM   #26
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
ok, I might have to check that out. it'd be pretty cool if I could run the server from my machine if I needed to. I did make a tgz of the /var/lib/MySQL directory before I turned it off. not sure why, but sounded like a good idea.
 
Old 05-08-2014, 12:26 PM   #27
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,912

Rep: Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513
Have you looked at the server logs? They seem to record when there has been a connection to the database, as well as replication logs, and it even appears to have statement logs of user activity.

https://dev.mysql.com/doc/refman/4.1...rver-logs.html
 
Old 05-08-2014, 12:39 PM   #28
anon091
Senior Member
 
Registered: Jun 2009
Posts: 1,795

Original Poster
Rep: Reputation: 49
I look in /var/log at some stuff, but i think the last time anything was actually used on this was way past what's in there.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Databases/ MySQL... spoovy General 9 04-26-2010 12:43 AM
LXer: How To Back Up MySQL Databases Without Interrupting MySQL LXer Syndicated Linux News 0 05-14-2007 09:16 AM
List databases in MySQL vital_101 Linux - Server 2 11-08-2006 06:26 PM
restoring mysql databases? and mysql permissions... armegeden Linux - Software 0 03-13-2003 11:04 AM
mysql databases k3v0 Linux - Software 2 12-03-2002 07:41 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:15 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration