Shoganai is (essentially) a philosophy. It says that if something is out of your control it's better to quickly accept it and move on.
Shoganai explains why Japanese people can deal with terrible situations such as disasters without complaining. It also explains how Japan recovered so quickly from WWII after many of it's cities had been completely destroyed.
Some argue that shoganai can have a negative effect too. For example, many Japanese people disagreed with Japan's actions during WWII but didn't speak up. Extreme right wing nationalist elements in the country seemed too powerful to fight (shoganai).
In recent times, shoganai is often used to explain why many Japanese are unhappy with government policy but don't bother to vote.