<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Brice</title>
    <description>The latest articles on DEV Community by Brice (@roznet).</description>
    <link>https://dev.to/roznet</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F110990%2Fbc741890-ea96-4455-ae45-edeb2d846331.png</url>
      <title>DEV Community: Brice</title>
      <link>https://dev.to/roznet</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/roznet"/>
    <language>en</language>
    <item>
      <title>Word cloud thumbnails for jekyll</title>
      <dc:creator>Brice</dc:creator>
      <pubDate>Sun, 09 Dec 2018 15:32:30 +0000</pubDate>
      <link>https://dev.to/roznet/word-cloud-thumbnails-for-jekyll-4elj</link>
      <guid>https://dev.to/roznet/word-cloud-thumbnails-for-jekyll-4elj</guid>
      <description>&lt;p&gt;I love word cloud. As I have just started a site with jekyll I wondered how would it look to add a word cloud thumbnail to the list of post as a thumbnail and how hard would it be?&lt;/p&gt;

&lt;h2&gt;
  
  
  Building the word cloud images
&lt;/h2&gt;

&lt;p&gt;My first instinct was to see if there was a python package to build wordcloud. I know python quite well, and would definitely be easy to automate the generation of the images. And of course python has usually pretty much any type of &lt;a href="https://xkcd.com/353/" rel="noopener noreferrer"&gt;module you can ever dream of&lt;/a&gt;, so felt like a good start.&lt;/p&gt;

&lt;p&gt;A quick web search later and of course, there is a very nice and easy to &lt;a href="http://amueller.github.io/word_cloud/" rel="noopener noreferrer"&gt;use package&lt;/a&gt; already. Install into my anaconda setup was trivial with &lt;code&gt;conda install -c conda-forge wordcloud&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Then generation of the picture is trivial and take one line:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="n"&gt;wordcloud&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;WordCloud&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;max_words&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;30&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="n"&gt;background_color&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;21&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="mi"&gt;21&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="mi"&gt;21&lt;/span&gt;&lt;span class="p"&gt;)).&lt;/span&gt;&lt;span class="nf"&gt;generate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;to generate the below for this post:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Froznet.github.io%2Fassets%2Fclouds%2F2018-12-09-wordcloud-jekyll-thumbnail.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Froznet.github.io%2Fassets%2Fclouds%2F2018-12-09-wordcloud-jekyll-thumbnail.png"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It was then trivial to loop through the posts files and generate a corresponding word cloud image for each&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;fn&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;allposts&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;endswith&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;.md&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="ow"&gt;and&lt;/span&gt; &lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;isfile&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="n"&gt;fp&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;open&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt; &lt;span class="n"&gt;post_dir&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;r&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;text&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;fp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;read&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
        &lt;span class="n"&gt;wordcloud&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;WordCloud&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;max_words&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;30&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="n"&gt;background_color&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;21&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="mi"&gt;21&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="mi"&gt;21&lt;/span&gt;&lt;span class="p"&gt;)).&lt;/span&gt;&lt;span class="nf"&gt;generate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;outname&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;img_dir&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;[:&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="nf"&gt;len&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;md&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)]&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;png&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;
        &lt;span class="n"&gt;wordcloud&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;to_file&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;outname&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I just picked the background color to match the background I had set in my jekyll site theme.&lt;/p&gt;

&lt;p&gt;I set the &lt;code&gt;img_dir&lt;/code&gt; to be a subfolder &lt;code&gt;/assets/clouds&lt;/code&gt; in the side, et voila, the thumbnails were ready.&lt;/p&gt;

&lt;h2&gt;
  
  
  Adding the thumbnail to the list of posts
&lt;/h2&gt;

&lt;p&gt;Next step was to figure out how to automatically add the image to the list of post. For that I had to find out a bit more about which &lt;a href="https://jekyllrb.com/docs/liquid/filters/" rel="noopener noreferrer"&gt;liquid tag and filters&lt;/a&gt;  were available.&lt;/p&gt;

