Clarification Needed: When does autovacuum daemon run?
Clarification Needed: When does autovacuum daemon run?
am 18.05.2010 11:56:26 von Narasimha Murthy-VRFX87
This is a multi-part message in MIME format.
------_=_NextPart_001_01CAF670.61411719
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
Hello,
=20
Postgresql-8.2 manual has mentioned following points.
* The autovacuum daemon, when enabled, runs every autovacuum_naptime
seconds.
* autovacuum_naptime (integer): Specifies the delay between "activity
rounds" for the autovacuum daemon....The delay is measured in seconds,
and the default is one minute (1m)....
=20
My Query: I want to run autovacuum daemon everyday at 5 am. By setting
autovacuum_naptime to 24*60*60 (# of seconds in a day), I can run the
daemon everyday. But, how do I ensure the daemon runs at 5am? What is
the "activity rounds" mentioned in the manual? Pl clarify. Appreciate an
early reply.
=20
[postgresql-8.2-US.pdf]
http://www.postgresql.org/files/documentation/pdf/8.2/postgr esql-8.2-US.
pdf
..pdf>=20
=20
Regards, Narasimha Murthy
Cell +91 95814 98895, +91-94940 62794 | 040-2347 2025 (O) | x2025 (O)
=20
------_=_NextPart_001_01CAF670.61411719
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
charset=3Dus-ascii">
class=3D714114609-18052010>Hello,
class=3D714114609-18052010>
class=3D714114609-18052010>Postgresql-8.2
class=3D714114609-18052010>=20
manual has mentioned =
following=20
points.
class=3D714114609-18052010>* The autovacuum daemon, when enabled, =
runs=20
every autovacuum_naptime seconds
class=3D714114609-18052010>.
Sans MS">
size=3D2>* autovacuum_naptime (integer)
class=3D714114609-18052010>:=20
Specifies the delay between "activity rounds" for the autovacuum=20
daemon....The delay is measured =
in=20
seconds, and the default is one minute (1m).
class=3D714114609-18052010>...
size=3D2>
face=3D"Comic Sans MS"=20
size=3D2>My Query: I want to run autovacuum daemon everyday at 5 am.=20
By setting autovacuum_naptime to 24*60*60 (# of seconds in a day), =
I can=20
run the daemon everyday. But, how do I ensure the daemon runs at 5am? =
What is=20
the "activity rounds" mentioned in the manual?
class=3D714114609-18052010> Pl =
clarify.=20
Appreciate an early reply.
Sans MS"=20
size=3D2>
class=3D714114609-18052010>[postgresql-8.2-US.pdf
class=3D714114609-18052010>]=20
title=3Dhttp://www.postgresql.org/files/documentation/pdf/8. 2/postgresql-=
8.2-US.pdf=20
href=3D"http://www.postgresql.org/files/documentation/pdf/8. 2/postgresql-=
8.2-US.pdf">
title=3Dhttp://www.postgresql.org/files/documentation/pdf/8. 2/postgresql-=
8.2-US.pdf=20
face=3D"Comic Sans MS"=20
size=3D2>http://www.postgresql.org/files/documentation/pdf/8 .2/postgresql=
-8.2-US.pdf
Sans MS">
size=3D2>
size=3D2>
size=3D2>Regards,=20
Narasimha Murthy
size=3D2>Cell +91 95814=20
98895, +91-94940 62794 | 040-2347 2025 (O) | x2025 =
(O)
------_=_NextPart_001_01CAF670.61411719--
Re: Clarification Needed: When does autovacuum daemon run?
am 18.05.2010 12:10:23 von devrim
--=-8h4AAPR6SJ5HIZMb6c3U
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
On Tue, 2010-05-18 at 17:56 +0800, Narasimha Murthy-VRFX87 wrote:
> My Query: I want to run autovacuum daemon everyday at 5 am.=20
That is not "auto"vacuum. What you want is manual vacuum.
--=20
Devrim GÃNDÃZ
PostgreSQL DanıÅmanı/Consultant, Red Hat Certified Engineer
PostgreSQL RPM Repository: http://yum.pgrpms.org
Community: devrim~PostgreSQL.org, devrim.gunduz~linux.org.tr
http://www.gunduz.org Twitter: http://twitter.com/devrimgunduz
--=-8h4AAPR6SJ5HIZMb6c3U
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: This is a digitally signed message part
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
iEYEABECAAYFAkvyZ44ACgkQtl86P3SPfQ4ougCgyC9+atM/V84YU3ieDimc q3ua
4fcAni21c/EiixXQEs/YXZfrfzncKwsL
=Pncn
-----END PGP SIGNATURE-----
--=-8h4AAPR6SJ5HIZMb6c3U--
Re: Clarification Needed: When does autovacuum daemon run?
am 18.05.2010 13:04:34 von Narasimha Murthy-VRFX87
=20
Thanks Devrim and Ian, for a quick response.
I need some more clarification. autovacuum_naptime takes one minute by defa=
ult. In this case, which second of each minute the autovacuum daemon runs (=
provided it is enabled)? What is the "activity rounds" mentioned in the man=
ual?
Regards, Narasimha Murthy
Cell +91 95814 98895, +91-94940 62794 | 040-2347 2025 (O) | x2025 (O)
-----Original Message-----
From: Ian Lea [mailto:ian.lea@gmail.com]=20
Sent: Tuesday, May 18, 2010 3:43 PM
To: Narasimha Murthy-VRFX87
Subject: Re: [ADMIN] Clarification Needed: When does autovacuum daemon run?
As far as I understand it, the idea of autovacuum is that it chugs away tra=
nsparently in the background, keeping things healthy on a little but often =
basis. It is not designed to run once a day at a specific time. If that i=
s really what you want, I suggest you disable autovacuum and run vacuum man=
ually at 05:00.
--
Ian.
On Tue, May 18, 2010 at 10:56 AM, Narasimha Murthy-VRFX87
com> wrote:
> Hello,
>
> Postgresql-8.2 manual=A0has mentioned following points.
> * The autovacuum daemon, when enabled, runs every autovacuum_naptime=20
> seconds.
> * autovacuum_naptime (integer): Specifies the delay between "activity=20
> rounds" for the autovacuum daemon....The delay is measured in seconds,=20
> and the default is one minute (1m)....
>
> My Query: I want to run autovacuum daemon everyday at 5 am. By=A0setting=
=20
> autovacuum_naptime to 24*60*60 (# of seconds in a day), I can run the=20
> daemon everyday. But, how do I ensure the daemon runs at 5am? What is=20
> the "activity rounds" mentioned in the manual? Pl clarify. Appreciate an =
early reply.
>
> [postgresql-8.2-US.pdf]
> http://www.postgresql.org/files/documentation/pdf/8.2/postgr esql-8.2-U
> S.pdf
>
> Regards, Narasimha Murthy
> Cell +91 95814 98895, +91-94940 62794=A0| 040-2347=A02025 (O) | x2025 (O)
>
--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin
Re: Clarification Needed: When does autovacuum daemon run?
am 18.05.2010 16:51:10 von Alvaro Herrera
Excerpts from Narasimha Murthy-VRFX87's message of mar may 18 05:56:26 -0=
400 2010:
> Hello,
> =20
> Postgresql-8.2 manual has mentioned following points.
> * The autovacuum daemon, when enabled, runs every autovacuum_naptime
> seconds.
> * autovacuum_naptime (integer): Specifies the delay between "activity
> rounds" for the autovacuum daemon....The delay is measured in seconds,
> and the default is one minute (1m)....
> =20
> My Query: I want to run autovacuum daemon everyday at 5 am.
You cannot do that with autovacuum currently. Use cron.
--=20
--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin
Re: Clarification Needed: When does autovacuum daemon run?
am 19.05.2010 22:51:17 von Alvaro Herrera
Excerpts from Narasimha Murthy-VRFX87's message of mar may 18 07:04:34 -0=
400 2010:
> I need some more clarification. autovacuum_naptime takes one minute by
> default. In this case, which second of each minute the autovacuum
> daemon runs (provided it is enabled)?
Why does it matter which second it runs?
> What is the "activity rounds" mentioned in the manual??
Each worker start is a new round.
--=20
--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin
Re: Clarification Needed: When does autovacuum daemon run?
am 20.05.2010 08:47:21 von Narasimha Murthy-VRFX87
Hi Alvaro Herrera,
Since, my original plan was to run the auto-vacuum daily EXACTLY at 5 am, I=
wanted to know which seconds of a minute. My query in other word was, if I=
set autovacuum_naptime to 1 hr, which minute of an hour the auto-vacuum ru=
ns (oth min, 15th min or something else).
From the clarification given by the you and other community members, I now =
understood that autovacuum is designed to run frequently in the background,=
not designed to run once a day at a specific time. Due to this design inte=
nt, autovacuum_naptime is set to 1 min by default and autovacuum runs lazy/=
plain/standard vacuum commands (so that Vacuum can run concurrently with ot=
her normal DB operations).
Regards, Narasimha Murthy
Cell +91 95814 98895, +91-94940 62794 | 040-2347 2025 (O) | x2025 (O)
-----Original Message-----
From: pgsql-admin-owner@postgresql.org [mailto:pgsql-admin-owner@postgresql=
..org] On Behalf Of Alvaro Herrera
Sent: Thursday, May 20, 2010 2:21 AM
To: Narasimha Murthy-VRFX87
Cc: Ian Lea; Devrim GÜNDÜZ; pgsql-admin
Subject: Re: [ADMIN] Clarification Needed: When does autovacuum daemon run?
Excerpts from Narasimha Murthy-VRFX87's message of mar may 18 07:04:34 -040=
0 2010:
> I need some more clarification. autovacuum_naptime takes one minute by=20
> default. In this case, which second of each minute the autovacuum=20
> daemon runs (provided it is enabled)?
Why does it matter which second it runs?
> What is the "activity rounds" mentioned in the manual??
Each worker start is a new round.
--=20
--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make chan=
ges to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin
--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin
Re: Clarification Needed: When does autovacuum daemon run?
am 20.05.2010 19:20:04 von Alvaro Herrera
Excerpts from Narasimha Murthy-VRFX87's message of jue may 20 02:47:21 -0=
400 2010:
> Hi Alvaro Herrera,
>=20
> Since, my original plan was to run the auto-vacuum daily EXACTLY at 5 a=
m, I wanted to know which seconds of a minute. My query in other word was=
, if I set autovacuum_naptime to 1 hr, which minute of an hour the auto-v=
acuum runs (oth min, 15th min or something else).
Yeah, you have no way to be know. I guess you could turn autovacuum off
in postgresql.conf all day, and exactly at 5am you have a cron job that
edits postgresql.conf and reloads Postgres. This would start up
autovacuum, which would then continue with the regular schedule.
This is hardly ideal; there were plans to improve on this by having an
autovacuum schedule, but I think the demand for this feature has
decreased considerable, so I haven't given it any minute's thought.
> From the clarification given by the you and other community members, I =
now understood that autovacuum is designed to run frequently in the backg=
round, not designed to run once a day at a specific time. Due to this des=
ign intent, autovacuum_naptime is set to 1 min by default and autovacuum =
runs lazy/plain/standard vacuum commands (so that Vacuum can run concurre=
ntly with other normal DB operations).
Correct.
--=20
--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin