• You've discovered RedGuides 📕 an EverQuest multi-boxing community 🛡️🧙🗡️. We want you to play several EQ characters at once, come join us and say hello! 👋
  • IS THIS SITE UGLY? Change the look. To dismiss this notice, click the X --->
Logrotate for EverQuest, Very Vanilla and everything else on Windows 10

Guide Logrotate for EverQuest, Very Vanilla and everything else on Windows 10

Software Requirements
Windows
Server Type
🏢 Live 🏘️ Emu TLP Test
Description
This guide will show you how to compress and rename any log file that's over 50MB, delete old archives, and then repeat this process automatically each week. Up to 30 of these compressed files will be kept for each log, which gives you over 6 months of archives. You can easily change these settings.

The Problem
If you have log files turned on in EverQuest (/log on) and Very Vanilla (/mlog on) you may have noticed they grow very quickly and become a pain to open and parse. One user didn't know they had logs turned on, until they ran out of HDD space due to a several hundred GB log file.

Some EverQuest software such as Gamparse has log rotate built in, but if you prefer a more generic solution here's what I use:

The Solution

LogRotateWin (download)

Install LogRotateWin and then go to the install folder, by default: C:\Program Files (x86)\Ken Salter\LogRotate
Create a file called eqrotate.conf (There will be permission issues, you'll need to create it elsewhere and copy it into this folder. You could also put it in a folder that doesn't need permissions, but this is pointless for EQ as you'll need admin privileges to rotate active logs anyway)

in your new eqrotate.conf file, add the following:

INI:
# sample logrotate configuration file

# uncomment to enable compression of rotated log files
compress

C:\Users\Redbot\Games\Everquest\Logs\eqlog*.txt {
    rotate 30
    size 50M
    prerotate
        @echo off
        echo Let's keep our EQ folder tidy
        echo parameter pass %1
        VER | TIME > TEMP.BAT
        ECHO SET TIME=%%3>CURRENT.BAT
        DEL TEMP.BAT
        DEL CURRENT.BAT
        ECHO It's %TIME% now
    endscript
}
C:\Users\Redbot\Games\macroquest\Release\logs\*.log {
    rotate 30
    size 50M
    prerotate
        @echo off
        echo Let's keep our VV folder tidy
        echo parameter pass %1
        VER | TIME > TEMP.BAT
        ECHO SET TIME=%%3>CURRENT.BAT
        DEL TEMP.BAT
        DEL CURRENT.BAT
        ECHO It's %TIME% now
    endscript
}

Unless you're named Redbot, be sure to change folder locations to suit your setup.

Now you can run the script manually from the command prompt, powershell, or any CLI provided you run them as administrator.

Now Let's Automate!

But it's even easier to run from task scheduler, where you can also schedule it to run each week.

Open the task scheduler by searching Windows for "task scheduler"
click "create basic task"
1614848983169.png


Give it a name,
1614884849629.png


Choose how often to run,
1614849061938.png


For action, choose start a program
1614849088526.png


Program: powershell
Add arguments: ./logrotate eqrotate.conf
Start in: C:\Program Files (x86)\Ken Salter\LogRotate
1614884953483.png


There's a screen to review your settings, click finish.

Now go to your Task Scheduler Library and right-click your newly made task and select "properties"
1614887632247.png


At the bottom of the General tab, make sure "Run with highest privileges" is set,
1614887675267.png


Now right-click the task and select "Run" to make sure it works, and enjoy your tidy hard drive!
Minimum Required Level
1
Author
Redbot
First release
Last update
Rating
0.00 star(s) 0 ratings

More resources from Redbot

Share this resource

Back
Top