Saturday, April 20, 2013

Root Cause Analysis for dummies: Part 2 - Definition


What is a Root Cause?

The word speaks for itself: the root of the cause. That simple? Yes! 
BTW, I like my another version from the practical point of view: 
A Root Cause is defined as any cause when it is removed, it can eliminate the reoccurrence of an effect. 
What's the root of a tree? There are many components of the tree: leaves, truck, body, bottom part, ROOT: the most bottom part inside the soil. Is it the ROOT the only root cause of a tree? (The answer is NO, below will tell you why.)

Every single problem or an issue is an effect of a cause. If there is a effect, there is a cause.
A cause is the reason behind causing the effect. Cause -> Effect. From now on, the symbol -> will be used to mean causing.  For example, the Cause is no electricity and the Effect is Lamp malfunction. No electricity causing the Lamp malfunction.

No Electricity -> Lamp Malfunction

Cause A -> Effect A

So, in the example, if we remove the Cause A, we can eliminate Effect A. 

For instance, the main switch is turned off causing the lamp malfunction. The cause of the lamp malfunction is the off main switch. According to the definition above: the root cause of the lamp malfunction is the off main switch.

That simple?! Yes! That simple. Do I need to find out who turn off the switch? That may be the root cause. Do I need to find out the reason behind the person turn off the switch? That can be the root cause too, right?

Let me draw the diagram to clarify how to single out this chain of effects and identify the root cause.

Reason behind the person turning off the switch -> The person turn off the switch -> Main switch is off -> Lamp malfunction. 

If you look at above diagram, we can rewrite it like below.

Cause A -> Cause B (Effect of Cause A) -> Cause C (Effect of Cause C) -> final Effect

So, let me ask the same question again. What's the root cause of the final effect?

..... give you 5 minutes to think about it :)

......

......

Answer: Cause A, Cause B, Cause C

What? Why all three are the root causes of the final effect?
The answer is: if removing the cause will removing the final effect. This fit the root case definition.

Cause A: Reason behind the person turning off the switch -> 
Cause B: The person turn off the switch -> 
Cause C: Main switch is off -> 
Final Effect: Lamp malfunction. 

Eliminate Cause C: If we turn the main switch on, the lamp is functional now. The effect is gone.
Eliminate Cause B: If the person did not turn off the switch, the switch is on, the Lamp is functional. Effect gone!
Eliminate Cause A: If the reason behind the person turning off the switch is removed, the person did not turn off the switch. The switch is on and the Lamp is functional now. The effect is gone too.

So, the root cause of an issue is depending how the issue is defined. If you want to solve the issue of Lamp malfunction. You can just turn the main switch to solve this issue. The immedicate cause of lamp malfunction is good enough to resolve the issue.

If you want to resolve the issue to prevent the person turn off the switch, we have to find the reason behind why the person did that.

So, my point is: It is not necessary to dig too deep of a cause unless you want to address deeper issue.
If not, immediate cause is good enough in most cases.

Points to remember:
a. Cause can become an effect if there is a cause creating this cause. 
b. Eliminating a cause to remove an unwanted effect, this very cause is weighty enough to be a ROOT CAUSE.


2. How about I have 2 causes of a effect (issue or problem)?

Cause A: Main Switch is off -> Lamp is malfunction
Cause B: Light Bulb is broken -> Lamp is malfunction

Both Cause A & Cause B cause the lamp malfunction.

To resolve this issue, we can resolve Cause A and Cause B. That is to turn the main switch on and replace the light bulb. 

To be creative, i give you 5 minutes again to find a creative solution yourself that can solve this problem with ONE solution.

..... give you 5 minutes to think about.

......

......

Cause C: No one monitor the main switch and the Light bulb. That's the cause of Cause A & B. 
So, we can resolve this issue by finding the Cause C, exactly speaking to define the cause C and resolve it. 

We can just search what behind the Cause A & B. 

Cause C -> Cause A & B -> Final Effect
Not Monitor Main Switch and Bulb -> Main Switch is off & Bulb is broken -> Lamp malfunction.

In this, Cause A & B, a combined cause can be a root cause of Lamp malfunction.
Or, Cause C can be a root cause of Cause A & B. 

Either eliminating only cause C or eliminating cause A & B will resolve the Lamp malfunction problem.

