Q:

Hypervalency in elements in the second period

In my experience, most texts that address hypervalency say that it only occurs from elements in the 3rd period and onwards. This explains the occurrence of $\ce{Cl2O7}$ or chlorine heptoxide. However, some 2nd period nonmetals like $\ce{C}$ and $\ce{O}$ show hypervalency.
Examples:

$\ce{CH5}$ - This is unlikely to occur but it does sometimes happen that carbon bonds to 5 atoms instead of 4.
$\ce{H3O+}$ - Here oxygen is hypervalent.

How is it possible for carbon and oxygen to each have 9 electrons if each orbital only holds 2 electrons? Do they switch between electrons or something?

A:

Normally when we talk about a single covalent bond, we are referring to a 2-centre 2-electron bond, which means that there are two electrons holding two atoms together.
Carbon never forms 5 bonds. The only exception that I know of is the $\ce{CH5+}$ methanium cation, the bonding in which can be explained by a 3-centre-2-electron bond. The same kind of bond appears in diborane ($\ce{B2H6}$). In both cases, the octet rule (or duplet rule in the case of the bridging hydrogens in diborane) is not violated. It is just that those 2 electrons are shared amongst 3 different atoms, so each "bond" is effectively half a bond (in MO theory parlance we say that the bond order is 0.5). You could think of it as three of the C-H bonds being normal 2-electron bonds, and two of the C-H bonds being half-bonds (having one electron each). The total number of electrons around carbon is therefore $3 \times 2 + 1 + 1 = 8$.
The neutral species $\ce{CH5}$ does not exist, because it has one more electron than the $\ce{CH5+}$ cation. That would mean that you either have to put 9 electrons around carbon, or put 3 electrons around hydrogen, both of which are of course not allowed.
The hydronium ion $\ce{H3O+}$ is not actually hypervalent. It is similar to the ammonium ion $\ce{NH4+}$ in that a dative bond is formed from the lone pair on O to a $\ce{H+}$ ion.

