Well, to clarify, Libya was already an Italian colony at the beginning of World War II, so Italy didn't need to invade it. You may be thinking of Ethiopia, which Mussolini attacked in 1936. While he was successful at conquering this poor, ill-equipped nation, it demonstrated that his army was no juggernaut.
He fared even worse in Greece, where a massive Italian attack was stopped by a few understrength divisions of the Greek Army. For six months, Mussolini's forces failed to gain the upper hand. He called his friend Hitler, who agreed to help him out by invading both Yugoslavia and Greece in "Operation Punishment". German forces conquered both nations in a mere seven days.
This operation delayed the attack on the Soviet Union by five weeks, which would become crucial the following December, when German troops stalled right outside of Moscow as winter set in. If they had attacked in early May instead, as planned, they likely would have taken the city.