Points to remember: 
a. An effect could have multiple causes. 
b. The multiple causes can be a root cause.
c. Or the cause behind the multiple causes can be a root cause. 


3. How about a cause has multiple effects?
Main switch is off -> Lamp malfunction and Alarm clock malfunction
Cause A -> Effect A & Effect B

This is similar to the previous cases. The root cause is Cause A. 
Resolving Cause A will eliminate effect A & effect B. 

Points to remember:
a. A cause could have multiple effects.
b. Resolve this cause could resolve multiples issues/problems.

Conclusion:
Isn't it nice and effective using one stone to hunt for two birds?

If you can put the very definition in mind, you would not be afraid to identify the root cause. 
By this, you will get more chance to tacky the issues in your work and your life. 

Hopefully, this can help to remove the hassle of finding a root cause.

Friday, April 19, 2013

Root Cause Analysis for dummies: Part 1 - Introduction

Introduction
The first time I learned Root Cause Analysis (RCA) is from a training class in a chemical company 15 years ago. They put safety in the first of the first priority. Since if there is any major safety incident, the plant manager can be fired or even the whole plant will be closed. For this reason, they introduced Root Cause Analysis to every employee for part of continuous improvement to avoid occurrence of the same incident, big or small.

I picked it up and kept it in my arsenal to use it daily to resolve IT problems. It became my arm and leg just embedding in part of my mind. The merit of this tool is: once the root cause is identified and being resolved. The similar problem or issue will be disappeared forever. 

When surfing the Web, there are a lot of website talking about RCA. Most of them embrace tons of methodologies combining with unnecessary problem solving skills and steps. If I first learned it from them, I'll be intimidated that RCA is belongs to the intellectual or at least a Master degree person could have a grab of it. e.g. http://en.wikipedia.org/wiki/Root_cause_analysisThis is totally untrue.

So, I tried to share my own simple version of Root Cause Analysis. To let all the layman like me, pick it up and become part of themselves. 

Let's go to: Part 2  the definition of Root Cause. 

Pretty much if you define the Root Cause well, in 50% you can identify the root cause right away.

Sunday, April 14, 2013

Google TV - Authentication Error Resolved - Upgraded to Android 3.2

I got a free Google TV in 2010. It was fun to play with. And in 2011, it gave me an upgrade to Android 3.1. It was extremely nice. However, today, when I hooked this Google TV again. It prompts me the Google Talk failed to login error and doesn't allow me to login the Market (now should be Google play).

I tried the some web users suggested two way verification. I got no luck. Even I created another Google account, it still gives me the same error. And because of this authentication error. It doesn't allow the Google TV to upgrade the software to the latest Android software, 3.2 I believe. Simply get me stuck in the middle.

Google for a while, it lands me to this page. http://productforums.google.com/forum/#!topic/mobile/m1l8Sw4hnmY

Below steps work for me. It is in "Manage Application" under "Setting" of Google TV. When I go to Above->System Upgrade again, it shows me the screen to download the latest software (211MB).


da da.... The Google TV is upgraded to Android 3.2 and re-live again. :)


Follow the steps below to if you are experiencing issues with downloading apps from the Android market:

1. Open the Market app and press the home button in the upper left corner to return to homepage
2. Go to Settings \ Applications \ Manage \ Running
3. Press "Market"
4. Press "Clear cache" (do not clear data)
5. Press "Force stop"
6. Return to "Settings \ Applications \ Manage \ Running"
7. Press "Google Services Framework"
8. Press "Clear Data"
9. Press "Force Stop"
10. Go back to home screen and press Market app to Start Google Market, it will give an error message
11. Shut off and turn the tablet back on; once back Market should work, if it gives an error it could need another minute to work
12. At this point the Market should work

Friday, April 12, 2013

Retrieve Linux local mailbox with command lines non-interactively

I need to automate reading email from Linux. So, I google to see if there is any available posted methods to do it in command line non-interactively. Surprisingly, there is no simple scripting method found. The web is either full of how to send email thru command line or how to read email interactively.

So, I dig into mail commands and I did some trials and errors. I discovered "echo" command can enter command to mail thru pipe. And combining with mail command, the command combinations will return the mail command output nicely to Linux stdout after each. Below are 6 handy command combinations.

