Raspberry Pi : setup VNC on the default display

I needed a way to connect the PI to the TV and VNC to that display from my mobile or any device for that matter. Below are the steps I took to accomplish my goal.

cd ~/
– sudo apt-get install x11vnc

mkdir -p .config/autostart
mkdir -p .vnc
if you wish to use a password
x11vnc -storepasswd .vnc/passwd

cd .config/autostart
echo “[Desktop Entry]” > x11vnc.desktop
echo “Encoding=UTF-8” >> x11vnc.desktop
echo “Type=Application” >> x11vnc.desktop
echo “Name=X11VNC” >> x11vnc.desktop
echo “Comment=” >> x11vnc.desktop
echo “Exec=x11vnc -forever -usepw -display :0 -ultrafilexfer” >> x11vnc.desktop
echo “StartupNotify=false” >> x11vnc.desktop
echo “Terminal=false” >> x11vnc.desktop
echo “Hidden=false” >> x11vnc.desktop

This start x11vnc when lxde starts. reboot the system
You can manually run the app ” x11vnc -forever & ”

Linux , Swap Memory usage

running free -m , you notice the system is using swap and you are curious to know which process is using all the memory.
free -m
total used free shared buff/cache available
Mem: 2000 419 783 2 797 1380
Swap: 2047 0 2047

run the below command to see if your system actively using swap
vmstat -S M 1
Found this nice script courtesy of http://blog.theunixguide.com/?p=277

/usr/bin/time -v ls /etc/resolv.conf

grep Swap /proc/[1-9]*/smaps | grep -v ‘\W0 kB’

ps ax | sed "s/^ *//" > /tmp/ps_ax.output
for x in $(grep Swap /proc/[1-9]*/smaps | grep -v '\W0 kB' | tr -s ' ' | cut -d' ' -f-2 | sort -t' ' -k2 -n | tr -d ' ' | tail -10); do
swapusage=$(echo $x | cut -d: -f3)
pid=$(echo $x | cut -d/ -f3)
procname=$(cat /tmp/ps_ax.output | grep ^$pid)
echo "============================"
echo "Process : $procname"
echo "Swap usage: $swapusage kB"; done

Install Kodi on the firestick – easy steps

I have been hearing about people paying 80+ dollars for a firestick amazon-fire-stick exoduswith Kodi installed.  Its pretty sad to over charge someone for a application that is free. So I decided to post the easy instructions here .

  1. You can find the instructions on how to install kodi on the firestick at Kodi Wiki . In a nutshell you will need Jarvis Kodi APK and ABPlink

2.  You will then need to enable developer mode on the stick and obtain the IP address.   Enable developer mode by going to Settings > System > Developer options . Turn on ADB debugging and Apps from unknown sources. Obtain the IP from the same location under <About>
( Note with these instructions you will not need to install ES File Explorer) ES file explorer allows you to install a app from the website. Using ADB , you can push the app to the device over your local network.

3. At the moment the best addon to use is Exodus .

How to Install Addon Installer so you can install Exodus
(Thanks to http://bestforkodi.com/install-exodus-addon-kodi/? for the below )

Open Kodi
Select SYSTEM > File Manager
Select Add Source
Select None
Type the following EXACTLY http://fusion.tvaddons.ag and select Done
Highlight the box underneath type fusion
Select OK
Go back to your Home Screen
Select Add-Ons
Select Install from zip file
Select Fusion
Select start-here
Select plugin.program.addoninstaller-x.x.x.zip
Wait for Add-on enabled notification
Once Addon Installer is on your device or if already on your device then just follow below

Select Addon Installer
Select Featured Add-Ons
Select Exodus
Select Install Exodus
Select Install when asked if you wish to install the add-on and it’s repository
The download of the Exodus add-on and repo will now begin.
Select OK when the success message.

You are now ready to enjoy this superb addon.

There is also another way to Install Exodus Addon Kodi if you don’t want to install addon installer to your device follow easy steps below:

Select System.
Select Add-ons
Select Install from Zip.
Select Fusion.
Select xbmc-repos.
Select English.
Scroll down and select repository.Exodus
Then wait for enabled notification.
Select Get Add-ons.
Select Exodus repo.
Select Video Add-ons.
Select Exodus.
Select Install.

Then wait for Add-on enabled.

Top Addon


Other resources
Firestarter : https://github.com/sphinx02/FireStarter/releases


Daily Rant : In-house Bind9 and dhcp

I was talking with someone about my home lab and the applications I have running in-house.  I mention to them that i have Bind9 running and ISC DHCP.  Their response startled me and I quote “Bind9 is overkill for a house DNS and why not use the router DHCP” .  They then went on to say that Bind9 configuration was hard to understand.

Here is my take on the comment.

Bind9 is not overkill and is used by most companies.  It’s a great way to learn the in and outs of the application by using it in-house and a lab environment.  To say the configuration is hard to understand mean you have not taken the time to understand it. As of this writing you can find Bind9 documentation here

With Regard to DHCP , I ran into a few issues using the DHCP server that come pre-installed on most residential routers.  One main thing was the ability to control the lease time. This was a huge bummer for me because the lease times were 4 hours. This was causing my devices to go offline often during the renewal process. ISC DHCP gave me more control over my environment and the ability to use Vlans.  You can find ISC Documentation here

With that being said, never let someone tell you what you can and can not due.  The sky is the limit when it comes to technology . If you decide to have a full rack in your basement , then go with it.


OPenKB Admin


Samba basic setup

edit /etc/samba/smb.conf

Sample config

comment = FileServer
path = /path/path
browseable = yes
read only = no
guest ok = no

set the workgroup
workgroup =

passdb backend = tdbsam

# “security = user” is always a good idea. This will require a Unix account
# in this server for every user accessing the server. See
# /usr/share/doc/samba-doc/htmldocs/Samba3-HOWTO/ServerType.html
# in the samba-doc package for details.
security = user

SElinux config

setsebool -P samba_export_all_rw 1

setsebool samba_share_fusefs on

Restart samba

systemctl restart smb.service
systemctl restart nmb.service

Allow the connection via the firewall

firewall-cmd –permanent –add-service=samba

firewall-cmd –list-all

Computer , server issues and solutions