partition_data_proc taking too long to transfer the data
I have a table with >500 million rows that I want to partition. So I followed the offline partitioning steps given here, but the partition_data_proc procedure is taking too long to complete even with larger batch size.
I setup the monthly partitions on timestamp field using SELECT partman.create_parent('public.new_table', 'timestamp', 'native', 'monthly');
I ran the proc CALL partman.partition_data_proc('public.new_table', p_interval := '50000', p_source_table := 'public.old_table'); and it ran for ~15 hours and after that it was killed by postgres. Even after that, all of the data was not transferred from the source table.

Just for comparison, I also setup partitions manually for the same table and copied the data from the old table to the new in batches of 50000 rows and it took only around ~3 hours to copy everything.
I'm not sure if I'm doing something wrong or if there is some issue with the proc. Let me know if more information is needed
Apologies I did not see your initial question over in the Discussion section. I answered there first before I saw the question here again. Please continue the discussion there for now.
https://github.com/pgpartman/pg_partman/discussions/436