logo logo

 Back to main page

The NWNX Community Forum

 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Delete Logfile on Restart

 
Post new topic   Reply to topic    nwnx.org Forum Index -> Technical support
View previous topic :: View next topic  
Author Message
Morrandir



Joined: 13 Jan 2006
Posts: 27

PostPosted: Sun Nov 25, 2007 19:16    Post subject: Delete Logfile on Restart Reply with quote

For Debugging purpose I'd like the NWN² logfile nwserverLog1.txt to be deleted each time I restart NWServer with NWNX4 GUI.
Yes, I'v tried with a batch file specified in nwnx.ini, but the file can't be deleted as NWNServer seems to access it at the moment the batch file is executed.

So is there any way I can do this, without manually having to Stop NWServer , delete nwserverLog1.txt and Start NWServer?
_________________
German NWN1/2 Persistent World Hochwaldallianz
Back to top
View user's profile Send private message
Papillon
x-man


Joined: 28 Dec 2004
Posts: 1060
Location: Germany

PostPosted: Thu Jan 10, 2008 23:56    Post subject: Reply with quote

I guess the best thing would to modify the NWNX4 source directly. Maybe I could close the logfile while restarting the server, but that would have to wait until the next version.
_________________
Papillon
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Morrandir



Joined: 13 Jan 2006
Posts: 27

PostPosted: Fri Jan 11, 2008 0:31    Post subject: Reply with quote

I could live with that very well. Smile
_________________
German NWN1/2 Persistent World Hochwaldallianz
Back to top
View user's profile Send private message
xaltos



Joined: 03 Jun 2006
Posts: 31
Location: Germany

PostPosted: Sat Jan 12, 2008 13:06    Post subject: Reply with quote

There is a easier way as well.

NWNx4 can start a batch befor a restart.
So you can delete your Log files with it.


Take a look into the nwnx.ini
Code:

# If you want NWNX to execute a CMD or BAT file before restarting the server after
# a crash, specify it's name here. If you leave this setting empty, no program
# will be run. NWNX will wait for the program to finish before it continues.
# no default
restartCmd = nwnx_restart.cmd

_________________
xaltos

NWN2_Audolo
Back to top
View user's profile Send private message
Morrandir



Joined: 13 Jan 2006
Posts: 27

PostPosted: Sat Jan 12, 2008 19:28    Post subject: Re: Delete Logfile on Restart Reply with quote

Morrandir wrote:

Yes, I'v tried with a batch file specified in nwnx.ini, but the file can't be deleted as NWNServer seems to access it at the moment the batch file is executed.
Wink
_________________
German NWN1/2 Persistent World Hochwaldallianz
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    nwnx.org Forum Index -> Technical support All times are GMT + 2 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group