1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.5 Prune Admin Log, Moderator Log

Discussion in 'XenForo Questions and Support' started by Bob_R, Sep 3, 2015.

  1. Bob_R

    Bob_R Active Member

    How does one prune the Admin log and Moderator logs?
     
  2. Chris D

    Chris D XenForo Developer Staff Member

    They aren't really supposed to be cleared (in that way), nor is there much benefit in doing so. They are pruned automatically.

    If you absolutely have to prune them now, you could truncate/empty the xf_admin_log and xf_moderator_log table. (Take back ups first).
     
    borbole likes this.
  3. borbole

    borbole Well-Known Member

    Have a look here about it:

    XF 1.2 - Deleting or pruning Admin and Moderator logs

    If you want to prune them now, you can truncate the following tables: xf_admin_log and xf_moderator_log.

    P.s. If you still want to prune them, make a backup first in case you would need them later on.
     
    Chris D likes this.
  4. Brogan

    Brogan XenForo Moderator Staff Member

    You can set the moderator log length to 1 in the options which will prune it to 1 day (after running the daily clean up cron), then set it back to the previous value.
     
    maszd and Chris D like this.
  5. Bob_R

    Bob_R Active Member

    Thanks to all.
     
  6. melbo

    melbo Well-Known Member

    Where does one set the length of time for automatic pruning of the admin log?
    I see options for moderator log and user change log (both set to 30 days) but my admin log goes back to 12/2015 so it's at >60 days right now

    -edit: found it as a config.php option

    Code:
    $config['adminLogLength'] = 30;
    The number of days to keep the log of all administrator activities in the admin control panel.
     
    Last edited: Feb 26, 2016

Share This Page