Re: Help automate pg_dump

Поиск
Список
Период
Сортировка
От Bjoern Metzdorf
Тема Re: Help automate pg_dump
Дата
Msg-id 034d01c216d3$62eb6620$81c206d4@office.turtleentertainment.de
обсуждение исходный текст
Ответ на Re: Help automate pg_dump  (terry@greatgulfhomes.com)
Список pgsql-general
> Please let the list know if you get a solution, I am about to go to 7.2 on
> my production machines but that could be a show stopper if the cron job
> cannot automatically back it up anymore.

You might try this with expect (customizing necessary):

#!/usr/bin/expect -f
# wrapper to make passwd(1) be non-interactive
# username is passed as 1st arg, passwd as 2nd

set password xxx
spawn /usr/bin/psql -d db
expect "password:"
sleep 1
send "$password\r"
expect "password:"
sleep 1
send "$password\r"
expect eof



Greetings,
Bjoern



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

Предыдущее
От: Andrew Sullivan
Дата:
Сообщение: Re: Are there any "official" PostgreSQL banners available.
Следующее
От: "Bjoern Metzdorf"
Дата:
Сообщение: db grows and grows