How large can the smallest generating set of a group $G$ of order $n$ be? Let $n$ be a natural number. For every group $G$ of order $n$, denote 
$d(G)$ : The number of elements of the smallest generating set of $G$

How large is the maximum possible value of $d(G)$ depending on $n$ ?

If $n$ is a cyclic number, we have $d(G)=1$ for every group of order $n$.
For $n=2p$ , $p$ an odd prime, there are two groups : the cyclic group and the dihedral group with $2$ generators, so in this case the maximum value is $2$. 
But I wonder, if the maximal value for $d(G)$ can be determined in general, assuming the factorization of $n$ is known. Is the value known for $n=2048$, for example ? 
 A: By a Theorem of Guralnick and Lucchini (which does require CFSG), if each Sylow subgroup of $G$ (ranging over all primes) can be generated by $r$ or fewer elements, then $G$ can be generated by $r+1$ or fewer elements. As noted in comments, if $G$ has a Sylow $p$-subgroup $P$ of order $p^{a}$, then $P$ can be generated by $a$ or fewer elements (and $a$ are needed if and only if $P$ is elementary Abelian). Hence if $|G|$ has prime factorization $p_{1}^{a_{1}}p_{2}^{a_{2}} \ldots p_{r}^{a_{r}}$ with the $p_{i}$ distinct primes, and the $a_{i}$ positive integers, then $G$ can be generated by $1 + {\rm max}(a_{i})$ or fewer elements. 
(The result attributed to Guralnick and Lucchini was not a joint paper, rather a result proved independently at around the same time: references:
R. Guralnick, "A bound for the number of generators of a finite group, Arch. Math. 53 (1989), 521-523.
A Lucchini: "A bound on the number of generators of a finite group", Arch. Math 53, (1989), 313-317).
A: The general answer (as a function just of $n$, rather than of its factorization into primes) is $\log_2 n$. It is elementary to prove that this number suffices. Just choose $1 \ne g_1,g_2,g_3,\ldots \in G$ with $g_{i+1} \not\in G_{i} := \langle x_1,\ldots,x_i \rangle$, until $G_k=G$. Since each $G_i <G_{i+1}$ for $i<k$, we have $|G_{i+1}/G_i| \ge 2$, so $|G| = |G_k| \ge 2^k$.
But since an elementary abelian $2$-group requires that number of generators, this bound is best possible.
A: For natural $n$, let $d(n)$ be the maximum of $d(G)$ as $G$ runs through all groups of order $n$, and let $\nu(n)$ denote the maximal exponent occurring in the canonical prime factorization of $n$. It follows from answers and comments elsewhere in this thread that
$$
d(n)= \begin{cases}
1+\nu(n) & \text{for } n\in S \\
\nu(n)   & \text{otherwise}
\end{cases}
$$
where $S\subseteq\mathbb{N}$ is a set that we would like to characterize as precisely as possible.
I have now added an entry A332766 in OEIS listing the members of $S = \{ 6, 10, 14, 18, 21, 22, \ldots\}$. Does anyone have any nontrivial contribution to the characterization of $S$?