&lt;p&gt;It was actually quite simple to generate the thumbnail file name replacing the prefix by the path with the images and the suffix with png&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;{% assign filename = post.path | remove_first: '_posts/' | replace: '.md', '.png' | prepend: '/assets/clouds/' %}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I also wanted to make sure if the png didn't exist that the generation would just skip the image. I found out that there was a &lt;code&gt;site.static_files&lt;/code&gt; variables that could help, I just had to iterate through that and see if the required image was found. Which resulted in the following code in my &lt;code&gt;home.html&lt;/code&gt; template:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;      &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;
        {%- assign date_format = site.minima.date_format | default: "%b %-d, %Y" -%}
    {% assign filename = post.path | remove_first: "_posts/" | replace: '.md', '.png' | prepend: "/assets/clouds/" %}
    {% for static_file in site.static_files %}
    {% if static_file.path == filename %}
    &lt;span class="nt"&gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"{{ post.url | relative_url }}"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;img&lt;/span&gt; &lt;span class="na"&gt;src=&lt;/span&gt;&lt;span class="s"&gt;"{{ filename }}"&lt;/span&gt; &lt;span class="na"&gt;width=&lt;/span&gt;&lt;span class="s"&gt;"120px"&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&amp;lt;/a&amp;gt;&lt;/span&gt;
    {% endif %}
    {% endfor %}

        &lt;span class="nt"&gt;&amp;lt;span&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"post-meta"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;{{ post.date | date: date_format }}&lt;span class="nt"&gt;&amp;lt;/span&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;h3&amp;gt;&lt;/span&gt;
          &lt;span class="nt"&gt;&amp;lt;a&lt;/span&gt; &lt;span class="na"&gt;class=&lt;/span&gt;&lt;span class="s"&gt;"post-link"&lt;/span&gt; &lt;span class="na"&gt;href=&lt;/span&gt;&lt;span class="s"&gt;"{{ post.url | relative_url }}"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
            {{ post.title | escape }}
          &lt;span class="nt"&gt;&amp;lt;/a&amp;gt;&lt;/span&gt;
        &lt;span class="nt"&gt;&amp;lt;/h3&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The last stage was to work out how to get the thumbnail properly placed to the left in the list&lt;/p&gt;

&lt;h2&gt;
  
  
  Positioning the thumbnail
&lt;/h2&gt;

&lt;p&gt;This turned out quite trivial to do, after a quick web search. As expected a list with thumbnail is quite a common occurence on the way. Just required a few lines edit to the &lt;code&gt;_layout.scss&lt;/code&gt; file in the post-list class to specify to float the &lt;code&gt;img&lt;/code&gt; under &lt;code&gt;li&lt;/code&gt; and add a margin&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nc"&gt;.post-list&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="err"&gt;li&lt;/span&gt; &lt;span class="err"&gt;img&lt;/span&gt; &lt;span class="err"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;float&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;left&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;15px&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="err"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Automating the generation
&lt;/h2&gt;

&lt;p&gt;The last piece was to automate the process of generating the word cloud images. Easiest way was to create a small python script and a make file to achieve that.&lt;br&gt;
I created a new directory &lt;code&gt;_bld&lt;/code&gt; in my &lt;a href="https://github.com/roznet/roznet.github.io" rel="noopener noreferrer"&gt;website repo&lt;/a&gt;, and simple makefile&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight make"&gt;&lt;code&gt;&lt;span class="nv"&gt;POST_FILES&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;$(&lt;/span&gt;shell find &lt;span class="p"&gt;$(&lt;/span&gt;POST_DIR&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="nt"&gt;-type&lt;/span&gt; f &lt;span class="nt"&gt;-name&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt;.md&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="nv"&gt;IMG_FILES&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;$(&lt;/span&gt;patsubst &lt;span class="p"&gt;$(&lt;/span&gt;POST_DIR&lt;span class="p"&gt;)&lt;/span&gt;/%,&lt;span class="p"&gt;$(&lt;/span&gt;IMG_DIR&lt;span class="p"&gt;)&lt;/span&gt;/%,&lt;span class="p"&gt;$(&lt;/span&gt;POST_FILES:.md&lt;span class="o"&gt;=&lt;/span&gt;.png&lt;span class="p"&gt;))&lt;/span&gt;

&lt;span class="nl"&gt;all&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;$(IMG_FILES)&lt;/span&gt;

