[nos-bbs] Changing JNOS log file name

Wm Lewis thunderft at hotmail.com
Mon Sep 29 12:05:57 EDT 2014


Thanks, Bob.

 

That seems to have done the trick.

 

Bill

KG6BAJ
 



Date: Sun, 28 Sep 2014 05:45:39 -0400
From: bobtenty at gmail.com
To: nos-bbs at tapr.org
Subject: Re: [nos-bbs] Changing JNOS log file name


Yes that is possible, I changed the name to "nos.log"

Open main.c of the source with an editor and look for the line....

sprintf (ML, "%s/%2.2s%3.3s%2.2s", LogsDir, cp + 8, cp + 4, cp + 22);

- Around line 1101 in function nos_log() -

I changed it to:


  /*    sprintf (ML, "%s/%2.2s%3.3s%2.2s", LogsDir, cp + 8, cp + 4, cp + 22);  */

      sprintf(ML, "%s/%s", LogsDir, "nos.log");       /* 28Sep2014, Boudewijn(Bob) VE3TOK, changed log name to nos.log */


Recompile!

73,

Bob VE3TOK





On 14-09-27 11:58 PM, Wm Lewis wrote:




Currently JNOS automatically names its log files in the format [ddmmyy] (example : "25Sept14" or "01Jan14")
 
Is there a way to change the name of the logs to something like "jnos.log" and have jnos always leave the log file name the same?
 
Then I could use use linux's log-rotate feature to rotate the logs say, once a week.
 
I'm using an intrusion detection software scanning the logs for "bad login" and automatically ban ip addresses that have 3 or more failed login attempts, via an iptables drop command.
 
Only, the intrusion detection software (Fail2Ban) needs the log file name to always be the same name. 
 
Anyone know if it's possible to setup jnos so it always keeps the log file name the same?
 
Thanks
Bill - KG6BAJ 


 
_______________________________________________
nos-bbs mailing list
nos-bbs at tapr.org
http://www.tapr.org/mailman/listinfo/nos-bbs


_______________________________________________ nos-bbs mailing list nos-bbs at tapr.org http://www.tapr.org/mailman/listinfo/nos-bbs 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.tapr.org/pipermail/nos-bbs_lists.tapr.org/attachments/20140929/d997a157/attachment.html>


More information about the nos-bbs mailing list