You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by GitBox <gi...@apache.org> on 2022/09/27 21:03:10 UTC
[GitHub] [iceberg] calvin-pietersen opened a new issue, #5871: Running out of disk space on row level deletes
calvin-pietersen opened a new issue, #5871:
URL: https://github.com/apache/iceberg/issues/5871
### Query engine
EMR 6.7.0
Spark 3.2.1
Iceberg 0.14.0
### Question
Hi,
We are performing row level deletion on an Iceberg table using Spark SQL. Rows need to be deleted across multiple partitions/files.
`delete from data as d where exists ( select id from deletes where d.id = id )`
When deletion runs, our EMR cluster is running out of disk space if a high number of partitions/files are hit. On further inspection, Iceberg is performing a final repartition and sort just before replacing the data. My question is, why does Iceberg need to repartition and sort the files? Should the files not already be partitioned/sorted?
<img width="450" alt="image" src="https://user-images.githubusercontent.com/16835507/192633685-f15fcc5b-b38c-4735-8257-91c9af3b7419.png">
The deletes table seems to be joined onto the data table via broadcast join.
<img width="941" alt="image" src="https://user-images.githubusercontent.com/16835507/192634589-4c193747-1e63-4867-911d-e422ab0c2b72.png">
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
[GitHub] [iceberg] github-actions[bot] commented on issue #5871: Running out of disk space on row level deletes
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #5871:
URL: https://github.com/apache/iceberg/issues/5871#issuecomment-1487767880
This issue has been automatically marked as stale because it has been open for 180 days with no activity. It will be closed in next 14 days if no further activity occurs. To permanently prevent this issue from being considered stale, add the label 'not-stale', but commenting on the issue is preferred when possible.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
[GitHub] [iceberg] github-actions[bot] closed issue #5871: Running out of disk space on row level deletes
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #5871: Running out of disk space on row level deletes
URL: https://github.com/apache/iceberg/issues/5871
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
[GitHub] [iceberg] github-actions[bot] commented on issue #5871: Running out of disk space on row level deletes
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #5871:
URL: https://github.com/apache/iceberg/issues/5871#issuecomment-1506125712
This issue has been closed because it has not received any activity in the last 14 days since being marked as 'stale'
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
[GitHub] [iceberg] singhpk234 commented on issue #5871: Running out of disk space on row level deletes
Posted by GitBox <gi...@apache.org>.
singhpk234 commented on issue #5871:
URL: https://github.com/apache/iceberg/issues/5871#issuecomment-1262429384
I think this would be happening becuase `write.delete.distribution-mode` default is set to `hash` can try setting to `none`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
[GitHub] [iceberg] calvin-pietersen commented on issue #5871: Running out of disk space on row level deletes
Posted by GitBox <gi...@apache.org>.
calvin-pietersen commented on issue #5871:
URL: https://github.com/apache/iceberg/issues/5871#issuecomment-1262718690
Can confirm this has resolved the issue. Thank you @singhpk234! - sorry will share plans next time.

Two more questions
- Why is `write.delete.distribution-mode=hash` by default? Seems like `write.delete.distribution-mode=none` is safer?
- Is the sort unnecessary considering the files should already be sorted?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org