|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
Добрый вечер. В логе несколько сообщений: using stale statistics instead of current ones because stats collector is not responding + pg_stat_user_tables в n_live_tup показывает на 5 порядков значение меньше чем в реальности. Подозреваю из-за этого "едут" планы запросов. Подскажите пожалуйста, как можно исправить эту проблему? ... |
|||
:
Нравится:
Не нравится:
|
|||
15.06.2018, 19:11 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
аналайз таблицы в ручную не обновляет статистику в pg_stat_user_tables ... |
|||
:
Нравится:
Не нравится:
|
|||
15.06.2018, 19:13 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
В какую сторону копать? ... |
|||
:
Нравится:
Не нравится:
|
|||
15.06.2018, 19:15 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
Версия 9.4 ... |
|||
:
Нравится:
Не нравится:
|
|||
15.06.2018, 19:24 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
Сделал ANALYZE всей БД в ручную. Проверил, данные в pg_stat_user_tables соответствуют действительности. Затем рестартанул postgres и данные pg_stat_user_tables обнулилась: Как так может быть? ... |
|||
:
Нравится:
Не нравится:
|
|||
15.06.2018, 20:22 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
sstatisticЗатем рестартанул postgres и данные pg_stat_user_tables обнулилась: Как так может быть? Логи смотрите. У вас случайно нештатных выключений (с последующим восстановлением) не было?? После рекавери сбрасывает статистику. ... |
|||
:
Нравится:
Не нравится:
|
|||
16.06.2018, 05:16 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
sstatistic, может проблема с каталогом pg_stat ? там сохраняется статистика из оперативной памяти ... |
|||
:
Нравится:
Не нравится:
|
|||
16.06.2018, 08:05 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
grgdvosstatisticЗатем рестартанул postgres и данные pg_stat_user_tables обнулилась: Как так может быть? Логи смотрите. У вас случайно нештатных выключений (с последующим восстановлением) не было?? После рекавери сбрасывает статистику. Спасибо, не знал про это. Было выключение через -m immediate. В логе вот такое сообщение потом проскользнуло: FATAL: the database system is starting up FATAL: the database system is starting up LOG: database system was not properly shut down; automatic recovery in progress LOG: redo starts at 671/BB7F7F70 FATAL: the database system is starting up FATAL: the database system is starting up Получается каждый раз при этом статистика полностью сбрасывается? ... |
|||
:
Нравится:
Не нравится:
|
|||
18.06.2018, 10:59 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
gav21sstatistic, может проблема с каталогом pg_stat ? там сохраняется статистика из оперативной памяти Возможно из-за огромной загрузки диска туда ничего не записалось. ... |
|||
:
Нравится:
Не нравится:
|
|||
18.06.2018, 11:01 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
sstatistic, а зачем вам immediate выключение? Это проходит по типу нештатный сбой (вроде сбоя по питанию), там много чего может происходить с ненужными данными вроде всякой статистики и прочих unlogged таблиц. На выключенном синхронном коммите, емнип, и последние транзакции потерять можно. ... |
|||
:
Нравится:
Не нравится:
|
|||
18.06.2018, 11:06 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
Melkijsstatistic, а зачем вам immediate выключение? Это проходит по типу нештатный сбой (вроде сбоя по питанию), там много чего может происходить с ненужными данными вроде всякой статистики и прочих unlogged таблиц. На выключенном синхронном коммите, емнип, и последние транзакции потерять можно. fast висело минут 20. ... |
|||
:
Нравится:
Не нравится:
|
|||
18.06.2018, 11:08 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
grgdvo После рекавери сбрасывает статистику. Подскажите пожалуйста где это написано? ... |
|||
:
Нравится:
Не нравится:
|
|||
18.06.2018, 12:43 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
sstatistic, https://www.postgresql.org/docs/current/static/monitoring-stats.html Последний абзац пункта 28.2.1 авторWhen recovery is performed at server start (e.g. after immediate shutdown, server crash, and point-in-time recovery), all statistics counters are reset. ... |
|||
:
Нравится:
Не нравится:
|
|||
18.06.2018, 15:28 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
sstatisticfast висело минут 20. Какие-то у вас незакрытые коннекты остаются, не дают базе нормально завершиться. Ищите, что у вас там настроено?? Злобные клиенты, репликация......... Мой init-скрипт завершения через определенные таймауты идет по цепочке smart -> fast -> immediate. Вот описание stop mode shuts down the server that is running in the specified data directory. Three different shutdown methods can be selected with the -m option. “Smart” mode waits for all active clients to disconnect and any online backup to finish. If the server is in hot standby, recovery and streaming replication will be terminated once all clients have disconnected. “Fast” mode (the default) does not wait for clients to disconnect and will terminate an online backup in progress. All active transactions are rolled back and clients are forcibly disconnected, then the server is shut down. “Immediate” mode will abort all server processes immediately, without a clean shutdown. This choice will lead to a crash-recovery cycle during the next server start. ... |
|||
:
Нравится:
Не нравится:
|
|||
18.06.2018, 15:35 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
Забыл приписать. Верхнее - это выдержка из man pg_ctl, который собственно и должен запускать и останавливать сервер PG. ... |
|||
:
Нравится:
Не нравится:
|
|||
18.06.2018, 15:46 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
grgdvo, Я искал не там, хорошо что вы сказали в разделе The Statistics Collector искать! Большое спасибо! ... |
|||
:
Нравится:
Не нравится:
|
|||
18.06.2018, 17:11 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
Здравствуйте. Подскажите, пожалуйста, по этой ошибке "LOG: using stale statistics instead of current ones because stats collector is not responding" У меня на разных серверах в кластере и одиночные ноды имеют такие логи. Причем разные версии PostgeSQL Делал Код: sql 1.
не помогает ... |
|||
:
Нравится:
Не нравится:
|
|||
26.03.2020, 11:29 |
|
using stale statistics instead of current ones because stats collector is not responding
|
|||
---|---|---|---|
#18+
Наверное были какие-то проблемы с виртуализацией. Возможно виртуалки с PostgreSQL выключались и снова запустились. Если виртуалка внезапно выключалась, то нужно просто перезагрузить PostgreSQL? ... |
|||
:
Нравится:
Не нравится:
|
|||
26.03.2020, 11:33 |
|
|
start [/forum/topic.php?fid=53&msg=39941259&tid=1994756]: |
0ms |
get settings: |
11ms |
get forum list: |
13ms |
check forum access: |
3ms |
check topic access: |
3ms |
track hit: |
38ms |
get topic data: |
12ms |
get forum data: |
3ms |
get page messages: |
52ms |
get tp. blocked users: |
1ms |
others: | 280ms |
total: | 416ms |
0 / 0 |