Delete log data

This support forum board is for support questions relating to Nagios Log Server, our solution for managing and monitoring critical log data.
Locked
cockraml
Posts: 28
Joined: Tue May 07, 2013 8:10 am

Delete log data

Post by cockraml »

I messed up when trying to import data from a file. How do I delete the data out of the log server?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Delete log data

Post by scottwilkerson »

If you go to Admin -> Index Status

You can delete any or all of the daily indexes
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
cockraml
Posts: 28
Joined: Tue May 07, 2013 8:10 am

Re: Delete log data

Post by cockraml »

scottwilkerson wrote:If you go to Admin -> Index Status

You can delete any or all of the daily indexes

I apologize, but all I see is a status of how many documents, total shards, and other statistics. How do I remove the data?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Delete log data

Post by scottwilkerson »

In the Actions column on the right you can click "delete"

Or for days other than the current day, you can check all the boxes and choose delete from the "With selected indices: " drop down on the bottom
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Delete log data

Post by scottwilkerson »

If you only have a current day index you may need to run the following from the CLI

Code: Select all

curl -XDELETE localhost:9200/logstash-2018.07.19/
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
cockraml
Posts: 28
Joined: Tue May 07, 2013 8:10 am

Re: Delete log data

Post by cockraml »

scottwilkerson wrote:In the Actions column on the right you can click "delete"

Or for days other than the current day, you can check all the boxes and choose delete from the "With selected indices: " drop down on the bottom
I am sorry, but I don't see an actions column. Please see my attached screenshot.
Screen Shot 2018-07-19 at 3.19.19 PM.png
You do not have the required permissions to view the files attached to this post.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Delete log data

Post by scottwilkerson »

Yes, it auto-drills in to this if you only have 1 index, the following will delete that index, and then it will be re-created when the first new log comes in.
scottwilkerson wrote:If you only have a current day index you may need to run the following from the CLI

Code: Select all

curl -XDELETE localhost:9200/logstash-2018.07.19/
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
cockraml
Posts: 28
Joined: Tue May 07, 2013 8:10 am

Re: Delete log data

Post by cockraml »

scottwilkerson wrote:Yes, it auto-drills in to this if you only have 1 index, the following will delete that index, and then it will be re-created when the first new log comes in.
scottwilkerson wrote:If you only have a current day index you may need to run the following from the CLI

Code: Select all

curl -XDELETE localhost:9200/logstash-2018.07.19/

Thank you, this helped.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Delete log data

Post by scottwilkerson »

cockraml wrote:
scottwilkerson wrote:Yes, it auto-drills in to this if you only have 1 index, the following will delete that index, and then it will be re-created when the first new log comes in.
scottwilkerson wrote:If you only have a current day index you may need to run the following from the CLI

Code: Select all

curl -XDELETE localhost:9200/logstash-2018.07.19/

Thank you, this helped.
Locking thread.
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked