Page 1 of 1

Can Hazel clean up MySQL "binlog" files?

PostPosted: Mon Jun 21, 2021 6:36 am
by morkafur
I've noticed that over time, MySQL creates a bunch of "binlog" files that are huge and unneeded.

I would like to set up a Hazel rule to remove these files.

Removing these files at the command prompt requires a "sudo" so I don't know how to do that in Hazel.

So, can Hazel remove files that require authentication like with sudo?

Please advise how to setup a rule, if possible for Hazel to remove these files.

Thanks

Re: Can Hazel clean up MySQL "binlog" files?

PostPosted: Mon Jun 21, 2021 11:16 am
by Mr_Noodle
You'd either need a script to handle the password or use a setuid script, which can be dangerous.

Re: Can Hazel clean up MySQL "binlog" files?

PostPosted: Mon Jun 21, 2021 11:17 am
by morkafur
Thanks. Probably better in this case to do this manually on a reminded schedule.

Appreciate your suggestions and advice. :)