Community discussions

MikroTik App
phil@nowires.com.au
newbie
Topic Author
Posts: 45
加入: Sat Feb 05, 2005 5:15 am
Location:Tamworth, NSW, Australia
Contact:

Delete the usermanager log.

Wed Oct 04, 2006 2:07 am

Howdy,

Is there a way to remove/delete the usermanager log?

I have a usermanager log of over 330,000 items, mainly authentication failures generated pre-2.9.30 before the logging options became available.

I noticed that when i open the log in usermanager that my routers CPU utilisation goes to 100% for several seconds. Resorting the log also causes several seconds of 100% router CPU utilisataion.

Regards...ƒil
Top
uldis
MikroTik Support
MikroTik Support
Posts: 3446
加入: Mon May 31, 2004 2:55 pm

Wed Oct 04, 2006 11:31 am

we are working on that, in the one of the next versions you will be able to delete the logs and sessions.
Top
用户头像
balimore
Forum Veteran
Forum Veteran
Posts: 884
加入: Mon Apr 10, 2006 3:38 am

Fri Oct 13, 2006 12:23 pm

we are working on that, in the one of the next versions you will be able to delete the logs and sessions.
----
again, thaaaaannnk youuuu ULDIS and MT Team

Hasbullah.com
----
Top
allac
newbie
Posts: 46
加入: Fri Jan 27, 2006 9:42 pm

Sun Apr 22, 2007 9:50 pm

Schedule script for task you
Top
allac
newbie
Posts: 46
加入: Fri Jan 27, 2006 9:42 pm

Sat Apr 28, 2007 6:32 pm

Schedule folow script, interval 20 seconds.

file receive all log and you manager file.
Code:Select all
:local Flag :set Flag [/tool user-manager log find] :if ([:len $Flag] > 0) do={/tool user-manager log print append file log;/tool user-manager log remove [/tool user-manager log find];}
Top
phil@nowires.com.au
newbie
Topic Author
Posts: 45
加入: Sat Feb 05, 2005 5:15 am
Location:Tamworth, NSW, Australia
Contact:

Sun Apr 29, 2007 3:01 am

Hi Allac,

Thanks so much, your script has removed all my logs. It did take about 45 minutes at ~90% processor...i was worried that it would never finish.

Thanks again mate.
Top
csickles
Forum Guru
Forum Guru
Posts: 1255
加入: Fri May 28, 2004 8:46 pm
Location:Phoenix, AZ
Contact:

Sun Apr 29, 2007 6:24 am

External logging would be an idea..
Top
用户头像
deleola1
刚刚加入了
Posts: 17
加入: Fri Mar 02, 2007 8:28 pm
Location:Nigeria

Sessions Reseting

Fri May 04, 2007 5:30 pm

Schedule folow script, interval 20 seconds.

file receive all log and you manager file.
Code:Select all
:local Flag :set Flag [/tool user-manager log find] :if ([:len $Flag] > 0) do={/tool user-manager log print append file log;/tool user-manager log remove [/tool user-manager log find];}

Please How do I run this schedule I dont know how?
Pls. direct me on step by step via console of Terminal
Top
Trisc
Member Candidate
Member Candidate
Posts: 242
加入: Sat May 29, 2004 11:24 pm
Location:Glos, UK

Wed May 09, 2007 7:01 pm

我试着运行is script manually - but nothing happened apart from maxing out the CPU for 2-3 minutes.
Top
phil@nowires.com.au
newbie
Topic Author
Posts: 45
加入: Sat Feb 05, 2005 5:15 am
Location:Tamworth, NSW, Australia
Contact:

Thu May 10, 2007 4:24 am

The script worked perfectly for me.

I only pasted the script in and ran it manually. In winbox, system->scripts create new, paste in the script. Highlight and click run script button.

It created a (250MB) log file in the root directory of my usermanager router. The complete 330,000 item usermanager log was removed.
I didn't even bother to have a look at what the log file contained, I just deleted it.
Top
用户头像
airstream
Member Candidate
Member Candidate
Posts: 188
加入: Fri Feb 03, 2006 6:33 am
Location:New Zealand

Re: Delete the usermanager log.

Thu Aug 09, 2007 1:22 am

Thanks allac, this is a great script that works for me without hassle.
Top

Who is online

Users browsing this forum: No registered users and 2 guests