Thread
#prefect-community
    t

    Tao Bian

    10 months ago
    I was running a prefect flow but facing a run out of memory issue, how can I clear up and free the space. I saw a 17G .prefect file in the root directory, can I remove it?
    Kevin Kho

    Kevin Kho

    10 months ago
    You can delete those files if you don’t need them. They are checkpoints from the flow runs. You can also turn off checkpoints with
    @task(checkpoint=False)
    def ...
    t

    Tao Bian

    10 months ago
    Thank you for your reply!! Can I clean the checkpoints for a specific flow since we have several flows ran.
    Kevin Kho

    Kevin Kho

    10 months ago
    These checkpoints are mainly for restarting a flow run from failure. Instead of re-running the previous tasks, it will pull the checkpoint. So you can delete most of them safely
    Like just leave the most recent ones.
    t

    Tao Bian

    10 months ago
    Thanks!!! So for accessing the checkpoints - I cd into .prefect/flows/name_of_my_flow , I see multiple files in there - is this the correct place to delte the checkpoints? and how do I know which one is the latest ?
    Kevin Kho

    Kevin Kho

    10 months ago
    yes exactly. can you sort it by time?
    t

    Tao Bian

    10 months ago
    Okay, can i remove the entire folder or remove all the checkpoints inside.
    Kevin Kho

    Kevin Kho

    10 months ago
    All might be aggressive but as long as you dont have future flows that rely on these, yeah it should be fine
    t

    Tao Bian

    10 months ago
    Thank you very much! Space error fixed!