Here is the weekly summary of Technical / Non-Technical topics that I found very resourceful.
Technical:
Performance Check – List of commands to check Utilization, Saturation and Errors(USE method) at different components in a system. – “USE Method: Linux Performance Checklist“
More often than not, full-time Remote work options look great. But just like everything, they have pros and cons. Here are learning from – “A Decade of Remote Work”
[Geeky – Highly Recommended] This blew my mind! Animation of – “507 mechanical movements” ! [ I did study Mechanical Engineering for 4years! 🙂 ]
An extract from a book I am reading :
“In the beginning of your career, you spend time to earn money. Once you hit your stride in any capacity, you should spend money to earn time, as the latter is nonrenewable.”
Here is the weekly summary of Technical / Non-Technical topics that I found very resourceful.
Technical:
Performance Engineering and Tuning is equally important on Client side as it is on server side. Here is a free course on client performance optimization from a Google performance engineer. – “Website Performance Optimization“
I have been Tracking my expenses for 3 years now, and I review them by every month end. I use AndroMoney for tracking. It has both WebClient and AndroidApp. There are 100 other apps out there, but the point is, once you know where your money is going, you can control it.
I came across Kevin Kelly in one of the podcasts. He is movie buff and has a list of great movie recommendations. – “TrueFilm“.
An extract from the book that I am reading:
“It’s very interesting to observe who the top competitors pick out when they’re five rounds into the sparring sessions and they’re completely gassed. The ones who are on the steepest growth curve look for the hardest guy there—the one who might beat them up—while others look for someone they can take a break on.”
Want to do some web-scrapping with Python and need some ideas about the same. – Check the comments!
Non-Technical :
Have you ever had an idea of getting your personal website, but then didn’t spend enough time to make it happen ? Here is another reason to get back to that idea. – “You should have a personal website.“
A study on how much money professionals make across different fields. Study link. Results link. Note: Make sure to use filters for the results.
“A lion is fully capable of capturing, killing, and eating a field mouse. But it turns out that the energy required to do so exceeds the caloric content of the mouse itself. So a lion that spent its day hunting and eating field mice would slowly starve to death. A lion can’t live on field mice. A lion needs antelope. Antelope are big animals. They take more speed and strength to capture and kill, and once killed, they provide a feast for the lion and her pride. A lion can live a long and happy life on a diet of antelope. The distinction is important.”
Performance Engineers go through a set of manual tasks time and again. Be it for creating data for the load test, triggering of the test in a particular sequence / at a particular time or post processing of data collected after the test. The general rule of thumb is – anything that takes more than 10 minutes and has to be done more than two times a week has to be automated. That is a minimum of 1040 minutes saved per year – 2 working days / year per person. To achieve automation, although the world has come to Python & Scala for sophisticated solutions, quick and dirty Shell Scripts will never go out of style. I would not go for sophisticated / complex solutions, if the same can be attained in less than 20-lines of a quick Shell Script.
With that being said, this series of writings on Shell Scripts are basically my notes from different sources which I have collected over the period of time. In this Part-1, let’s look at some basics Shell Scripts. Note: This is not Shell Scripting-101. You might need to know real basics like giving permissions to shell script, how to run shell scripts etc.
User input and Validation
Lets say we are writing a shell script to create test data for Performance load testing. We don’t want to hard-code the environment details in to the script. We want to pass it as input-parameter.
$1 – represents the first input variable passed along with the script at trigger.
script run as ./scriptname.sh <envname> . Example: ./loadGeneration.sh staging
Output: This test will run on staging setup.
#!/bin/bash
environment=$1 echo "This test will run on $environment setup."
If user doesn’t enter environment name with the above script, you would want to stop him and notify him to do so.
if statement below will make sure that the user enters the environment name.
also pay attention to the “exit” in the if loop.
#!/bin/bash
environment=$1
if [[ "$environment" == "" ]]
then
echo "Please enter the environment name"
exit
fi
echo "This test will run on $environment setup."
The above example doesn’t scale if there are many input variables. If along with environment name, if you had to pass user count, test time etc, there will have to be an if condition for every input value check.
Below is a better solution to tackle the same.
#!/bin/bash
environment=${1?Please enter the environment name.}
userCount=${2?Please enter the user load value.}
testTime=${3?Please enter Test Duration.}
echo "This test will run on $environment setup, with a user load of $userCount and for a duration of $testTime minutes."
Above script can be made further more usable like :
#!/bin/bash
usage="Run the script as - ./loadGeneration.sh <envName> <userLoad> <testDurationInMins>"
environment=${1?$usage}
userCount=${2?$usage}
testTime=${3?$usage}
echo "This test will run on $environment setup, with a user load of $userCount and for a duration of $testTime minutes."
We can also have the default values for arguments, like below.
Pay attention the variable – testTime
In the below case even if the third values is not passed while execution, it takes a default value of 60. Example: ./loadGeneration.sh staging 100
#!/bin/bash
usage="Run the script as - ./loadGeneration.sh <envName> <userLoad> <testDurationInMins>"
environment=${1?$usage}
userCount=${2?$usage}
testTime=${3:-60}
echo "This test will run on $environment setup, with a user load of $userCount and for a duration of $testTime minutes."
To output all the input variable sent to the script use – $@
To output the number of variable to a script (count) use – $#
To output the return code use – $?
#!/bin/bash
usage="Run the script as - ./loadGeneration.sh <envName> <userLoad> <testDurationInMins>"
environment=${1?$usage}
userCount=${2?$usage}
testTime=${3:-60}
#this outputs all the input parameters
echo $@
#this output the number of input parameters (count)
echo $#
#to get the return code of a section.
echo $?
Side notes :
Do not leave any space across the = sign while assigning the variables.
Next :
In the Part-2 , we will look in to if-statements, loops and arrays!
Podcast that I enjoyed : First 15minutes of this one form Tim Ferriss – Episode#363. It talks about how to find a mentor and the importance of mentorship.
Building a business of any sort involves adding value to a your customers, who intern become your fans. Here is a great post on how to aim for less and just have – ‘1000 true fans!“
“It’s really how you look at it [bad situations], and the way you look at it is so important. If you can have a positive attitude, look at it, and say, “Let me see, what I can learn from this?” . . . Why would you ever get upset about anything?’”
Recently, I tried to find a place where I could read papers on computer science. I found — “arxiv-sanity” , “sci-hub” & “csrankings.org” very resourceful.
Here is Steve Jobs describing Product Manager role in 1986. Read through the amazing comments as well. — Video-link.
Non-Technical :
With so much information flowing around the web, How to find what is true on internet ? If you could take only one thing out of this article — I would like you to take this! (feel free to jump to 6min 28secs). — “Why your newsfeed is bad!“
I recently started using Brave browser , and it has been a great ad-free and [a little] faster browsing experience ! Here are a weeks stats of using Brave!
An extract from the book I am reading :
“So if you’re planning to do something with your life, if you have a 10-year plan of how to get there, you should ask: Why can’t you do this in 6 months? “
Here is the weekly summary of Technical / Non-Technical topics that I found very resourceful.
Technical:
In Linux, perf command can give you a lot of power for instrumenting the system if you know how to use it. Here is a “not so short” description on how to use it. Note: A post about perf commands is in the pipeline & I will post it shortly ! — “Perf command in linux.”
Bash is more powerful than Black Magic (if that exists!). Here is a 3 part series on some powerful “Bash one-liners.”
I greatly enjoyed the podcast. — “How Seth Godin Manages His Life — Rules.” Note : It is a 123minute long podcast. I consumed it at 2x play speed during an overnight journey. One of the take aways for me — “Most of the people keep playing with the cards they have got instead of moving to a different table with different cards. Don’t get stuck. Move to a different table.“
Have you tried Stoic philosophy ? If not, I highly recommend it for general life wisdom. If a Stoic philosophical book like “Letters from a Stoic” is too much for you, then there is an app — “The Stoic” which will fill you with one Stoic quote a day!
So there was the first image of Blackhole this week. This explains the efforts involved in making Blackhole image a reality. — Youtube link.
An amazing extract from a book that hit me:
“When you are very competitive, you get good at the thing you are competing with people on. But it comes at the expense of losing out on many other things. It is important to understand and accept the consequences.”
We all know the importance of cutting and parsing only required parts of an output in programming. Awk on a whole can do much more than that. Here is – “Why you should learn just a little Awk”
I found this resource on github which is suitable for almost every programmer, System and Network administrators, DevOps, Pentesters and Security Researchers. – “The Book of Secret Knowledge”
Learning is important true, but we forget what we learnif there is no repetition. I use Anki for spaced repetition. Anki works wonders. Reviewing notes multiple times based on the ones you mark Easy, Medium or Difficult. – “Anki”
Quote I’m pondering :
“I don’t give explanations anymore, and I’ll catch myself when I start giving explanations like ‘Oh, I’m sorry, I can’t make it. I have a doctor’s appointment. I’m really sick. I broke my leg over the weekend’ or something. I just say, ‘I can’t do it. I hope everything is well.’ “
The reason I love Linux is, there are tools available for peeking in to the performance of every component. Below cheat sheet lists the set of commands to look in to different components.
For all those who want to take up management roles (Managers) in the future moving away from technical roles, remember, “Moving from dev to manager is NOT A PROMOTION. It’s a CAREER CHANGE.” This resource has interactions with all the people who went through this transition and their take on the transition. “Developer to Manager”
Podcast for weekly brief in to the Python World – “PythonBytes” – weekly one episode of 3o minutes
Non-Technical :
A 5 minute read in to the power of non-expiring information – “Compounding Knowledge“
From Einstein to Mark Twain, most of the great personalities kept a daily journal of some sort. Here is read on importance of journaling – “Benefits of a daily diary and topic journals“
This is an idea that I have been planning to try for quite sometime now. A summary of what happened over the week. A weekly bullet would come out every Saturday and it would cover:
What interesting stuff happened in Tech or Non-Tech world over the week –(Not NEWS)
Extracts from the books that I am reading (somethings which have hit me hard)
Resources Tech/Non-Tech that I might have come across.
I have started learning Scala recently and the following site has been very resourseful in terms of knowing existing/new packages, best practices and news letters. “Awesome Scala”
Non-Technical :
Podcast that I truly enjoyed. This is a 32min short extract from a full episode. If I had only 30mins this entire weekend, I would just listen to this one podcast. Enough said! “Tools of Titans: Derek Sivers Distilled (#202)”
Another one from Derek Sivers. He has a site for all the books that he has recommended with notes/summary/extracts from the books. If you want to pick your next book, dive in here. “Derek Sivers – Books I have read”
Quote I’m pondering :
“Most of the 30year olds are trying to pursue many different directions at once, but not making progress in any. They get frustrated that the world wants them to pick one thing, because they want to do them all. The solution is to think long-term. To realize that you can do one of these things for a few years, and then do another one for a few years, and then another.”