Macro Help - web logs

CybGeek

New Member
Joined
Nov 12, 2019
Messages
2
Complete Macro noob here...
I am working with a very large data set (5,000+ rows, 57 columns) of web server logs. These logs contain a great deal of noise I need cleaned out. The best column to do this from would be the Destination IP addresses. There are over 250 unique addresses. I need to strip out 137 unique addresses and the entire row associated with each to isolate specific browsing behavior. I figured a vlookup from another sheet would work. But I'm not positive.
The format of this column is as follows:

[TABLE="width: 200"]
<tbody>[TR]
[TD]DestinationIP[/TD]
[/TR]
[TR]
[TD]DestIP="111.222.133.44"[/TD]
[/TR]
[TR]
[TD]DestIP="33.44.66.77"[/TD]
[/TR]
[TR]
[TD]DestIP="125.89.143.23"[/TD]
[/TR]
[TR]
[TD]DestIP="76.945.34.87"[/TD]
[/TR]
[TR]
[TD]DestIP="45.347.33.89"[/TD]
[/TR]
[TR]
[TD]DestIP="44.3.22.454"[/TD]
[/TR]
[TR]
[TD]DestIP="130.79.142.56"[/TD]
[/TR]
[TR]
[TD]DestIP="87.56.23.17"[/TD]
[/TR]
[TR]
[TD]DestIP="52.34.576.34"[/TD]
[/TR]
[TR]
[TD]DestIP="53.55.123.45"[/TD]
[/TR]
</tbody>[/TABLE]

(Disclaimer: These are random made up IPs, most of which are not in valid format to protect privacy).
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
Do you have a list of the IP addresses you are interested in?
 
Upvote 0
Do you have a list of the IP addresses you are interested in?

I gave mock addresses. I can change those myself in the code. I just don't know how to write/form an adequate script that will take out 137 addresses + the associated row in order to clean up this data and make it more readable for an analyst.
 
Upvote 0
You could probably do this without code.

For a start you could use a MATCH formula to check the IPs in the Destination IP address columns against the list of IPs you want to keep.

You could then filter on that column to exclude IPs that don't match and copy the returned rows to another sheet.
 
Upvote 0

Forum statistics

Threads
1,223,239
Messages
6,170,947
Members
452,368
Latest member
jayp2104

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top