&lt;span class="nl"&gt;$(IMG_DIR)/%.png&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;$(POST_DIR)/%.md&lt;/span&gt;
    ./gencloud.py &lt;span class="nt"&gt;-o&lt;/span&gt; &lt;span class="p"&gt;$(&lt;/span&gt;IMG_DIR&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="nv"&gt;$&amp;lt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can see the final code in my &lt;a href="https://github.com/roznet/roznet.github.io" rel="noopener noreferrer"&gt;website repo&lt;/a&gt; and how the list looks &lt;a href="https://roznet.github.io" rel="noopener noreferrer"&gt;here&lt;/a&gt;&lt;/p&gt;

</description>
      <category>python</category>
      <category>jekyll</category>
      <category>webdev</category>
      <category>wordcloud</category>
    </item>
    <item>
      <title>Troubleshooting network issues</title>
      <dc:creator>Brice</dc:creator>
      <pubDate>Mon, 12 Nov 2018 10:38:00 +0000</pubDate>
      <link>https://dev.to/roznet/troubleshooting-network-issues-fn6</link>
      <guid>https://dev.to/roznet/troubleshooting-network-issues-fn6</guid>
      <description>&lt;p&gt;One of the requirement for me in finding a new house was to make sure it had ethernet cabling everywhere so I could ensure I have a stable network and enough access point to get good wifi connectivity in every room.&lt;/p&gt;

&lt;p&gt;When I moved into a new place in August 2016, it met the requirement, but to my and my family dismay, the network and wifi stability was dreadful. It consistently would stall time and time over again. Streaming movies or music want halt for minutes at a time, and reading news on the web would also randomly hang.&lt;/p&gt;

&lt;p&gt;I embarked on a long journey to try to resolve the issue, which would lead me to learn way more about networking that I ever imagined possible…&lt;/p&gt;

&lt;h2&gt;
  
  
  December 2016: The ISP Router
&lt;/h2&gt;

&lt;p&gt;My first guess was that the culprit was my BT router. Though I had moved my line and all my equipment from my previous house where everything was working fine, I suspected that the issue could first be the router being of an older generation that had issue keeping the line. BT at the time offered a new router that supported IPV6, so I figured maybe upgrading that would solve the issue.&lt;/p&gt;

&lt;p&gt;It didn’t change much and the network connectivity continued to be very poor.&lt;/p&gt;

&lt;h2&gt;
  
  
  February 2017: Wifi interference
&lt;/h2&gt;

&lt;p&gt;In my new house, I could see many wifi networks from the neighbors, so I started to suspect that the problem may be interference and my old netgear access point were overwhelmed.&lt;/p&gt;

&lt;p&gt;I wasn’t using the BT router as a wifi access point, because the BT line arrives in the basement and that was too out of the way, I had two older Netgear access point in the house connected via the ethernet cabling.&lt;/p&gt;

&lt;p&gt;So I decided to upgrade to new Netgear R7000 router that I would setup as access points and added a managed Netgear ProSafe switch in the basement to make sure the issue wasn’t from the BT router at all.&lt;/p&gt;

&lt;p&gt;While this helped ensure that the signal strengh was very strong in all the rooms, somehow the network poor performance continued.&lt;/p&gt;

&lt;h2&gt;
  
  
  June 2017: It must be the line
&lt;/h2&gt;

&lt;p&gt;I became then convinced that the problem was the BT line itself. (Spoiler: I was wrong). And colleagues at work told me about AAISP, the provider that was &lt;a href="https://xkcd.com/806/"&gt;shibboleet&lt;/a&gt; compliant. I called them and discussed my problem, they told me that I could switch to them, they have rigourous monitoring of the lines and if it was defective would help me sort it out. I made the switch.&lt;/p&gt;

&lt;p&gt;I can’t recommend AAISP more. They are great. There support is top notch. They have &lt;a href="https://support.aa.net.uk/CQM_Graphs"&gt;control pages&lt;/a&gt; that provides great historical insights on what happened on your line.&lt;/p&gt;

&lt;p&gt;And sure enough, their graphs showed constant drop of the lines for few minutes at a time. I was very excited. Finally a diagnostic that was showing a problem, and AAISP support told me something was definitely wrong and they would help me chase BT to fix the line. But the first thing I had to do is make sure I connected the router to the “test port” of the BT socket to make sure it wasn’t an issue with my internal wiring.&lt;/p&gt;

&lt;p&gt;My socket wasn’t standard and didn’t have a test port! BT would not look at my line until I could show the problem by connecting to that test port. Not to worry, I hired a technician to upgrade my socket to a new standard one and connected the router to the test socket.&lt;/p&gt;

&lt;p&gt;This lead to the problem on the control graph disappearing all together. This was a new low. Now the line appeared to work perfectly, but the performance of my network was still as bad as before.&lt;/p&gt;

&lt;p&gt;The AAISP technician told me it must be an issue with my router or network equipment. So I decided to upgrade the few remaining pieces (a few old switch) to newer one.&lt;/p&gt;

&lt;p&gt;But this didn’t resolve anything. And I started to worry it had to do with my internal wiring or ethernet cable. This prospect was concerning as I started to imagine ripping all the walls to find the cable problem.&lt;/p&gt;

&lt;h2&gt;
  
  
  December 2017: Linux Server Monitor
&lt;/h2&gt;

&lt;p&gt;So if it was an internal cabling issue, I had to try to narrow it down. It couldn’t be all the cables and hopefully I would see which part of the network was the problem.&lt;/p&gt;

&lt;p&gt;I decided to go to the next phase and after some research online decided to try to narrow down the problem by implementing some probes on my network using ping. First I tried to build a little python script from my imac that would ping a few devices regularly to see when the latency would change. This clearly showed some issue, but the script wasn’t reliable and it seemed to be on every part of the network.&lt;/p&gt;

&lt;p&gt;I then decided to move on to getting a small linux server and put some monitoring software on it. First, I hoped it would help me narrow down the problem further, and second, I wanted to get into linux.&lt;/p&gt;

&lt;p&gt;I ordered a &lt;a href="https://www.intel.com/content/www/us/en/products/boards-kits/nuc.html"&gt;NUC computer&lt;/a&gt;. These are great little piece of hardware, reasonably priced and perfect to be left headless next to my main switch and router as a server/monitor. I installed ubuntu on it and among other tools, installed &lt;a href="https://oss.oetiker.ch/smokeping/"&gt;smokeping&lt;/a&gt;. I configured it to ping from the linux server to most hardware equipement (switches, access points, computer) in my network to see if one part of the network was the problem.&lt;/p&gt;

&lt;p&gt;The graphs were dreadful, a lot of “dark” smoke and many dropped packets. Though far from 100% loss, the network was somewhat working but no single device was the issue: Everything was dark!&lt;/p&gt;

&lt;h2&gt;
  
  
  January 2018: Upgrade of the last switch
&lt;/h2&gt;

&lt;p&gt;Completely out of ideas, I decided to upgrade the last older switch I had to a new one. Not that I believed at that point it would help much, but I really didn’t know what to do anymore and was secretely hoping the problem was a single defective device.&lt;/p&gt;

&lt;p&gt;This didn’t help of course, the performance continued to dreadful and the smokeping graphs remained stubornly dark throughout the network.&lt;/p&gt;

&lt;p&gt;But upgrading that last switch, ultimately led me to the solution…&lt;/p&gt;

&lt;h2&gt;
  
  
  February 2018: Epiphany!
&lt;/h2&gt;

&lt;p&gt;After upgrading that last switch I noticed that the imac, hardwired by ethernet, I was using to log in remotely to my linux server started to behave much worse than before. While devices on wifi were always showing the worst network performance, the hardwired computer also but to a less extent. Though, after upgrading that last switch, to which the imac was connected, performance became very clearly worse. The connection to the linux server would constantly drop or stall.&lt;/p&gt;

&lt;p&gt;So getting a new switch made things worse to my imac? What gives?&lt;/p&gt;

&lt;p&gt;I reviewed the connection of the switched and realized that I had forgotted to connect the switch to the wall ethernet socket!&lt;/p&gt;

&lt;p&gt;How was this possible? I could I have internet access while I had not connected the switch to the intranet???&lt;/p&gt;

&lt;p&gt;This was the final clue! I have a Sonos system and one of the Sonos speaker is also connected to the switch and disconnecting the Sonos speaker dropped the internet all together.&lt;/p&gt;

&lt;p&gt;Sonos is creating a mesh network over wifi (its own wifi, not my main network). After searching on this on the web, I found out that Sonos is using the &lt;a href="https://en.community.sonos.com/troubleshooting-228999/sonos-and-the-spanning-tree-protocol-16973"&gt;spanning tree protocol&lt;/a&gt; to prevent loops. But then it occured to me that it must not work somehow with the netgear devices I had and creating intermittent random loops that lead to the network performance.&lt;/p&gt;

&lt;p&gt;I found online information about &lt;a href="https://bsteiner.info/articles/disabling-sonos-wifi"&gt;turning off the wifi&lt;/a&gt; on Sonos Devices as all my devices are also hardwired.&lt;/p&gt;

&lt;p&gt;And since then, we enjoy top notch network and wifi performance in the house, partly thanks to all these upgrade network components :)&lt;/p&gt;

&lt;p&gt;You can see on the smoke ping graph how clean the network is since that fix and compare to the dark smoke of the previous network situation…&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s---OOnqm5x--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://roznet.github.io/assets/smokeping.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s---OOnqm5x--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://roznet.github.io/assets/smokeping.png" alt="SmokePing"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>network</category>
    </item>
  </channel>
</rss>
