View Full Version : LOG FILE IS NOT RECORDING KILLS PLEASE HELP!!!!!
Green_Falcon
12-05-2002, 06:11 PM
Hey all, I just have one problem with my server. I have MOHSTATS working. All that is left to do is get my log file to output the correct information. What settings do i have to have to make my log files work? right now i have this setting
seta logfile "1"
But this does not output the kills or suicides. all it does is outputs the precash and other info that i do not need. ALL I NEED IT TO DO IS OUTPUT KILLS in the log
Thanks (Any help) will be appriciated
Green Falcon
Check out my server at 64.62.158.35:12206
DCFA-Anex
12-06-2002, 02:41 AM
I have a similar problem/question...was going to create a post when I saw this...thought I'd just add it in here.
First, for you stats/kills question, I use seta logfile "3" (I read it from somewhere) and all the kills/deaths are being recorded. Hope that does it for you.
Now, on to my problem, I can't seem to get the server to record global and team chatting in the logfile. I have sv_chatter set to 1, which works in the logfile created on my own system, so why doesn't it work for the server logfile? I would greatly appreciate any and all help with that one.
Thanks in advance!
Shockwave
12-06-2002, 08:29 AM
In order to get kill/death information in your log file, the key is to have this cvar set:
developer 2
The settings for the logfile cvar mean the following from what I have been able to gather:
0 = none
1 = buffered
2 = continuous
3 = append
I've always used logfile 2 personally and it has worked well for me.
Regarding the logging of chat information, the following line needs to be in your server configuration file:
sv_chatter 1
It shouldn't require any other cvars to be set as long as the game server is successfully creating a log file already. If it isn't working for you, check your configuration file and be sure you have it entered there exactly like I have shown above and try it again. If it works on one system but not another, it's usually because there is some difference in the configurations. You might also want to try using the exact configuration file from the server that works with the server that doesn't just as a test as well.
Green_Falcon
12-06-2002, 10:24 PM
Hey I am still having problems, i have set the following settings
set logfile 2
set developer 2
yet it seems to do everything exept log frags. the closest it gets is "localization error "you killed" does not have an entry"
What am i doing wrong, could anyone who knows how to do this or has a configuration that i could test send it to me
Here is my email tr_tombraiders@yahoo.com
Shockwave you said you got yours to work, mabye you could send me one of your config files and log files to see what i am looking for, i would me MOST appriciative.
Green Falcon
DCFA-Anex
12-07-2002, 03:25 AM
Well, my server provider added developer 1 to the server exec but that still didn't add the chatting to the log file. Well, that's not correct, it did add them but I, like Green_Falcon, get localization errors with the words used in the chat. I don't get these errors in my own log file, everything works perfectly, so I'm curious as to why one doesn't get it while the other does.
I tried removing the global directory containing the localization file, but in doing so, everything recorded, deaths, kills, chatting, etc. were all giving me Localization errors. So, I added the localization file back in to at least bv able to record the kills and deaths.
I asked my server provider if their script to start the server uses MOHAA_Server.exe or MOHAA.exe. I saw in a separate post by someone, Yochoy or plague I think, that using MOHAA.exe with developer set to 2 was how they got thiers to work. Hopefully that's it and my server provider makes the adjustment. However, on the off chance they don't change it or that it's not actually the problem, do you or anyone else reading this have any ideas that might clear it up?
Thanks in advance!
Shockwave
12-07-2002, 10:27 AM
Shockwave you said you got yours to work, mabye you could send me one of your config files and log files to see what i am looking for, i would me MOST appriciative.
Done. The information you requested should be in your inbox by now.
I saw in a separate post by someone, Yochoy or plague I think, that using MOHAA.exe with developer set to 2 was how they got thiers to work.
As I said earlier, if you have one server that is working and one that isn't then there must be something different between the two that is causing your problem. If they're both Windows servers with the same version number, then it is most likely either the command line or configuration file that is to blame. Try starting the server that has the problem with the same command line and configuration file that works on your other server and see what happens.
If you can get your wayward server to start logging properly Anex, perhaps you could post what works here to help Green_Falcon get his problem fixed. I run the Linux version so my server information won't be quite as helpful as yours. :)
DCFA-Anex
12-07-2002, 11:38 AM
The one I have working is my local system so the configuration for it and a dedicated server are different. But like you said, I'm sure it's just going to come down to the developer setting added to the command line parm of the right exe file. Unfortunately, I don't have access to the server start up scripts my provider uses so I'll have to wait for them to do it. I'll certainly post whatever works as soon as I get it working.
Thanks for all your help and effort Shockwave, much appreciated :!:
Druid
12-07-2002, 05:16 PM
If your running a customized localization.txt it can also cause problems with recording the frag info.
Check and see if their is a localization.txt in the main\global directory.
If there is then rename it and see if it help with the frag info.
If you still have problems you can go back and rename it to localization.text. This is usually only a problem if the kill statements had been changed.
Green_Falcon
12-08-2002, 01:03 PM
Hey i am STILL having problems, i think that this might be part of the problem, i do not have a localization file in my global folder, yet where do you find a localization file that has not been altered, i need one that will work with frags. I REALLY NEED TO GET FRAGS TO WORK. my team is counting on it. If anyone could send me an untouched localization file please send it to me at
tr_tombraiders@yahoo.com
mabye you have one, shockwave. please send it if you do or if you know where to get one. Thanks i really need the help and am most appriciative
Green Falcon
Druid
12-08-2002, 01:08 PM
If there isn't one in the main/global directory, your already using a stock
localization.txt file. It's in one of the pk3's.
The txt file is only a problem when its been cutomized for new death messages.
Shockwave
12-08-2002, 02:29 PM
The localization.txt file is located in the game server's PAK6.PK3 archive. You can obtain a copy of this file by opening the PK3 file with WinZip and extracting it to your global directory manually.
Green_Falcon
12-09-2002, 02:27 AM
Thanks to everyone that helped me get the frags working, they are working now. Thanks especially to Shockwave you were a big help. I wish i could tell you what i did to get it to work but all i know is i have logfile set to 2 and developer set to 2. Shockwave the files you sent helped the tech support guy see what was wrong and only took a couple hours to get it to work. Thanks again by the way, I am using aestats. Can you keep track off more than one log file. That is what i want to be able to do but i am not sure how. Thanks again
Druid
12-09-2002, 02:48 AM
Grab a copy of the log whenever you shut down the server. Then rename it to whatever.log
ie.. 1.log 2.log 3.log 4.log 5.log
save all the log files to the directry you have aestats program in.
Then in a dos window or with a batch file do
preaes.exe -moh *.log
This will convert all the log files into one moh.mlg.
You can then run the stats program on the single moh.mlg file.
Shockwave
12-09-2002, 12:22 PM
I'm glad to hear that everything is working for you, Green_Falcon!
Regarding log files and stats generation, there are some things you can do to help maintain them. The one thing that I would keep in mind is that log files can get pretty big and concatenating a bunch of them can take a while. I suggest that you take an incremental approach to the situation and simply append the data from your current log file to a statically named statistics log file to save time. Assuming you are already in the directory where the log file exists and you are using the default log filename, this line of code will work under Windows:
type qconsole.log >> stats.log
The code takes the contents of a file named qconsole.log in the current directory and appends its data to the end of a file named stats.log in the same directory. If you're working with Linux, this code will work:
cat qconsole.log >> stats.log
If you adopt this strategy, you never have to worry about creating unique file names for your backup server logs. Druid's method will work, but there are two things to consider. First, you shouldn't have your restart script concatenate the log files because it will delay the restart of your server significantly as soon as you amass a decent amount of log data. A separate batch file for this would be better if this is the way you want to go. Second, unless you adopt a dynamic file naming routine that will always generate a unique name for the backup copy of the log, you will eventually run out of names and overwrite existing data. The best way to avoid this is either to use some type of static counter file that can be read to get the next sequential number for use in the backup copy name and incremented each time it is used, or to use a date/time stamp for the log name.
I spent some time this morning developing a routine you can use under Windows that will archive your game server log file for you. Some of the problems with the native DOS/Windows shell are that you can't read files and arithmatic functions aren't available. This means it gets complicated when you try to do something like this. In any event, I managed to get the following batch file to work. Here it is:
@echo off
REM This batch file creates copies of a log file named "qconsole.log" using
REM an incrementing counter file for the creation of unique filenames. All
REM processing takes place in the directory where this script resides.
REM add another "X" to the counter file
echo X >> counter.txt
REM Count the number of lines in the counter file and save the result in a
REM temporary file
type counter.txt | find /c "X" > temp.txt
REM Run compare function to generate output containing the number of lines
REM that are different between a null file and our temporary file and pipe
REM it through the date command looking for the line from the output that
REM contains the number of different lines. Save that line to a temporary
REM batch file.
fc temp.txt nul /lb1 /n | date | find "1:" > temp.bat
REM Since the first word on the only line in our temporary batch file is the
REM word "Enter" because of how the date command output is formatted, we can
REM use that to our advantage. Create a batch file called "enter.bat" which
REM will be called when we execute temp.bat and use it to assign the 5th
REM command line argument as a part of a unique filename. The 5th command
REM line argument will be the line count from the counter file.
echo copy qconsole.log arch%%5.log > enter.bat
REM execute batch file to archive log data
call temp.bat
REM remove all temporary files
del temp.txt > nul
del temp.bat > nul
del enter.bat > nul
REM indicate processing is complete
echo:
echo Log file archive complete
echo:
Just cut and paste this code into Notepad and save it in your log file directory with a name like log.bat. You can then change your startup script to reference this batch file prior to restarting the server and it will make a backup copy of each game log using the following naming convention:
arch1.log
arch2.log
arch3.log
...
You can also use this in conjunction with the command I mentioned earlier to append the game server log to a static statistics file if you want.
Linux has a much more robust set of commands available and doesn't require the level of trickery used in the Windows batch file I created above. I created a routine for my Linux server that uses a date/time stamp for the filename instead of a sequential counter that works really well. Here's what the script I use looks like:
# change directory to where log is kept
cd ~/.mohaa/main
# save current log file with date/time stamp
echo
echo "Saving log file..."
# create filename date/time stamp - CCYYMMDDHHMMSS
STAMP="`date +%Y%m%d%H%M%S`"
SUFFIX=".log"
cp qconsole.log $STAMP$SUFFIX
echo "Log saved."
echo
As you can see, there's a lot of things you can do with your log file if you take the time to mess around with the setup. :)
Druid
12-09-2002, 01:01 PM
Great info Shockwave
Thanks
Green_Falcon
12-09-2002, 04:39 PM
Hey it is Green again, i was wondering how do you make a restart script, i know this sounds dumb but i am new to this sort of thig, i would really like to use your file below but i dont know where to begin. Thanks GFalcon
vBulletin® v3.7.4, Copyright ©2000-2008, Jelsoft Enterprises Ltd.