Return-Path: X-Original-To: apmail-cloudstack-users-archive@www.apache.org Delivered-To: apmail-cloudstack-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E08E4195B5 for ; Mon, 25 Apr 2016 11:04:47 +0000 (UTC) Received: (qmail 50243 invoked by uid 500); 25 Apr 2016 11:04:41 -0000 Delivered-To: apmail-cloudstack-users-archive@cloudstack.apache.org Received: (qmail 50113 invoked by uid 500); 25 Apr 2016 11:04:41 -0000 Mailing-List: contact users-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@cloudstack.apache.org Delivered-To: mailing list users@cloudstack.apache.org Received: (qmail 50049 invoked by uid 99); 25 Apr 2016 11:04:40 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Apr 2016 11:04:40 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 9907C18028C; Mon, 25 Apr 2016 11:04:39 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.664 X-Spam-Level: ** X-Spam-Status: No, score=2.664 tagged_above=-999 required=6.31 tests=[FSL_HELO_BARE_IP_2=1.499, KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_NUMERIC_HELO=0.865] autolearn=disabled Received: from mx2-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id YLJiECXhfgw3; Mon, 25 Apr 2016 11:04:36 +0000 (UTC) Received: from smtp02.mail.pcextreme.nl (smtp02.mail.pcextreme.nl [109.72.87.139]) by mx2-lw-eu.apache.org (ASF Mail Server at mx2-lw-eu.apache.org) with ESMTPS id 06B0D60D2C; Mon, 25 Apr 2016 11:04:36 +0000 (UTC) Received: from 109.72.87.221 (ox01.pcextreme.nl [109.72.87.221]) by smtp02.mail.pcextreme.nl (Postfix) with ESMTPSA id DE0E8410FD; Mon, 25 Apr 2016 13:04:29 +0200 (CEST) Date: Mon, 25 Apr 2016 13:04:29 +0200 (CEST) From: Wido den Hollander To: anil lakineni , dev@cloudstack.apache.org, users@cloudstack.apache.org Message-ID: <1941372718.383.1461582269902@ox.pcextreme.nl> In-Reply-To: References: Subject: Re: mysql-bin log files eating more space and DB server root fs filling up now at 98% MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Priority: 3 Importance: Medium X-Mailer: Open-Xchange Mailer v7.8.1-Rev8 X-Originating-Client: open-xchange-appsuite > Op 25 april 2016 om 12:28 schreef anil lakineni : > > > Hi All, > > In Cloud DB server, the root file system reached to 98% and found that > */var/lib/mysql/* is consumed with more space. > > Inside that specified directory i found that " *mysql bin logs* " are > eating more space and files are there since one year. > > My environment has enabled with DB replication. > > Is it safe to purge the older mysql bin logs ? if yes, Could you please > paste the working steps here which wouldn't affect replication as some > blogs are saying that replication will be affected if we purge. > Yes, you can remove them. Just use 'rm' to remove the old logs. > *Please recommend best solution that was already worked on production > environment* > > So please suggest me the process to free up some space and clean up mysql > bin logs. > I recommend you search a bit on this topic. It is not CloudStack-specific, the MySQL documentation will tell you how to do this. > P.S. I have verified other directories and logs, they are consuming very > little space except this bin logs directory (not *ibdata1* file). > > Cloud version is 4.5 and MySQL version is " 5.1.73-log " > > My MySQL configuration file is, > > #cat /etc/my.cnf > *[mysqld]* > *datadir=/var/lib/mysql* > *socket=/var/lib/mysql/mysql.sock* > *user=mysql* > *# Disabling symbolic-links is recommended to prevent assorted security > risks* > *symbolic-links=0* > > *innodb_rollback_on_timeout=1* > *innodb_lock_wait_timeout=600* > *max_connections=1400* > *log-bin=mysql-bin* > *binlog-format = 'ROW'* > *innodb_buffer_pool_size=5500m* > > *default-character-set=utf8* > *default-collation=utf8_unicode_ci* > *character-set-server=utf8* > *collation-server=utf8_unicode_ci* > *default-time-zone='+03:00'* > > *# for Master / Slave* > *server-id = 1* > > *[mysqld_safe]* > *log-error=/var/log/mysqld.log* > *pid-file=/var/run/mysqld/mysqld.pid* > > > Please let me know if any other information needed and please suggest the > process that would cleanup old logs automatically by mysql. > > Hope will get some help here.. > > Regards, > Anil.