How does the electrical ground rod work? I was reading this article about shock current path, but it seems to be contradicting answers that I have seen on this site regarding electric shock. I can't find the original question but it was asking along the lines of "Why do you get shocked from touching only the live wire?". It was answered that the current travels through your body to ground as there is a potential difference and your body provides a conducting path between the two potentials. We can see this from an illustration in the article.

So the current flows through the body and back to the ground connection which would be the ground rod I think? The article then shows what would happen if the was no ground rod and the live wire was touched.

So from this it seems that if you have a single ground rod no current will flow. So how does the ground connection protect people from faulty appliances such as when a frayed live wire touches a metal casing?
The ground wire is designed to redirect this charge into the ground through the rod but according to this illustration, if you have a single ground connection no current flows. So how does the charge of a faulty appliance get redirected?
 A: The first thing to note is that the supply voltage is relatively small $(100 - 240 \,\rm V)$ compared to the transmitted voltage $(100 \rm s \,kV)$ so that chances of survival after an electric shock are much increased.
The neutral wire is approximately at earth potential whereas the potential of the live wire fluctuated above and below the earth potential.
The earth wire is in position to protect a device which in turn can protect a human.
It does this with the inclusion of a fuse in the  live wire and the earthing of metal parts of the device.
A fault such as the live wire touching the metal case of the device will blow the fuse and hence disconnect the live wire from the device and render it safe.
Your second picture would be equivalent to you touching the live wire with no fuse in the circuit or the  fuse not blowing.
In such a situation you will get a shock but hopefully survive it as the voltages involved and the currents generated by them are relatively low.
If the fault is the live wire touching a metal part of the device which is earthed then you touching the metal part of the device will hopefully produce less of a shock as there is there is now an alternative path ie the current can pass from the device via the earth wire and you which hopefully means less through you
Residual current devices work on a different principle in that they monitor the difference in current between the neutral and the live.
If due to a fault (or you touch the live wire) the difference exceeds a certain value (eg $30\,\rm mA)$ the residual current device trips and disconnects the live wire.
Residual current devices are sometimes preferred to fuse as they are deemed to be safer than fuses by some.
A: The Earth connection (metal stake in the ground, or metal water pipes) is not intended to protect you from faulty appliances. That's what the protective ground wire is for.
It's easy to conflate the Earth connection, with the protective ground and the neutral conductor because they all are bonded to each other at the circuit breaker panel, but each one serves a different purpose.
The neutral conductor normally carries current for the appliance.
The protective ground does not normally carry any current, but it can do if there is a fault. The ground wire is supposed to be connected to any exposed metal part of the appliance. If, because of a wiring fault inside the appliance, the chassis touches the "hot" conductor, then there will be a short-circuit through the protective ground that will trip the circuit breaker, and the chassis will not become "hot." One reason why neutral can't serve that purpose instead is because, it's too easy for hot and neutral to be accidentally switched--inside the appliance, inside the walls of your home, etc. Having a separate, dedicated, color-coded ground wire makes such mistakes less common.
The Earth connection is a bit harder to explain. Power distribution systems rely on transformers, and the output of a transformer normally has no DC connection to the input or to anything else. We say that the output is "isolated." Sometimes, isolation is a good thing: Your second illustration shows a person not being shocked when they touch an isolated power source and Earth at the same time.
Isolation can be a bad thing though when you have long-distance, overhead power lines. Those lines can build up a charge of thousands-to-millions of volts because of atmospheric effects (i.e., the same as what causes lightning in thunderstorms.) That's why power grids are connected to Earth, not just at the distribution panel in your home, but at the generating stations, and at practically every pole or pylon in-between as well. That prevents the voltage on any part of the system relative to Earth from ever being any higher than the nominal voltage for that part of the system.
A: 
So how does the ground connection protect people from faulty appliances such as when a frayed live wire touches a metal casing. The ground wire is designed to redirect this charge into the ground through the rod but according to this illustration, if you have a single ground connection no current flows. So how does the charge of a faulty appliances get redirected?

Well, let's take a look at an example of how this might work in a typical house in the United States. This example shows an installation that has no GFCI.

