Multithreading and Multiprocessing in Python

To begin with, let us clear up some terminlogy: Concurrency is when two or more tasks can start, run, and complete in overlapping time periods. It doesn’t necessarily mean they’ll ever both be running at the same instant. Eg. multitasking on a single-core machine. Parallelism is when two or more tasks are executed simultaneously. A

Temporary failure resolving – sudo apt-get update in ubuntu

If you are trying to update ubuntu respository and getting error: W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-backports/Release.gpg  Temporary failure resolving ‘us.archive.ubuntu.com’ just check the DNS. Set the Google DNS (8.8.8.8) in /etc/resolvconf/resolv.conf.d/base [crayon-5b4f9ab58ffcb283156615/] then [crayon-5b4f9ab58ffda497628018/] After this procedure, I was able to resolve hostnames and [crayon-5b4f9ab58ffe1162092529/]

Kill multiple pid with same process

Sometime back I caught up in a situation where I need to kill multiple pid invoked from same process. So, all process have same name Assume, process invoked for “vim” editor. If I have 20 “vim” process running and I want to kill all of them, what’s the best way to do it? #There are multiple ways:

TCPDUMP examples

Tcpdump is a command-line based packet capture tool like wireshark which is GUI. Capture all traffic on ethernet interface: $tcpdump –i eth0 2. Filter by host IP-address: $tcpdump host 10.0.2.15 3. Filter traffic by source and destination ip-address: TCPDUMP filter by source and destination:             $tcpdump src 10.0.2.15        

CURL command examples

CURL is a command line tool used to transfer and retrieve data in web. Let’s have a look at few of the useful options while debugging web issues. Basic syntax $CURL <Options> <hostname or ip-address> Options are optional. Hostname and IP-address can be interchanged depends upon the options we are selecting. First example is to use

Meet our beloved “Ether” Net

Introduction Most of us take modern day Ethernet for granted. This is probably because it is what many of us have always known. This is especially true if you are like me and got into this crazy business . Today, Ethernet is a globally recognized and widely used standard. It is used in networks all

IP Unnumbered Interface

  The ip unnumbered  configuration command allows you to enable IP processing on a serial interface without assigning it an explicit IP address. Using  ip unnumbered interface, we can “borrow” the IP address of another interface already configured on the router, which conserves network and address space.  In other ways, when serial or any other