I want to extract the domain from the URL field present in my logs.
The URL fields are kind of
1 99.99.115.10/.aaa_dap.html
2 99.99.115.10/.index.html
3 99.99.115.10/aaa_dap.html?name=/*
4 99.99.115.10/aaa_dap/.html
5 **99.99.115.10/index.html?name=/
6 99.99.115.10/index/.html
7 *[fed0:9999::1151]/.aaa_dap.html
8 **[fed0:9999::1151]/.index.html
9 [fed0:9999::1151]/aaa_dap.html?name=/*
10 [fed0:9999::1151]/aaa_dap/.html
11 *[fed0:9999::1151]/index.html?name=/*
12 **[fed0:9999::1151]/index/.html
13 **fed0:9999::1151/name?nameee=/
14 my.domain.com/index.html
15 you.mydomain.org/home.html
I want to extract the bold letters. how to do this?
Thanks...
You could also use the "Field Extractor" app if it gets really specific.
You could also use the "Field Extractor" app if it gets really specific.
As I don't really know what your entire log looks like, I'll just write the expression that fits for the data you've provided.
^\d+\s+([^/]+)\/
Also, you might think about using the field extraction mechanics inside the UI. It's very helpful when trying to figure out tricky expressions.