Below is a curated list of system level design articles that link to other Medium.com articles and authors. I’ll revise this list from time to time to include any interesting topics.
Explain Server Monitoring
https://betterprogramming.pub/a-tricky-system-design-interview-question-explain-server-monitoring-c5be0ce54a30Design a URL Shortener
https://eileen-code4fun.medium.com/system-design-interview-url-shortener-cf68ea5db037Design Google Search
https://eileen-code4fun.medium.com/system-design-interview-mini-youtube-5cae5eedceaeDesign Facebook Messenger
https://eileen-code4fun.medium.com/system-design-interview-mini-twitter-1e0e99bd7377Globally Unique ID Generation
https://eileen-code4fun.medium.com/system-design-interview-globally-unique-id-generation-25359500573Replicated and Strongly Consistent Key/Value Store
Personas are the types of users using the system. For an e-commerce system, these user types might be:
Quick Note: Personas could resemble User Roles, but do not resemble permissions on the system. A Persona can be assigned permissions, for example, a Support User might…
*character on the address bar which will open a bookmarks’ search
Go to the address bar and type
* then space then any word in your bookmark, this will now search and auto-suggest based on your bookmarks only.
Shit, shit and shit! I hate to have to remember those commands when setting up my python environment on my MacOS and configuring it to 3.8.5.
So here you go, a cheatsheet to nail it forever!
brew install pyenv
Set the path correctly
$ echo ‘PATH=$(pyenv root)/shims:$PATH’ >> ~/.zshrc
List locally installed versions
$ pyenv versions
List all available python versions from all repositories
pyenv install --list
Install specific version
pyenv install 3.8.5
Again, List locally installed versions
$ pyenv versions
* system (Set by /Users/you/.pyenv/version)
Set python version as global version
pyenv global 3.8.5
There are three major reasons why I would completely avoid installing the PAM Google Authenticator Module from the Apt Ubuntu command which I detail here:
You can check the package compilation date using the command
apt-cache policy libpam-google-authenticator command on Ubuntu:
apt-cache policy libpam-google-authenticatorlibpam-google-authenticator:
500 http://archive.ubuntu.com/ubuntu bionic/universe amd64 Packages
Surprisingly the last update was on 02-JUL-2017 for the apt package while the Github project was last updated on Dec 23rd, 2020. That’s three whole years of lost updates!
The Google Authenticator PAM module package is being published on Ubuntu through the bionic/universe…
AutoRun and AutoPlay are Windows OS enabled features that allow an inserted drive (e.g. USB memory) to run a script upon insertion. This is plain dangerous since an infected drive could lead to a Virus or Malware being installed on your PC.
How Can I Protect My Windows Machine?
Just permanently disable AutoPlay and AutoRun on your Windows machine.
Follow these steps:
Click the MS key, type “AutoPlay” and select AutoPlay Settings, then click the “Off” toggle (see (1) below), then select “Take no action” from the Removable drive select box and “Take no action” from the Memory card select…
This article will describe how to compile Google Authenticator directly from source by cloning the source code from the official GitHub repository.
If you need to know why you should compile and avoid the apt Ubuntu package, please read the previous article first.
Here we go, these steps will be sufficient to git clone it and compile it on your Ubuntu server:
apt install libqrencode-dev -y
apt install libtool -y
apt install libpam-dev -y
apt install autoconf -y
apt install make -y
git clone https://github.com/google/google-authenticator-libpam.git
rm -rf google-authenticator-libpam
apt remove libtool -y
apt remove libpam-dev -y
apt remove autoconf -y
apt remove make -y
In the upcoming articles, I will describe a bullet-proof way to set it up.
Here are the three approaches mostly used for copying a directory on the same host from one folder (or partition) to another.
Suppose we have two folders,
DESTINATION_FOLDER The three approaches for copying are:
cp -R /path/to/SOURCE_FOLDER/* /path/to/DESTINATION_FOLDER/
rsync -a /path/to/SOURCE_FOLDER/ /path/to/DESTINATION_FOLDER
cd /path/to/SOURCE_FOLDER; tar cf - . | (cd /path/to/DESTINATION_FOLDER; tar xvf -)
Copying a 2.5 GB directory on a Windows Subsystem Linux Ubuntu folder:
COMMAND TIME TAKEN
----------------------------------------------------------cp 12.167 seconds
rsync 11.763 seconds
tar 8.125 seconds
tar surprisingly outperforms both
rsync by a huge factor.
tar consumes only ~67% the time
cp takes, and ~69% the time
Hope this helps on your next partition migration.
When someone is asked to configure a PostgreSQL slave replica, the first thing that get’s done usually is “Googling It”, then clicking on the first title that sounds like a good How-To article without paying any attention to the subtle details that could make a huge difference between building a sloppy slave replica and a resilient one.
This recipe focuses on building a resilient setup for a Slave replica of a Master of any size and band-width usage and applies safety margins into the configuration in case a slave lag or conflict gets introduced (arising from any unexpected conditions).
In this article, I will create a partition that fully uses a new block device.
I will avoid the interactive mode while using the
parted command to make it easier to automate this task using a bash (or ansible) script.
A block device is named as
/dev/sda (notice no numbers at the end)
A block device holds one or more partitions. A block device could be formatted and used directly without any partitions, but this is not advised.
Instead one or more partitions should be created inside a block device. A partition name holds the block device name…
A Software Engineer with interests in data storage and database systems done right.