A nontrivial subgroup of $G$ contained in every other nontrivial subgroup. This question is from a collection of past master's exams.

Let $G$ be a group with a subgroup $H$ as described in the title. I'd like to show that $H$ is in the center of $G$. 

My intuition is to choose some element $x\in H$ (and thus in every nontrivial subgroup $K$ of $G$) and then apply the counting formula; i.e. the order of $G$ is the product of the order of the centralizer of $x$ with that of its conjugacy class. I feel like this, together with the class equation, should tell me everything I need to know. It's been awhile since I've done a problem like this, so any help would be appreciated. 
 A: For each $x \in G$, $C_G(x)$ is nontrivial, hence $H \subseteq C_G (x)$.
Therefore, $H \subseteq \mathop  \cap \limits_{x \in G} C_G (x) = Z(G)$
A: The classification of such groups is simple in two cases:


*

*If G is a finite group, then G has a non-identity subgroup H contained in every non-identity subgroup if and only if G is either non-identity cyclic of prime power order or a (generalized) quaternion 2-group.

*If G is an abelian group, then G has a non-identity subgroup H contained in every non-identity subgroup if and only if G is either non-identity cyclic of prime power order or a Prüfer p-group, $\mathbb{Z}[1/p]/\mathbb{Z}$.
The first is well known (for instance, Gorenstein's Finite Groups textbook, Theorem 5.4.10.ii page 199). The second is also easy: H is by definition essential and clearly has order p for some prime p, so G is contained in a maximal essential extension of H, and all such groups are Prüfer p-groups.
I suspect the classification for general groups is also fairly easy: presumably just the infinite generalized quaternion 2-group. However, I neither proved this nor found a classification.
By the above arguments (in other answers), G is a p-group and H is a central subgroup of order p, and both the finite and abelian subgroups of G are known.
A: Consider an arbitrary element $g\in G$. $g$ induces the cyclic subgroup $C:=\{g^n:n\in\mathbb Z\}$. Since $C$ is nontrivial (unless $g$ is the neutral element), $H$ must, by definition, be a subgroup of $C$. But all elements of $C$ commute with $g$, by construction. Therefore since $H$ is a subgroup of $C$, all elements of $H$ also commute with $g$. But $g$ was chosen arbitrary, thus all elements of $H$ commute with every element of $G$, thus $H$ is a subgroup of the center.
