Skip to content
Viksit
Gaur
LatestBlogProjects
AboutColophonSubstackX

July 13, 2012

Grep patterns for URLs in logs

Programming & computingtechnical note

For mostly my reference, and anyone else who’s googling for it,

<br></br>cat /tmp/my-log-file.txt | grep --only-matching --perl-regexp "http(s?):\/\/*" | awk '{print $1}'<br></br>

--

If you have any questions or thoughts, don't hesitate to reach out. You can find me as @viksit on Twitter.

← Older postThe future of diagnosticsNewer post →Setting up Emacs, Ensime, SBT for Scala code
© Viksit Gaur 1997–2026
RSSBack to top ↑