1. Print all email to stdout
> echo "type *" | mail
> echo "type 1" | mail   # print the first email to stdout
> echo "type 3-5" | mail # print the emails from 3 to 5

2. Check if mail box is empty (i.e. "No mail for [username]" is found)
> echo q | mail 2>&1 | grep "No mail for [username]"

3. Purge the mail box
> echo "d *" | mail

> echo "d 3" | mail     # Delete the 3rd email

4. Save all emails in a text file
> echo "s * test.txt" | mail

5. Save emails between a range in a file
> echo "s 3-6 test.txt" | mail
This will save email from #3 to #6 to the file test.txt

6. Read one email from mailbox
> echo 1 | mail
Read the first mail from mail box
> echo 5 | mail
Read the 5th email from mail box
> echo 6 | mail
If there is no 6th mail from mail box. It will prompt you below error:
6: Invalid message number

The error message "Invalid message number" tells you that there is no 6th email in the mailbox. If the 5th email is successfully returned. You can treat the error message "Invalid message number" as end of mailbox just like the EOF of a file. Combined this with a loop, you can browse thru all the emails inside the mailbox. 

It was fun to dig those command combinations out. Just like resolving puzzles. :)

Monday, February 13, 2012

Set Chrome incognito mode as default in ubuntu Unity



    In Ubuntu 11.10, if you alike me so addicted to Chrome incognito mode, 
    below is the steps how to make it as default under ubuntu Unity 3D:

    1. Modify the file /usr/share/applications/google-chrome.desktop
    e.g. sudo nano google-chrome.desktop

    2. Update the first Exec option as below:
    e.g. Exec=/opt/google/chrome/google-chrome --incognito %U

    3. Save the changes.


    If you would like to set it up in GUI, you can follow the steps in below link:

    http://shuffleos.com/3572/how-to-run-firefox-chrome-in-privacy-mode-automatically-in-ubuntu-11-10/

Thursday, February 9, 2012

Problems and Fixes during cm9 alpha 0.6 touchpad installation



Getting a used touchpad from Amazon and I so want to install ICS for a while since so many praises are there for cm7 and cm9. Last night, I did install cm9 alpha 0.6 on my touchpad and I hit on 4 problems. After a week, I hit on the touchscreen malfunction problem.
  1. ClockWorkMod not shown on Moboot menu
  2. Gapps didn't install
  3. Wifi doesn't work
  4. cm9 can not boot properly because of applying the charging fix to cm9 alpha 0.6
  5. touchscreen malfunction in the lock screen


Here is the details:
1. ClockWorkMod not shown on Moboot menu
The cause is the ClockWorkMod zip file I downloaded is a zero byte file.
So, I redownload it and using the acmeinstaller2 to reinstall it.


For those of you alike me as newbie, here are the steps:-
a. Download it from rootzwiki links there.
b. Transfer the file ACMEInstaller2 thru USB drive in WebOs touchpad boot up
c. Run the command: novacom.exe boot mem:// < ACMEInstaller2 in C:\Program files\Palm, Inc directory. (I'm using PC).


2. Gapps didn't install
Though Gapps zip file was copying to the cminstall directory, it did not install.
The cause is obvious. It requires ClockWorkMod to be functioning before it can be installed.


So, basically, I followed the same steps listed in liliputing website to install charging fix to
install the Gapps. Dada.... the Google Market is up!!!! Here is the details steps.


  1. Place the zip file in the cminstall directory of your TouchPad’s 
  2. Press-and-hold the power button to reboot the touchPad.
  3. From the Moboot menu, choose ClockworkMod.
  4. Use the volume keys to scroll down to the entry that says “install a zip from SDcard” and tap the home button to select.
  5. Using the volume and home keys, highlight the Gapps file and select it.
  6. Scroll down to select yes.
  7. When it’s done installing reboot into CyanogenMod.


3. Wifi doesn't work.
Googling it, it is a known problem most ppl would encounter. There are three ways to fix it.
a. Boot up WebOs on touchpad and turn off and on the Wifi.
b. Remove all files under the wifi directory (/data/misc/wifi )
c. Use fxr wifi fix and rescue


