t H [mailto:[EMAIL PROTECTED]
> Sent: Thursday, November 13, 2003 12:30 PM
> To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Subject: Re: maintaining size of a db
>
>
> Got it Harald, thanks. OK, I've got this working
> now, so I'll do a quick overview of what I've
&
Got it Harald, thanks. OK, I've got this working
now, so I'll do a quick overview of what I've
learned... for the archives:
I am setting up mysql with msyslog to be a
centralized logging server. My servers (Windows
& Red Hat) will send their logs to this mysql
box. To keep the mysql db from gro
sql
> >
> > see:
> > http://www.mysql.com/doc/en/Batch_mode.html
> >
> > > -Original Message-
> > > From: Scott H
> > [mailto:[EMAIL PROTECTED]
> > > Sent: Wednesday, November 12, 2003 4:22 PM
> > > To: Dan Greene
> >
MAIL PROTECTED]
> > Sent: Wednesday, November 12, 2003 4:22 PM
> > To: Dan Greene
> > Cc: MySQL Mailing List
> > Subject: RE: maintaining size of a db
> >
> >
> > Cool idea, but I don't think you can really
> do
> > it. When I try, mysql just
on
> > > > > average it takes to hit 20GB
> > > > >
> > > > > let's say it's 89 days.
> > > > >
> > > > > right off the top, take 10% off for
> safety,
> > > now
> > > > > we're at 80 days
> >
2003 3:17 PM
> To: Michael McTernan; Dan Greene
> Cc: MySQL Mailing List
> Subject: RE: maintaining size of a db
>
>
> Well, it sort of helps. But that section is
> about future enhancements intended for mysql. I
> need to set something up now, with the current
> stable ver
> delete from log_table WHERE TO_DAYS(NOW())
> -
> > > TO_DAYS(date_col) > 80
> > >
> > > if you don't have a timestamp field, but
> you do
> > > have an autoincrement id field:
> > >
> > > figure out number of records on average =
; MySQL Mailing List
> Subject: RE: maintaining size of a db
>
>
> OK, I *THINK* I follow you here. Couple of
> questions. I'm reading an online tutorial trying
> to figure this out, and I am led to believe mysql
> can't do nested queries, aka sub-queries. But you
>
2M)
> again, use 10% for safety (1.8M)
>
> select (@aa:=id) as low_id from logtable order
> by id limit 1800,1
> delete from logtable where id < @aa
>
> (do subqueries work with a limit clause?)
>
>
> > -----Original Message-----
> > From: Scott
Sent: Wednesday, November 12, 2003 11:19 AM
> To: Dan Greene; MySQL Mailing List
> Subject: RE: maintaining size of a db
>
>
> Yes sir, exactly. It's just that's what I'm
> looking for, and can't figure out. I can set up
> a cron job, but what exactly w
Yes sir, exactly. It's just that's what I'm
looking for, and can't figure out. I can set up
a cron job, but what exactly would the SQL delete
statement be that would allow me to delete old
records in such a way that the db maintains an
approximately constant size on disk? (Failing
that perhaps a
cronjob a sql script that runs a delete statement for old jobs daily
> -Original Message-
> From: Scott H [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, November 12, 2003 10:40 AM
> To: MySQL Mailing List
> Subject: Re: maintaining size of a db
>
>
> --- Egor E
--- Egor Egorov wrote:
> Scott H wrote:
>> Can't seem to find this one in the manual or
>> archives - how do I control a db to maintain
>> its size to an arbitrary value, say 20 GB? I
>> want to just rotate records, deleting those
>> that are oldest.
>
> You can't restrict size of the database on
Scott H <[EMAIL PROTECTED]> wrote:
> Repost - Haven't gotten any response on this and
> can't find an answer. If no one on the mysql
> list knows, where does a fellow turn? Help!
>
>> Can't seem to find this one in the manual or
>> archives - how do I control a db to maintain
>> its size to an a
Repost - Haven't gotten any response on this and
can't find an answer. If no one on the mysql
list knows, where does a fellow turn? Help!
> Can't seem to find this one in the manual or
> archives - how do I control a db to maintain
> its size to an arbitrary value, say 20 GB? I
> want to just r
15 matches
Mail list logo