Re: [SQL] Auto-Vacuum?
От | Brian |
---|---|
Тема | Re: [SQL] Auto-Vacuum? |
Дата | |
Msg-id | Pine.LNX.4.02.9901281302370.338-100000@mercury.shreve.net обсуждение исходный текст |
Ответ на | Auto-Vacuum? (Tim Perdue <tim_perdue@yahoo.com>) |
Список | pgsql-sql |
On Thu, 28 Jan 1999, Tim Perdue wrote: > Just curious if anyone has written an vacuum shell script. > Just use cron: 00 01 * * * /usr/local/pgsql/bin/psql shrevenet_users -c "vacuum;" 01 01 * * * /usr/local/pgsql/bin/psql shrevenet_ftp -c "vacuum;" 02 01 * * * /usr/local/pgsql/bin/psql shrevenet_counter -c "vacuum;" etc. Also before I vacuum, I dump each night (never can be too safe :) 00 00 * * * /usr/local/pgsql/bin/pg_dump shrevenet_users > /usr/local/pgsql/backups/shrevenet_users.dump 01 00 * * * /usr/local/pgsql/bin/pg_dump shrevenet_ftp > /usr/local/pgsql/backups/shrevenet_ftp.dump 02 00 * * * /usr/local/pgsql/bin/pg_dump shrevenet_counter > /usr/local/pgsql/backups/shrevenet_counter.dump > At this point, I have been going in weekly and issuing the VACUUM; > command manually. > > Now that tons of records are being inserted hourly, I want to vacuum > 1-2 times a day. > > I could do this pretty easily with a simple Java/JDBC proram, but > would rather just have a shell script go into psql. Unfortunately, I > know nothing about shell scripting. > > Any tips or samples are appreciated. > > Tim > > > == > ______________________________________________________ > > Tim Perdue > tim@perdue.net > > > _________________________________________________________ > DO YOU YAHOO!? > Get your free @yahoo.com address at http://mail.yahoo.com > > -------------------------------------------------------------------------- Brian Feeny (BF304) | ShreveNet Inc. - Premium Internet Service Provider Network Administrator | Shreveport, Louisiana - http://www.shreve.net/ signal@shreve.net | Web Hosting, Virtual Domains, Storefronts, (318)222-2NET x 109 | Database/Web Integration, 56k, ISDN, T1
В списке pgsql-sql по дате отправления: