Suggestion: Command to Clear or Delete EQ Log Files

Discussion in 'The Veterans' Lounge' started by Froglok, Aug 27, 2021.

  1. Froglok Augur

    I think this was suggested years ago, and it was a good suggestion.

    Rather than having to manually Delete Log files, could we please have an in-game command to do this?

    The condition would be that Logging is currently turned off.

    Suggested Commands:

    /log clear - Clears the log of all current entries, but does not erase the file.

    - or -

    /log delete - Deletes the current log file, so that a new one can be started.

    Also...

    /merclog clear - Clears the Merc log of all current entries, but does not erase the file.

    - or -

    /merclog delete - Deletes the current Merc log file, so that a new one can be started.

    I think this could help Players by having an expedient method to delete / clear log files... that could potentially help a little with lag by reducing the size of Log Files that are being constantly written to, when logging is turned on.
    Duder likes this.
  2. MasterMagnus The Oracle of AllHigh

    use
    /system del notes.txt

    Assuming the file is notes.txt and in your EQ directory, give it a path if not.
    And edit eqclient.ini adding EnableSystemCommand=1 in the [default] section.

    here is the explanation of the /system command from alla:

    Or if you followed my advice from your other notes.txt post
    Macro on each character
    /system del charactername.txt
  3. Svann2 The Magnificent

    if you use gina triggers, you can set it up to automatically move your log file to a backup location daily.
    Metanis and Ssdar like this.
  4. Yinla Ye Ol' Dragon

    I archive mine each month to a different folder by server.
    Fenthen likes this.
  5. Bigstomp Augur

    As Svann said, gina will rotate them for you. Based on either size or time period. (I rotate daily)
    I believe gamparse will as well but I'm not positive.

    This would solve 90+ percent of the cases since unless you have something planning to read the logs, there's little reason to have /log on
  6. Sissruukk Rogue One

    As the OP said, I think it would be nice to have an in-game command to do it. I shouldn't have to rely on a third party software to do it. I hardly use GINA or Gamparse, so I go in and manually delete it out. I do keep logs running because I would forget to turn them on for those times where I need to use GINA or Gamparse. Also, there are times where I have had to go back into my log to get something for a ticket or whatnot. It would be nice to have this feature in. It would also be nice if you could filter out certain things from the even being logged, such as merc data.
    Duder likes this.
  7. Khat_Nip Meow

    Granted it's not solely in-game but you could do as MasterMagnus suggested up-thread using the /system command and a .bat (batch) file.

    For example, create a file called eq.bat (in your logs directory for the sake of ease).
    This file's contents would be similar to:
    Code:
    IF "%~1"=="clear" ren D:\EQ\Logs\eqlog_Khaat_xegony.txt eqlog_Khaat_xegony_%date:~4,2%-%date:~7,2%_%date:~10,4%_%time:~0,2%_%time:~3,2%_%time:~6,5%.txt
    IF "%~1"=="delete" del D:\EQ\Logs\eqlog_Khaat_xegony.txt
    Naturally you'd change the drive:/path/filenames to suit your situation.

    (The first IF would rename your current logfile in this example to: eqlog_Khaat_xegony_08-28_2021_16_51_59.05.txt by appending month/day/year/hour/minutes/seconds/milliseconds to the filename)).
    (The second IF would delete your current logfile altogether).

    In order to make use of the .bat file you would access it via the EQ chatbox by typing either:

    /system D:\EQ\Logs\eq.bat clear
    or
    /system D:\EQ\Logs\eq.bat delete

    (Again, using your particular drive:\path for your setup.

    *I have no idea what /merclog is but you could certainly add more IF statements to the .bat file to handle them.
    *This .bat file-/system use will work whether or not you have /log on or /log off.
    *It will tab you out to your desktop when you invoke it so you'd have to tab back to EQ. (I'm not familiar enough with EQs /system command to know if that can be avoided).
    *This works fine while EQ itself is running but other programs may lock the logfile (GINA) and throw an error stating the file is in use.
    MasterMagnus likes this.
  8. Sissruukk Rogue One

    That looks great and all, but speaking for myself, I am not so well versed in code beyond BASIC and HTML (giving away my age here), so that looks all like Greek to me. I would assume a lot of others are in the same boat as I am. So, a simple in-game command would do me just fine.
    CatsPaws likes this.
  9. Svann2 The Magnificent

    Yea batch files are all fun and games until the day your partition gets deleted!
    Metanis and cadres like this.
  10. Elyssanda Bardbrain

    Go to your log file, and simply add the date that you are ready to stop the last log.I just use month & year
    I do this every 30 days or so..
    mine now say:
    eqlog_Elyssanda_cazic.6.21
    eqlog_Elyssanda_cazic.7.21
    eqlog_Elyssanda_cazic.8.21
    Metanis likes this.
  11. MasterMagnus The Oracle of AllHigh


  12. Metanis Bad Company

    This is a great idea!

    I would suggest a minor naming convention change so that the various saved log files can be more easily sorted by date... use _yy_mm.txt instead. They'll also open in your default text editor that way.

    So eqlog_Elyssanda_cazic.8.21 would become eqlog_Elyssanda_cazic_21_08.txt
    MasterMagnus likes this.
  13. Elyssanda Bardbrain

    mine works for how my brain works. don't delve deep there, you will get lost.
    Metanis likes this.
  14. Metanis Bad Company


    Oh gosh, I think I'm getting queasy already!!!!


    <wink>
    Elyssanda likes this.
  15. MasterMagnus The Oracle of AllHigh

    /system ren notes.txt %date%-notes.txt

    /system ren ".\logs\whateveryourlognameis.txt" ".\logs\%date%-whateveryourlognameis.txt"

    Put it on a button. Always types it the same, never makes a mistake, never deletes your partition LOL.
  16. Accipiter Old Timer

    I was curious so I did a couple of tests. As I expected, the /system code calls the WinAPI function, ShellExecute(). ShellExecute uses file associations so the following are equivalent:

    /system notepad file.txt
    /system file.txt

    That assumes notepad is your default text editor. If it is not, the second command will start your default text editor and load file.txt.

    You can also do:

    /system https://everquest.allakhazam.com/db/npc.html?id=4570

    And it'll open that page on your default browser.

    For whatever it's worth...
    MasterMagnus likes this.
  17. MasterMagnus The Oracle of AllHigh

    Accipiter likes this.
  18. Sissruukk Rogue One

    My reply was to Khatnip's coding.


    Will this look in your logs folder for that file, or just the base Everquest directory? In otherwords, do I have to set the directory for the log file (C:\users\public\daybreak_game_company\installed_games\everquest\logs\)?

    But, I stand by my argument that there should be a command in game to do this, WITHOUT having to go in and edit the eqclient.ini file.
    Metanis likes this.
  19. MasterMagnus The Oracle of AllHigh


    /system will run out of your Everquest folder. If you wanted to address logs you can use ".\Logs\"

    I've done some extensive testing to come up with my own solution. My desire was to create the easiest solution possible. What I ended up at is a .bat file that runs from /system, requires a change to the .ini file (because of /system), and requires you to add a new directory.

    I tried but gave up on solutions that didn't require .ini edits, or .bat files. And while that is possible, it's a lot more complicated command line, that may actually overrun the max character length of an EQ macro.

    ***EDIT***
    Created a better solution here.

    https://forums.daybreakgames.com/eq/index.php?threads/log-management-socials-how-to.277236/
    Sissruukk likes this.