How to install libevents on Linux

Dowload the library

tar xzf libevent-2.1.8-stable.tar.gz
cd libevent-2.1.8-stable
./configure --prefix=/opt/libevent # Change path as required
make install

How to get internet access inside Jupyter notebook

Create a file

vi ~/.ipython/profile_default/startup/

Add the following inside it
(Change proxy details as per your own environment)

import sys,os,os.path

# Test

Inside the notebook cell

import requests

Atom editor proxy

To use Atom editor behind proxy , use the below. Restart Atom if needed

apm config set strict-ssl false
apm config set https-proxy

Change proxy as per your requirements

Use Kafka command line with Kerberos

kinit -k -t myprincipal.keytab myprincipal/


/usr/hdp/current/kafka-broker/bin/ \
--zookeeper \
--topic topicname \
--from-beginning \
--security-protocol SASL_PLAINTEXT

Login to Container in Kubernetes

Step 0

Get all pods

kubectl get po --all-namespaces

Find the pod name in which your container is running

Step 1

Get the container name from running pod

kubectl describe po pod_name --namespace my_namespace

Example output

Name: pod_name
Namespace: my_namespace
Node: docker-host-03/
Start Time: Wed, 23 Nov 2016 16:57:15 +1100
Labels: name=my_container_name,pod-template-hash=2802333548
Status: Running

Note the label with value name

Step 2

Login to container


kubectl exec -it pod_name --namespace my_namespace -c my_container_name bash

Why does my LinkedIn inbox always show one unread message ?

Even if I have read all of my Linkedin messages , it still shows one unread message. Strange but true.
I am not sure what is the problem but i can tell how i fixed that.

  1. Click on any message that you have already read.
  2. Mark it as UNREAD
  3. Click on another message that you have already read.
  4. Mark it as UNREAD

See , if you notice any change in unread messages indicator ?

For me it changed correctly and then I read both messages one by one and it made my all messages as Read.

Have great time using Linkedin :)

Websites for learning Regular expressions

Regular expressions are like swiss knife which can do lot of work in small amount of code.

However knowing them deeply is very important to write code which is optimal.

I found below good websites for them while using and learning about them.

A very good website to have visual debugging for Regular expressions

Website to create and test regular expressions

A good website for Regular expressions tutorials