154 lines
6.1 KiB
HTML
154 lines
6.1 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en-us">
|
|
<head><script src="/livereload.js?mindelay=10&v=2&port=1313&path=livereload" data-no-instant defer></script>
|
|
<meta charset="utf-8">
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
|
|
|
<title>My New Hugo Site</title>
|
|
<meta name="viewport" content="width=device-width,minimum-scale=1">
|
|
<meta name="description" content="Network monitoring
|
|
Discover all devices connected to the local network:
|
|
#!/bin/bash
|
|
subnet="192.168.0"
|
|
for suffix in $(seq 101 199); do
|
|
ip_address="$subnet.$suffix"
|
|
# Only wait 1 second for each response: ping should only take a few
|
|
# milliseconds on LAN.
|
|
ping -c 1 -W 1 $ip_address | grep "64 bytes from $ip_address" | awk '{ print $4 }' | sed s/://
|
|
done
|
|
">
|
|
<meta name="generator" content="Hugo 0.145.0">
|
|
|
|
|
|
|
|
<meta name="robots" content="noindex, nofollow">
|
|
|
|
|
|
|
|
|
|
<link rel="stylesheet" href="/ananke/css/main.min.css" >
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<link rel="canonical" href="http://localhost:1313/home-network/admin/monitoring/">
|
|
|
|
|
|
<meta property="og:url" content="http://localhost:1313/home-network/admin/monitoring/">
|
|
<meta property="og:site_name" content="My New Hugo Site">
|
|
<meta property="og:title" content="My New Hugo Site">
|
|
<meta property="og:description" content="Network monitoring Discover all devices connected to the local network:
|
|
#!/bin/bash subnet="192.168.0" for suffix in $(seq 101 199); do ip_address="$subnet.$suffix" # Only wait 1 second for each response: ping should only take a few # milliseconds on LAN. ping -c 1 -W 1 $ip_address | grep "64 bytes from $ip_address" | awk '{ print $4 }' | sed s/:// done">
|
|
<meta property="og:locale" content="en_us">
|
|
<meta property="og:type" content="article">
|
|
<meta property="article:section" content="home-network">
|
|
|
|
<meta itemprop="name" content="My New Hugo Site">
|
|
<meta itemprop="description" content="Network monitoring Discover all devices connected to the local network:
|
|
#!/bin/bash subnet="192.168.0" for suffix in $(seq 101 199); do ip_address="$subnet.$suffix" # Only wait 1 second for each response: ping should only take a few # milliseconds on LAN. ping -c 1 -W 1 $ip_address | grep "64 bytes from $ip_address" | awk '{ print $4 }' | sed s/:// done">
|
|
<meta itemprop="wordCount" content="60">
|
|
<meta name="twitter:card" content="summary">
|
|
<meta name="twitter:title" content="My New Hugo Site">
|
|
<meta name="twitter:description" content="Network monitoring Discover all devices connected to the local network:
|
|
#!/bin/bash subnet="192.168.0" for suffix in $(seq 101 199); do ip_address="$subnet.$suffix" # Only wait 1 second for each response: ping should only take a few # milliseconds on LAN. ping -c 1 -W 1 $ip_address | grep "64 bytes from $ip_address" | awk '{ print $4 }' | sed s/:// done">
|
|
|
|
|
|
</head><body class="ma0 avenir bg-near-white development">
|
|
|
|
|
|
|
|
|
|
|
|
<header>
|
|
<div class="bg-black">
|
|
<nav class="pv3 ph3 ph4-ns" role="navigation">
|
|
<div class="flex-l justify-between items-center center">
|
|
<a href="/" class="f3 fw2 hover-white no-underline white-90 dib">
|
|
|
|
My New Hugo Site
|
|
|
|
</a>
|
|
<div class="flex-l items-center">
|
|
|
|
|
|
|
|
<div class="ananke-socials"></div>
|
|
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
|
|
</div>
|
|
</header>
|
|
|
|
|
|
|
|
<main class="pb7" role="main">
|
|
|
|
|
|
|
|
<article class="flex-l flex-wrap justify-between mw8 center ph3">
|
|
<header class="mt4 w-100">
|
|
<aside class="instapaper_ignoref b helvetica tracked ttu">
|
|
|
|
Home-Networks
|
|
</aside><div id="sharing" class="mt3 ananke-socials"></div>
|
|
<h1 class="f1 athelas mt3 mb1"></h1>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</header>
|
|
<div class="nested-copy-line-height lh-copy serif f4 nested-links mid-gray pr4-l w-two-thirds-l"><h1 id="network-monitoring">Network monitoring</h1>
|
|
<p>Discover all devices connected to the local network:</p>
|
|
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-bash" data-lang="bash"><span style="display:flex;"><span><span style="color:#75715e">#!/bin/bash
|
|
</span></span></span><span style="display:flex;"><span><span style="color:#75715e"></span>subnet<span style="color:#f92672">=</span><span style="color:#e6db74">"192.168.0"</span>
|
|
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">for</span> suffix in <span style="color:#66d9ef">$(</span>seq <span style="color:#ae81ff">101</span> 199<span style="color:#66d9ef">)</span>; <span style="color:#66d9ef">do</span>
|
|
</span></span><span style="display:flex;"><span> ip_address<span style="color:#f92672">=</span><span style="color:#e6db74">"</span>$subnet<span style="color:#e6db74">.</span>$suffix<span style="color:#e6db74">"</span>
|
|
</span></span><span style="display:flex;"><span> <span style="color:#75715e"># Only wait 1 second for each response: ping should only take a few</span>
|
|
</span></span><span style="display:flex;"><span> <span style="color:#75715e"># milliseconds on LAN.</span>
|
|
</span></span><span style="display:flex;"><span> ping -c <span style="color:#ae81ff">1</span> -W <span style="color:#ae81ff">1</span> $ip_address | grep <span style="color:#e6db74">"64 bytes from </span>$ip_address<span style="color:#e6db74">"</span> | awk <span style="color:#e6db74">'{ print $4 }'</span> | sed s/://
|
|
</span></span><span style="display:flex;"><span><span style="color:#66d9ef">done</span>
|
|
</span></span></code></pre></div><ul class="pa0">
|
|
|
|
</ul>
|
|
<div class="mt6 instapaper_ignoref">
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
<aside class="w-30-l mt6-l">
|
|
|
|
|
|
|
|
|
|
</aside>
|
|
|
|
</article>
|
|
|
|
</main>
|
|
<footer class="bg-black bottom-0 w-100 pa3" role="contentinfo">
|
|
<div class="flex justify-between">
|
|
<a class="f4 fw4 hover-white no-underline white-70 dn dib-ns pv2 ph3" href="http://localhost:1313/" >
|
|
© My New Hugo Site 2025
|
|
</a>
|
|
<div><div class="ananke-socials"></div>
|
|
</div>
|
|
</div>
|
|
</footer>
|
|
|
|
</body>
|
|
</html>
|