On the left side of the image, there are two devices. The first device is the 120 V 60 Hz incoming power feed, which has two wires coming out of it: the hot wire (shown in green) and the neutral wire (shown in gray). The second device is the ground rod.
Next is the circuit breaker panel, which contains two important things. On the hot wire, it has a circuit breaker (represented here by a fuse symbol). The other important thing it contains is a connection between the neutral wire (from the incoming power feed) and the ground wire (from the ground rod).
Out of the breaker box comes a cable which contains three wires: the hot wire, the neutral wire, and the ground wire. This cable connects to some kind of household appliance. The hot wire and the neutral wire are both connected to some kind of load (represented here by a resistor), and the ground wire connects to the case of the appliance. There's a complete circuit here, and the circuit has an 8 ohm resistor in it, so only 15 A of current flow, and the circuit breaker does not trip.
Now, what happens if a frayed live wire touches the metal case of that appliance? Then the circuit looks more like this:

Now a new complete circuit has been formed. The circuit starts at the incoming power feed, then goes into the breaker box, through the circuit breaker, out of the breaker box, through the hot wire, into the appliance, through the ground fault, back out of the appliance, through the ground wire, into the breaker box again, through the ground–neutral connection, back out of the breaker box again, and finally back to the incoming power feed.
This new circuit has very little resistance, so a huge amount of current will flow, and the circuit breaker will trip.
Notice that the ground rod doesn't actually play any role in this particular scenario. If the ground rod were missing, exactly the same thing would have happened.
Where the ground rod comes into play is if a hot wire touches, say, a metal fence outdoors. The metal fence probably doesn't have a ground wire attached to it, but the fence is in contact with the earth (the actual soil around the house). The ground rod is also in contact with the earth, and the earth conducts electricity (as long as it's not too dry!), and so a complete circuit is formed that way.
A: The article already explains that the circuit in the second picture is unsafe due to the possibility of ground faults.

So how does the ground connection protect people from faulty
appliances such as when a frayed live wire touches a metal casing.

It seems to me you are actually asking how does a system with a residual-current device (RCD) protect you from getting shocked in such a case. In such a system the picture above would look like this.

The residual current circuit breaker (RCD) forms the sum of all of the currents in the phase line and the neutral line. In a system without a ground fault, the sum is always zero.
If a current now flows back to the power source via an undesired current path, then the sum of all currents in the RCD is no longer zero and the RCD breaks the circuit.
For example in the picture if there is an accidental connection from the phase line to the metal casing of your consumer (red), then a large part of the current will flow through this new path, since the metal casing is connected to the ground. The RCD will break the circuit before a person has a chance to touch the metal casing.
On the other hand, if the person touches the phase line directly (yellow) then the person will still get shocked, but the RCD will limit the time the person is shocked to a few milliseconds, as the RCD will again break the circuit as soon as the missing current is detected. This means it can basically detect if any ground fault occurred somewhere.
A: What you're asking about is exactly the problem with "isolated systems" and why we don't use them much.
It seems clever at first to simply have the "live" and "neutral" wires float with no reference to ground.  I call this situation "First ground-fault is free" (has no consequences), as in your second illustration where the human is the first ground fault.
The problem is, it also blinds us to the first ground fault.  It's free, so we do not realize it is happening.  That equipment has faulted from live to ground, and we don't know.  So when the person also makes a connection between, let's say neutral and ground, they become the second ground fault and it is most definitely lethal to them!
Did you catch the part about neutral being live?  I actually had that happen in a building served by its own transformer.  It was an isolated system by accident; its neutral-ground bond was faulty.  The "first free ground fault" had happened inside a lamp on L1 phase. This pulled L1 to ground, making it neutral.  "The wire formerly known as neutral" was now 120 V to ground, and L2 was 240 V to ground.  All the other insulation held, and everything worked normally.  And I was working on a circuit that I positively definitely turned off at the breaker, flashed L1 to ground with my screwdriver while looking away (up at the light), and surprise! The fluorescent light struck its arc, and turned back on! (not the arc flash I was expecting).  I figure it out PDQ, but holy smoke... I was about to touch "The wire formerly known as neutral"! Good thing I checked.
When isolated systems are used (on purpose lol), it's in facilities with active engineering supervision, where you can get away with a lot of stuff because competent staff is checking for faults at frequent intervals.  As a result, "The first ground fault" gets caught early, and eliminated, before a second ground fault has a chance to happen.
