-
Notifications
You must be signed in to change notification settings - Fork 882
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: pg_restore cannot restore data correctly after running timescaledb_post_restore, but the right data when running timescaledb_pre_restore #7383
Comments
Anyone could help ? |
I just drop database and do it again, but it still dost not work. |
Can you look at and post explain plans before and after post restore?
|
There is something we are missing here, I have tried doing what you are doing and for me the behavior is opposite. I don't see any rows before post restore and see them after post restore. Is there anything else you did? Could you do an explain with analyze? Maybe that can give us some hints whats going on here. |
I don't think you need create tables and run Can you just try without that? Just run on server B:
|
It works, but there is another message. |
This seems like bar_data_1m is still created before you run pg_restore. Make sure you don't create it manually or drop it if already exists. |
I have restored data into database but table will be created again in our python script (we created table through python script when running) and it throw an exception as above. |
This is what I'm suggesting, don't create the table or hypertable, the restore step will do that for you. |
ok.thank you for your support... |
Sorry to open this issue and please help.There are some extract incremental datas from Server A that I need to sync it to Server B.
But I can find these data in csv so there are some incremental datas actually. |
I don't think your dump is OK then. There should be hypertables when you restore. Please take a look at our documentation on how to do dump/restore properly and follow the exact steps: |
I know the reason. The timescaledb version in Server A is 2.8.1 but version in Server B is 2.17.1. Thank you so much. |
What type of bug is this?
Incorrect result
What subsystems and features are affected?
Backup, Restore
What happened?
pg_dump -h localhost -U username -p 5434 -Fc -f vnpy.back vnpy
There is no any data after running 'SELECT timescaledb_post_restore()', but I can get the data when running 'SELECT timescaledb_pre_restore();'
details:
TimescaleDB version affected
2.17.0
PostgreSQL version used
14.13
What operating system did you use?
ubuntu 20.04
What installation method did you use?
Deb/Apt
What platform did you run on?
On prem/Self-hosted
Relevant log output and stack trace
No response
How can we reproduce the bug?
In my environment, the issue is inevitable following steps as above. How to restore database correctly, please give me advices?
The text was updated successfully, but these errors were encountered: