msound.tech - via RSS









Search Preview

msound.tech

msound.tech
Jekyll2017-07-19T07:18:23+00:00https://msound.tech//msound.techMani Soundararajan is a web developer who specializes in PHP, Drupal and DevOps. He loves Do
.tech > msound.tech

SEO audit: Content analysis

Language Error! No language localisation is found.
Title msound.tech
Text / HTML ratio 91 %
Frame Excellent! The website does not use iFrame solutions.
Flash Excellent! The website does not have any flash contents.
Keywords cloud DNS
  
server class=highlighterrouge> date ext4 case servers open >

= free performance running based hour

Keywords consistency
Keyword Content Title Description Headings
DNS 21
18
12
12
12
server 11
Headings Error! The website does not use (H) tags.
Images We found 0 images on this web page.

SEO Keywords (Single)

Keyword Occurrence Density
DNS 21 1.05 %
18 0.90 %
12 0.60 %
12 0.60 %
12 0.60 %
server 11 0.55 %
class=highlighterrouge> 11 0.55 %
10 0.50 %
date 10 0.50 %
ext4 10 0.50 %
case 8 0.40 %
servers 8 0.40 %
open 7 0.35 %
>

7 0.35 %
= 7 0.35 %
free 7 0.35 %
performance 6 0.30 %
running 6 0.30 %
based 6 0.30 %
hour 6 0.30 %

SEO Keywords (Two Word)

Keyword Occurrence Density
 
12 0.60 %
11 0.55 %
you can 11 0.55 %
DNS server 8 0.40 %
of the 8 0.40 %
in the 7 0.35 %
in a 7 0.35 %
you are 7 0.35 %
to do 6 0.30 %
is the 6 0.30 %
If you 6 0.30 %
the 6 0.30 %
to the 5 0.25 %
alt=Jenkins screenshot 5 0.25 %
with the 5 0.25 %
server is 5 0.25 %
This is 5 0.25 %
is a 5 0.25 %
your ISP’s 5 0.25 %
date = 5 0.25 %

SEO Keywords (Three Word)

Keyword Occurrence Density Possible Spam
seconds in a 5 0.25 % No
DNS server is 5 0.25 % No
bytes from 8888 4 0.20 % No
alt=Jenkins screenshot >

4 0.20 % No
64 bytes from 4 0.20 % No
nslookup
3 0.15 % No
  • Analyze the message
  • 3 0.15 % No
    the message and 3 0.15 % No
    is written to 3 0.15 % No
    written to the 3 0.15 % No
    mntnewvar 3 0.15 % No
    ms 64 bytes 3 0.15 % No
    the IP address 3 0.15 % No
    class=highlighterrouge>
    nslookup googlecoin
    3 0.15 % No
    class=highlight>date_default_timezone_setAmericaNew_York date = 3 0.15 % No
    your ISP’s DNS 3 0.15 % No
    class=highlighterrouge>
    date_default_timezone_setAmericaNew_York date
    3 0.15 % No
    a new partition 3 0.15 % No
    date_default_timezone_setAmericaNew_York
    3 0.15 % No
    this

    3 0.15 % No

    SEO Keywords (Four Word)

    Keyword Occurrence Density Possible Spam
    64 bytes from 8888 4 0.20 % No
    class=highlighterrouge>
    date_default_timezone_setAmericaNew_York date =
    3 0.15 % No
    is written to the 3 0.15 % No
    ms 64 bytes from 3 0.15 % No
  • Analyze the message and
  • 3 0.15 % No
    nslookup googlecoin
    3 0.15 % No
    date_default_timezone_setAmericaNew_York date
    3 0.15 % No
    like IRC or Slack 2 0.10 % No
    tool like IRC or 2 0.10 % No
    chat tool like IRC 2 0.10 % No
    from within your chat 2 0.10 % No
    your chat tool like 2 0.10 % No
    within your chat tool 2 0.10 % No
    DevOps from within your 2 0.10 % No
    your DevOps from within 2 0.10 % No
    running your DevOps from 2 0.10 % No
    like this

    2 0.10 % No
    open Does it mean 2 0.10 % No
    this

    date_default_timezone_setAmericaNew_York
    2 0.10 % No
    of running your DevOps 2 0.10 % No

    Msound.tech Spined HTML


    Jekyll2017-07-19T07:18:23+00:00https://msound.tech//msound.techMani Soundararajan is a web developer who specializes in PHP, Drupal and DevOps. He loves Docker and his latest interests include go lang. When he is not hacking, he likes to go on cross-country motorbike rides. Google Cloud Summit - New York2017-07-17T23:00:00+00:002017-07-17T23:00:00+00:00https://msound.tech/2017/07/17/google-cloud-summit-new-york<p>Here are some of the key takeaways from the summit:</p> <h2 id="machine-learning-is-already-here">1. Machine Learning is once here</h2> <p>Machine Learning (ML) was the main focus in the whole summit. A few customers are once running production workloads on various ML products offered by Google Cloud. All of the products are in General Availability with the exception of newly launched Video Intelligence API which is in beta.</p> <p>All products have a demo page where you can play with the API. No need to sign up or login or anything.Trammelsout these demos:</p> <p><a href="https://cloud.google.com/vision/">Cloud Vision API</a></p> <p>I dragged and dropped a meme and got this as the output:</p> <p><img src="/assets/gc-cloud-vision-1.png" alt="Cloud vision demo" /></p> <p><img src="/assets/gc-cloud-vision-2.png" alt="Cloud vision demo" /></p> <p><a href="https://cloud.google.com/natural-language/">Cloud Natural Language API</a></p> <p>I tried the demo with this text, a restaurant review I wrote on seamless older tonight:</p> <blockquote> <p>The Good: Naan was good. It was soft and light. The Bad: Very few pieces of Paneer in Palak Paneer. Also, the Palak was not pureed/blended as one would expect in Palak Paneer, it was increasingly like Saag Paneer. The Ugly: Basmati rice was stale, and smelling bad. Verdict: Not ordering from here again.</p> </blockquote> <p>And this is the output I got:</p> <p><img src="/assets/gc-natural-language-1.png" alt="Cloud natural language demo" /></p> <h2 id="the-algo-is-free-but-the-data-is-not">2. The algo is free, but the data is not</h2> <p>When TensorFlow was first spoken as an unshut source project, Wired magazine nailed it when they said <a href="https://www.wired.com/2015/11/google-open-sources-its-artificial-intelligence-engine/">“the algorightm is free, its the data that is precious”</a>. They could not have said it better. This is unveiled in the product offerings.</p> <p>ML as a Service. Google Cloud Machine Learning Engine is a compute engine with a custom GPU based chip. With this machine, you can write your own TensorFlow based programs and run your training set. This is the self-ruling part where the software is free. But to do this, you will need ML engineers and a decent value of training data.</p> <p>Models as a Service. On the other hand, they have ready-made pre-trained models (such as the vision model and the natural language model) which you can slosh via HTTP REST API. The data used for training the models, as well as the model itself are proprietary. You can only use them via API. This is where the windbreak of entry is very low. Most web developers are familiar with REST APIs and can hands build applications based on these APIs. A lot of speakers were using flourish writ on their terminal for demos, showing how easy it is to use these APIs.</p> <h2 id="ml-in-customer-service">3. ML in consumer service</h2> <p>Two specimen studies were presented showcasing companies using ML in consumer service. The first specimen study was Ocado, a UK based online grocery store. They were using the Natural Language Processing (NLP) sufficiency to do three things:</p> <ul> <li>Analyze the message and classify the ticket as upper or low priority</li> <li>Analyze the message and route it to correct consumer service team</li> <li>Analyze the message and tropical the ticket if it appears that the issue has been resolved</li> </ul> <p>Read increasingly well-nigh the <a href="http://ocadotechnology.com/blog/how-ocado-uses-machine-learning-to-improve-customer-service/">Ocado specimen study</a>.</p> <p>Another specimen study involved a visitor that uses NLP on consumer emails to decide:</p> <ul> <li>Which field technician (based on skill set) to send out to fix a problem</li> <li>What tools they should carry</li> <li>What spares they should carry</li> </ul> <p>Obviously they are sitting on a mountain of emails linked to work orders to track which emails resulted in which spares etc. This was used as a training set to predict what spares might be required based just on the email from the consumer reporting the problem.</p>Here are some of the key takeaways from the summit:Are there 86400 seconds in a day?2017-02-25T19:50:00+00:002017-02-25T19:50:00+00:00https://msound.tech/2017/02/25/are-there-86400-seconds-in-a-day<p>There are 24 hours in a day, 60 minutes in an hour and 60 seconds in a minute.</p> <p>So, there should be 24 * 60 * 60 = 86400 seconds in a day.</p> <p>Seems fairly straightforward. Let’s put this to test. Let’s print the first 10 days of November 2016.</p> <p>Here’s a simple way to do this:</p> <div class="highlighter-rouge"><pre class="highlight"><code>date_default_timezone_set("America/New_York"); $date = strtotime("2016-11-01 00:00:00"); for ($i=0; $i &lt; 10; $i++) { reverberate date("m/d/Y", $date) . "\n"; $date += 86400; } </code></pre> </div> <p>Let’s run this and squint at the output:</p> <div class="highlighter-rouge"><pre class="highlight"><code>11/01/2016 11/02/2016 11/03/2016 11/04/2016 11/05/2016 11/06/2016 11/06/2016 11/07/2016 11/08/2016 11/09/2016 </code></pre> </div> <p>November 6th appears twice! How is that possible?</p> <p>This is considering in the first line of the code, I had set the timezone as <code class="highlighter-rouge">America/New_York</code> and New York observes <a href="https://en.wikipedia.org/wiki/Daylight_saving_time">Daylight saving time</a>. In North America, every year on the second Sunday of March, the clock jumps from 01:59:59 to 03:00:00, thereby skipping an unshortened hour. This hour is later adjusted on the second Sunday of November when the clock goes from 01:59:59 when to 01:00:00, gaining when the hour that was lost in March. In other words, there were 25 hours on November 6th 2016.</p> <p>To see exactly what is happening in our code, let’s modify it slightly and have it print the stage and the time.</p> <div class="highlighter-rouge"><pre class="highlight"><code>date_default_timezone_set("America/New_York"); $date = strtotime("2016-11-01 00:00:00"); for ($i=0; $i &lt; 10; $i++) { reverberate date("m/d/Y H:i:s", $date) . "\n"; $date += 86400; } </code></pre> </div> <p>And now the output reads:</p> <div class="highlighter-rouge"><pre class="highlight"><code>11/01/2016 00:00:00 11/02/2016 00:00:00 11/03/2016 00:00:00 11/04/2016 00:00:00 11/05/2016 00:00:00 11/06/2016 00:00:00 11/06/2016 23:00:00 11/07/2016 23:00:00 11/08/2016 23:00:00 11/09/2016 23:00:00 </code></pre> </div> <p>We went from midnight to 11pm considering of the uneaten hour in the day, and that is why November 6th appears twice.</p> <p>Please withstand in mind, countries in Europe have a variegated schedule - from the last Sunday in March to the last Sunday in October. To remoter complicate things, countries in Southern Hemisphere have yet flipside schedule.</p> <p>If you wish to jump to the next date, use the <code class="highlighter-rouge">strtotime()</code> function with a relative offset, like this:</p> <div class="highlighter-rouge"><pre class="highlight"><code>date_default_timezone_set("America/New_York"); $date = strtotime("2016-11-06 00:00:00"); $next_day = strtotime("+1 day", $date); reverberate date("Y-m-d H:i:s", $next_day) . "\n"; </code></pre> </div> <p>And this will correctly requite you:</p> <div class="highlighter-rouge"><pre class="highlight"><code>2016-11-07 00:00:00 </code></pre> </div> <p>In conclusion, do not use 86400 as a measure of number of seconds in a day.</p>There are 24 hours in a day, 60 minutes in an hour and 60 seconds in a minute.Chat Ops2015-10-15T22:04:22+00:002015-10-15T22:04:22+00:00https://msound.tech/2015/10/15/chat-ops<p><strong>Chat Ops</strong> is the practice of running your DevOps from within your yack tool, like IRC or Slack etc.</p> <p>This post explains how you can implement ChatOps in your organization using Hubot.</p> <p>In 2011 Github released <a href="https://hubot.github.com/">Hubot</a>, an unshut source chatbot which was modeled without their internal chatbot. Apparently, Github internally used this chatbot to push deployments to their production server.</p> <p>Hubot can interface with many yack applications like Slack, IRC, HipChat and many increasingly using Adapters. If you are using one of the popular yack applications, you should be worldly-wise to hands find an <a href="https://www.npmjs.com/search?q=hubot%20adapter&amp;page=1&amp;ranking=popularity">adapter</a> for that.</p> <p>Traditionally, Slack integrations turned Slack channels into information sinks. We get notifications from Github that someone opened a PR, notifications from Jira that someone completed a task, notifications from Jenkins that a build was successfully completed etc. This can soon turn into information overload where your waterworks is so rented that it constantly keeps scrolling. And soon enough, you will learn that there is a mute sawed-off on Slack for muting notifications, considering you just word-stock take the unvarying <em>ding</em> from that channel.</p> <p>Hubot flips that around. With Hubot, you can turn your waterworks from an information sink into an information source.</p> <p>Here is an example of using Hubot to start a Jenkins build: <img src="/assets/chat-ops-jenkins-1.png" alt="Jenkins screenshot" /></p> <p>Please note that in our organization, we have named our Hubot as Synbot.</p> <p>Since this can be a lot of words to type to start a build, we have created a shortcut using the <a href="https://www.npmjs.com/package/hubot-shortcut">hubot-shortcut</a> module. Now the same job can hands be invoked by just typing <code class="highlighter-rouge">!qa</code>: <img src="/assets/chat-ops-jenkins-2.png" alt="Jenkins screenshot" /></p> <p>Now when you see a notification from Jenkins that a job has started, you can read whilom to get a context of what happened and why the build was started: <img src="/assets/chat-ops-jenkins-3.png" alt="Jenkins screenshot" /></p> <p>We have written a <a href="https://github.com/synduit/synbot/blob/master/scripts/jira-agile.coffee">custom Jira plugin</a> that allows you to run commands like this: <img src="/assets/chat-ops-jenkins-4.png" alt="Jenkins screenshot" /> <img src="/assets/chat-ops-jenkins-5.png" alt="Jenkins screenshot" /></p> <p>Apart from this, you can do fun stuff with various plugins for google map and google translate.</p> <p>Hubot is written in NodeJS and CoffeeScript. If you know JavaScript, you can pick up CoffeeScript easily. Also, trammels out npmjs.com for thousands of Hubot plugins that can make your bot smarter.</p> <p>You can find our source lawmaking at: <a href="https://github.com/synduit/synbot">https://github.com/synduit/synbot</a></p> <p>Check out our custom scripts in the <code class="highlighter-rouge">scripts/</code> folder.</p> <p>I gave a talk well-nigh this at Drupal NYC Oct 2015 meetup. You can find the slides <a href="https://docs.google.com/presentation/d/1MnOjraopt3JF3wyYzpQM1EDmBR4P0_e9ayRtUNT0iC4/edit?usp=sharing">here</a>.</p> <p><strong>Cue to 14m29s to see my talk.</strong></p> <iframe width="560" height="315" src="https://www.youtube.com/embed/lwBFukxBZS4" frameborder="0" allowfullscreen=""></iframe>Chat Ops is the practice of running your DevOps from within your yack tool, like IRC or Slack etc.My Internet is down, or is it?2013-05-23T23:32:48+00:002013-05-23T23:32:48+00:00https://msound.tech/2013/05/23/my-internet-is-down<p>I unshut my browser and go to google home page, and it does not open. Does it midpoint my internet is down? Not always.</p> <p>Sometimes your ISP’s gateway works just fine, but their DNS servers are down, making you think that your internet is down. To understand increasingly well-nigh this, let us see what DNS is.</p> <h2 id="domain-name-server">Domain Name Server</h2> <p>In the beginning, when there were only a handful of servers in the whole internet, everyone probably simply remembered the IP write of the server they wanted to access. But over time, it was decided to use the <a href="http://en.wikipedia.org/wiki/Domain_name">Domain name</a> system. Domain name servers (DNS servers) were used to “translate” / “look up” a domain name into an IP address. Once this was implemented, people only had to remember domain names (such as “google.co.in”) instead of remembering IP addresses (such as “74.125.236.183”). It’s kind of like how we have forgotten all our friends phone numbers, and use our phone’s phonebook to “look up” a phone number… or largest still, don’t plane show me the phone number, just dial it already.</p> <p>When you fire up your browser and hit “google.co.in” in the write bar, the first thing the browser does is to perform a DNS lookup to find out what is the IP write for the given domain name. If your ISP’s DNS server is down, then you will not be worldly-wise to see the google home page.</p> <p>To navigate check, unshut a terminal (in Linux) or a writ line window (in Windows), and run the pursuit command:</p> <div class="highlighter-rouge"><pre class="highlight"><code>nslookup google.co.in </code></pre> </div> <p>If you got an error message without a long delay, it ways your DNS is not working. It may moreover midpoint that your gateway moreover is down… but that is not the scenario we are talking about.</p> <p>Let us try to resolve the domain name using a variegated DNS server</p> <p>For Linux users,</p> <div class="highlighter-rouge"><pre class="highlight"><code>nslookup google.co.in - 8.8.8.8 </code></pre> </div> <p>For Windows users,</p> <div class="highlighter-rouge"><pre class="highlight"><code>nslookup google.co.in 8.8.8.8 </code></pre> </div> <p>Google is running a DNS server with the IP write 8.8.8.8 (which is easy to remember). If you see results for this command, then it ways that your internet is just fine, and only your ISP’s DNS is down. (If you still get error messages, then your gateway is probably lanugo – you had largest contact your ISP’s help line.)</p> <p>Now all you need to do is <a href="http://mintywhite.com/windows-7/change-dns-server-windows-7/">change your network settings</a> and manually set the Primary DNS server to 8.8.8.8</p> <p>Once this is done, you might have to restart your browser, and everything should work fine now.</p> <p>Another hint that your DNS server is lanugo is, if Skype works fine, but you are not worldly-wise to scan any website. Skype probably uses IP addresses internally, without using domain names.</p> <h2 id="a-word-of-caution">A word of caution</h2> <p>While we all know that Google is a fantastic company, they are most likely logging all your DNS lookup requests. If you are up to some mischief, and get caught, and if the police request Google for the list of websites you have been visiting, they will requite the list to police. Same applies if you are using your ISP’s DNS servers.</p> <p>To overcome this, you can use OpenDNS’s DNS servers. OpenDNS servers are self-ruling to use, and they are less likely to hand over your browsing history to anyone. The primary DNS server is 208.67.222.222 and the second DNS server is 208.67.220.220</p> <p>Here are the <a href="https://use.opendns.com/">instructions to transpiration your DNS server settings</a> to use OpenDNS.</p> <h2 id="advice-for-the-paranoid">Advice for the paranoid</h2> <p>Even when you use OpenDNS servers, your ISP might still spy on you, simply considering DNS lookups are not encrypted. So, if you are very conscious of your security, you largest read up on DNSSEC and DNSCurve.</p> <h2 id="even-more-paranoid">Even increasingly paranoid?</h2> <p>If you are up to some mischief, or simply do not want your ISP to track which websites you are visiting, you need to get <a href="https://www.torproject.org/">The Onion Router</a>. Simple download the <a href="https://www.torproject.org/download/download-easy.html.en">TOR browser bundle</a>. It works by anonymizing your browsing by sending it virtually the world through various nodes. Hence, this might be slow, but quite secure. Of course, if you use your TOR to trammels your gmail or facebook, then god help you… your anonymity is blown!</p> <h2 id="so-which-dns-server-is-good-for-me">So, which DNS Server is good for me?</h2> <p>It really depends. If you want speed, then you can try pinging various DNS servers and see which one has the least latency.</p> <div class="highlighter-rouge"><pre class="highlight"><code>ping 8.8.8.8 64 bytes from 8.8.8.8: icmp_req=1 ttl=52 time=36.4 ms 64 bytes from 8.8.8.8: icmp_req=2 ttl=52 time=36.0 ms 64 bytes from 8.8.8.8: icmp_req=3 ttl=52 time=35.8 ms 64 bytes from 8.8.8.8: icmp_req=4 ttl=52 time=35.5 ms </code></pre> </div> <p>As you can see, Google’s DNS server is just 36 milliseconds yonder (in my case). However, if you want some anonymity, then go with OpenDNS.</p>I unshut my browser and go to google home page, and it does not open. Does it midpoint my internet is down? Not always.Improving MySQL Insert Performance2013-05-12T20:11:23+00:002013-05-12T20:11:23+00:00https://msound.tech/2013/05/12/improving-mysql-insert-performance<p>Warning: Do NOT do this on a production server!</p> <p>So, my palmtop has been psoriasis when I try to import a database (about 6MB .sql file). It takes well-nigh 20 minutes to run the script.Withoutdoing some reading, I found a way to modernize the speed.</p> <p>The whole thing has to do with the fact that my / partition is running ext4 file system. And ext4 has some default settings that are good for reliability, but not so good for speed.</p> <p>Before I started experimenting with ext4 settings, I wanted to move /var to a new partition so my experiments do not stupefy the unshortened OS.</p> <h2 id="steps-to-move-var-to-a-new-partition-in-ubuntu-1204">Steps to move /var to a new partition in Ubuntu 12.04</h2> <p>Luckily for me, I had some unpartitioned self-ruling space lying virtually in my nonflexible disk. I created a new partition using that self-ruling space, and formatted it as ext4. In your case, you might have to resize an existing partition. Do this carefully, or you might lose your data.</p> <p>In my specimen the new partition was in sda7. So, first I marching into <a href="http://blog.troyastle.com/2010/06/boot-to-single-user-mode-in-ubuntu-1004.html">single user mode</a>.</p> <div class="language-bash highlighter-rouge"><pre class="highlight"><code><span class="c"># mkdir /mnt/newvar</span> <span class="c"># mount /dev/sda7 /mnt/newvar</span> <span class="c"># mv /var/* /mnt/newvar/</span> <span class="c"># vi /etc/fstab</span> </code></pre> </div> <p>Add a line at the end <code class="highlighter-rouge"> /dev/sda7 /var ext4 defaults 0 2 </code></p> <p>I rebooted the machine, and everything came up fine. Still MySQL was taking 20 minutes to import my database. So, next I got virtually to experimenting with ext4 settings.</p> <h2 id="steps-to-improve-ext4-speed-and-reduce-reliability">Steps to modernize ext4 speed (and reduce reliability)</h2> <p>There are three main parameters at play here:</p> <p>The first parameter is <em>access time</em>. There are three possible modes: atime, relatime and noatime. When you segregate atime, everytime a file is accessed, the last accessed timestamp is written to the inode. This means, for every read, there will be a write, and therefore might be reason for slow performance. The noatime option will rationalization the filesystem not to update the last wangle timestamp. Be warned that this might unravel some email applications that rely to last wangle timestamp to see if an email was read or unread. The default option is tabbed “relatime” and is similar to noatime, but updates the wangle time only when the previous wangle time was older than the current modify or transpiration time. This will modernize performance as well as not unravel any email applications. But I wanted to pericope max performance, and since it is my minutiae laptop, and not an email server, I went superiority and chose “noatime”.</p> <p>The second parameter is <em>data</em>. The valid options are journal, ordered and writeback. The default option is ordered, and all data is written to the main filesystem surpassing the metadata is written to the journal. This is the safest thing to do, and in specimen of crash will recover fine. However, to push the performance, I chose “writeback”. In this mode, the data ordering is not preserved. This is somewhat risky if there is a crash or unreticent poweroff. But this is my palmtop and I am feeling lucky. So!</p> <p>The third parameter is <em>barrier</em>. By default ext4 enables write barrier. This forces proper on-disk ordering of periodical commits. Again, it’s a question of reliability vs performance. So, I chose to disable barrier.</p> <p>I edited my /etc/fstab and it now looks like this:</p> <div class="highlighter-rouge"><pre class="highlight"><code>/dev/sda7 /var ext4 noatime,data=writeback,barrier=0 0 2 </code></pre> </div> <p>Also I replaced “/dev/sda7” in my /etc/fstab with the UUID of the device, that I got from running the writ blkid.</p> <p>Doing these steps gave me a huge performance improvment. I am worldly-wise to import my MySQL database in seconds! It’s been a few weeks now and so far I have not had any problems.</p> <p>Be sure to read the <a href="http://linux.die.net/man/8/mount">man page of mount</a>, the documentation of <a href="https://www.kernel.org/doc/Documentation/filesystems/ext4.txt">ext4</a> and Nick’s blog well-nigh <a href="http://blog.smartlogic.io/2009-06-04-rails-development-mount-options-to-improve-ext4-file-system-performance/">improving ext4 filesystem performance</a>.</p>Warning: Do NOT do this on a production server!