avril_cleaning
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| avril_cleaning [2018/04/23 15:57] – external edit 127.0.0.1 | avril_cleaning [2021/01/08 10:56] (current) – [Check how much place is occupied by job attachments] kalaschnikow | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ====== Avril Cleaning ====== | ||
| + | ===== Gelöschte Jobs endgültig löschen ===== | ||
| + | Da Avril die Jobs in der DB nur als gelöscht markiert, muss man die Jobs auch irgendwann mal aus der DB löschen. Am besten ein Mal im Monat -> am besten wäre es wenn man einen Job dafür anlegt. Momentan machen wir es aber händisch. | ||
| + | |||
| + | Zuerst gucken wie viele Sätze zu löschen sind. Am besten das Datum "Heute minus ein Monat" nehmen ([[http:// | ||
| + | |||
| + | <code sql> | ||
| + | -- org_id = 35 = Articard | ||
| + | -- delMS = 1510582919000 = Mon Nov 13 2017 15:21:59 GMT+0100 | ||
| + | |||
| + | SELECT count(*) FROM job where delMS < 1510582919000 and delMS > 0 and org_id=35 | ||
| + | </ | ||
| + | |||
| + | Dann löschen: | ||
| + | |||
| + | <code sql> | ||
| + | |||
| + | DELETE FROM job where delMS < 1510582919000 and delMS > 0 and org_id=35 | ||
| + | </ | ||
| + | |||
| + | ===== Check jobdeleteutil log ===== | ||
| + | |||
| + | <code bash> | ||
| + | cd ~/ | ||
| + | |||
| + | nano jobdeleteutil.log | ||
| + | </ | ||
| + | |||
| + | Use //Ctrl+W// and //Ctrl+V// to jump to the end of file. | ||
| + | |||
| + | ===== Check how much place is occupied by job attachments ===== | ||
| + | |||
| + | <code bash> | ||
| + | du -sh / | ||
| + | |||
| + | # or if you want to see every directory under upload | ||
| + | du -h / | ||
| + | </ | ||