Somehow method a) doesn't work for me. I never tried c) . So, I try method b. Below is the details steps.
1. Run the Terminal app from cm9 touchpad (assume your cm9 is running well now)
2. Run su and confirmed to use su from dialog box
3. Change directory to /data/misc/wifi (i.e. cd /data/misc/wifi)
4. Run the command to delete all file inside the /data/misc/wifi
                 rm -R *
5. Reboot your touchpad
6. Connect to the WIFI with password
Notes: After playing around the whole day. I got reconnect problem too. The wifi is on, but when I connect it. It failed to connect and get IP address. I found pressing the "SCAN" button will resolve the reconnect problem. It works for me once. See if it can resolve the problem next time. 


Update on 2-15-2012 :  FXR Wifi Fix and Rescue works like a charm. I played around the cm9 touchpad for a week. On and off, the wifi will be malfunction again like after the first installation. So, I tried c) method. It works like a charm.


4. cm9 can not boot properly because of applying the charging fix to cm9 alpha 0.6
This one is the most stupid one. As the author in liliputing is already mentioned
that don't install the charging fix if you have cm9 alpha 0.5 or later installed. But I overread it. and install it right away. What a mess to me!!!!


I got the error message "unfortunately, the process com.android.phone has stopped ..." prompting to me continuously while booting up cm9 and this error required me to press ok to close it. After the dialog closed, the error will show it again in less than a seconds. So, this prevents me to do anything even the simple task on the touchhpad to unlock or reboot the touchpad.


Struggling it a while, I manage to fix by reboot your touchpad to moboot menu to use clockworkmod to install the touchpad alpha 6.


The procedure is exactly the same in liliputing for those ppl already installed the cm9 alpha 0.5 and wanting to upgrade it to cm9 alpha 0.6.


Details steps are:
  1. Copy cm9 alpha 0.6 zip file update-cm-9.0.0-RC0-Touchpad-alpha0.6-fullofbugs.zip  and to the cminstall folder on your TouchPad.
  2. Connect your TouchPad to your PC.
  3. Reboot the TouchPad, pressing the volume-up button until the USB icon appears.
  4. Run ACMEInstaller2:  novacom.exe boot mem:// < ACMEInstaller2 in C:\Program files\Palm, Inc directory.
This problem is tough. I almost gave up since I ran out of ideas to reboot the cm9. At the end, YAY, my cm9 touchpad is revived!!!!!


5. touchscreen malfunction in the lock screen (Update on 2-15-2012)
It can be resolve by force reboot: i.e. press and hold the power and home button for 30 seconds. 


Sources:
1. Liliputing cm9 installation instructions:
http://liliputing.com/2012/01/how-to-install-android-4-0-on-the-hp-touchpad-cyanogenmod-9-alpha.html
2. Links to download all the files you needed:
http://rootzwiki.com/topic/15509-releasealpha06-cyanogenmod-9-touchpad/
3. wifi solution c: Forum suggest fxr wifi fix and rescue can fix the wifi issue
http://forum.cyanogenmod.com/topic/41320-cm9-wifi-trouble-tp-sometimes-do-not-really-scans-for-wifi/
4. Wifi solution b: to remove every files from /data/misc/wifi directory (need su priviledge)
http://forum.cyanogenmod.com/topic/41320-cm9-wifi-trouble-tp-sometimes-do-not-really-scans-for-wifi/

Monday, January 11, 2010

0.0.0.0 Default Gateway problem and solution

In case you are unfortunately encountering this same problem and looking for solutions: Here we go:

The problem:
I found my users PC having the below 0.0.0.0 default gateway when using Windows 7.


   Connection-specific DNS Suffix  . :
   Link-local IPv6 Address . . . . . : fe80::356c:2966:d136:bef5%11
   IPv4 Address. . . . . . . . . . . : 192.168.1.144
   Subnet Mask . . . . . . . . . . . : 255.255.255.0
   Default Gateway . . . . . . . . . : 0.0.0.0
                                                 192.168.1.1

When this 0.0.0.0 default gateway appear, my user cannot get into Internet and some Windows network drive were not connected correctly.

The solution:
Found from the net, here is the solutions working for me.


  1. Disable IP v6 (under network adapter properties, check off IP v6)
  2. In command prompt (administrator mode)
C:\> route delete 0.0.0.0
C:\> ipconfig renew

  1. Reboot the PC.
Hope the above works for you too. : )