Re: Vaccum

Поиск
Список
Период
Сортировка
От bangh
Тема Re: Vaccum
Дата
Msg-id 3C0677C3.6D244165@baileylink.net
обсуждение исходный текст
Ответ на Vaccum  ("Leong, Fushan" <fushan.leong@SonoSite.com>)
Список pgsql-admin
Hello,

You can use vacuum at different levels.

As a command you can use vacuumdb database_name.

In psql, you can use
psql> vacuum table_name;

I don't think it is going to delete records. To delete records you need to
issue SQL command:
like: delete from table_name where condi.

It must delete the cells. when you delete the reocrds, the space does not
get compressed.

You can check the size changes of a table or database before and after you
issue "vacuum" command.

You don't need to shut down postmoaster.

It would be nice if you do such jobs at midnight, because such a job does
keep your CPU busy.

Bangh

"Leong, Fushan" wrote:

> Hi :
>
> Want to get your opinion.
>
> I am thinking to schedule to run Vaccum everynight.
>
> 1) As I understand, Vaccum is the command to delete old data, right?
> 1) Do I have to stop the postmaster before run the Vaccum command?
> 2) Should I run it everynight?  How often should I run it?
>
> thanks
> Fushan
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: Have you searched our list archives?
>
> http://archives.postgresql.org


В списке pgsql-admin по дате отправления:

Предыдущее
От: "Leong, Fushan"
Дата:
Сообщение: Vaccum
Следующее
От: "Nick Fankhauser"
Дата:
Сообщение: Re: table test