Perturbation theory in Griffiths In Griffith's (page 222), the perturbed Hamiltonian has been written as

$H + \lambda H'$

Where $\lambda$ is apparently a small number that they will later crank up, and $H'$ is the extra portion of the Hamiltonian. But then they mention that the wave function and energy can be written as follows, where here also $\lambda$ is just a marker.

$\psi_n = \psi^0_n + \lambda\psi^1_n + \lambda^2 \psi^2_n ...$
$E_n = E_n^0 + \lambda E_n^1 + \lambda ^2 E_n^2 ...$

Later the Schrodinger equation is written and multiplied out fully, and the terms with same $\lambda$ coefficients are equated.
What I don't understand is how can one randomly do this? If $\lambda$ is just a marker to keep track of the nth order correction, then why is the same $\lambda$ being used in the Hamiltonian as well?
 A: In this context, $\lambda$ is just a parameter that appears in the Hamiltonian.  Writing
$$H(\lambda) = H_0 + \lambda H'$$
makes it clear that when $\lambda=0$, then $H$ is simply the unperturbed (and easy to handle) Hamiltonian; when $\lambda \neq 0$, then the Hamiltonian has an extra term which may make the problem much more difficult.
Because $\lambda$ appears in the Hamiltonian, it should be pretty obvious that the energy eigenstates $\psi_n$ and the corresponding eigenvalues $E_n$ depend on $\lambda$ as well.  In that sense, we can write $\psi_n(\lambda)$ and $E_n(\lambda)$ as explicit functions of the parameter $\lambda$.
Assuming that $\psi_n$ and $E_n$ are analytic functions of $\lambda$, we can Taylor expand them around $\lambda=0$:
$$\psi_n(\lambda) = \psi_n(0) + \psi'_n(0)\cdot \lambda + \frac{1}{2!} \psi''_n(0) \lambda^2 + \ldots$$
and the same for $E_n$.  Note that $\psi_n(0)$ is simply the eigenfunction of the unperturbed Hamiltonian.  We don't actually know any of those derivatives (because we don't know the function $\psi_n(\lambda)$), so we just give them different names and simply write
$$\psi_n(\lambda) = \psi_n^0 + \lambda \psi_n^1 + \lambda^2 \psi_n^2$$
If $\lambda$ is small, then we can treat the first (unperturbed) term as the dominant one, with the rest being increasingly small corrections.  Throwing out everything of order $\lambda^2$ and higher, the time-independent Schrodinger equation tells us (dropping the subscript $n$ for the moment)
$$(H_0 + \lambda H')(\psi^0 + \lambda \psi^1) = (E^0 + \lambda E^1)(\psi^0 + \lambda \psi^1)$$
Multiplying this out (and discarding the $\lambda^2$ term as before), 
$$H_0\psi^0 + \lambda\big( H_0 \psi^1 + H' \psi^0\big) = E^0\psi^0 + \lambda\big(E^1 \psi^0 + E_0 \psi^1\big)$$
Looking at both sides as functions of $\lambda$, this is morally equivalent to 
$$A + B\lambda = C + D\lambda $$
or
$$(A-C) + (B-D)\lambda = 0$$
If I demand that this is true for every value of $\lambda$ (or at least, in a small neighborhood of $\lambda=0$), then we must have that both $A-C$ and $B-D$ are zero, so $A=C$ and $B=D$.  Applying this to the more complicated looking expression we found above, this means that
$$H_0\psi^0 = E^0 \psi^0$$
and
$$H_0 \psi^1 + H' \psi^0=E^1 \psi^0 + E_0 \psi^1$$
A: My answer is that Griffiths uses the same $\lambda$ throughout his entire analysis. I will focus in my answer on the idea of expanding eigenvectors and eigenfunctions in a power series in $\lambda$ with a worked out example.
The idea is that from the operator equation

$H_{new} = H + \lambda H'$

with some analysis assumptions swept under the rug, it is reasonable to assume that the energy and the eigenvectors corresponding to $H_{new}$ are some nice function of lambda, so we may expand in a series in powers of $\lambda$.
We can determine the coefficients (e.g. $E_n^1$) on the powers of $\lambda$ by either solving the perturbed problem exactly and writing out the expansion, or as Griffiths shows, we can figure out the coefficients by considering clever inner products with the eigenfunctions of the unperturbed Hamiltonian. The latter is the perturbation theory Griffiths shows.

It can be nice to see some examples of this expansion outside of the machinery of perturbation theory, and I believe Griffiths has some examples in coming problems. I will focus on the former expansion of solving a perturbed problem exactly and expanding in a Taylor series in $\lambda$ to show that at least in some nice cases it can be done.
For example, if I have any Hamiltonian and I add a constant potential $\lambda V_0$, then my new energies will be $$E = E_n^0 + \lambda V_0$$ and my wavefunctions will be unchanged. That is, $E_n^1 = V_0$ and $E_n^p = 0$ for $p>1$, while $\psi_n^q = 0$ for $q>0$, which I recommend you verify.

For a more fun example, let's take a harmonic oscillator potential and add some lambda-scaled perturbation to it. Using your notation, let's take our original Hamiltonian as $H = \frac{p^2}{2m} + \frac{1}{2}m \omega ^2 x^2$ and our $H' = \lambda\frac{1}{2}m \omega ^2 x^2$. The original energies are $$E_n^0 = \hbar \omega (n+1/2)$$ and the original wavefunctions are $$\psi_n^0 = \Big(\frac{m \omega}{\pi \hbar}\Big)^{1/4} \frac{1}{\sqrt{2^n n!}} H_n \Big(\sqrt{ \frac{m \omega}{\hbar}}x\Big) e^{-\frac{m \omega}{2 \hbar}x^2},$$ which you can verify from chapter 2. For sanity, let's consider what our perturbation does to the energies for now, and I'll let you expand a wavefunction or two.
Our new Hamiltonian with perturbation included is $H_{new} = \frac{p^2}{2m} + \frac{1}{2}m \omega ^2 x^2 (1+\lambda)$. You can verify that this is the same as taking $\omega \rightarrow \omega\sqrt{1+\lambda}$ in the exactly solved Hamiltonian above. This means we can solve the eigenenergies and eigenvectors of this Hamiltonian exactly by substituting $\omega \rightarrow \omega\sqrt{1+\lambda}$.
Then we have for our exact energies for the new Hamiltonian that $$E_n = \hbar \omega\sqrt{1+\lambda} (n+1/2).$$ Then we see that we can Taylor expand $E_n$ in powers in $\lambda$. For example, we see that for small $\lambda$ $$E_n = \hbar \omega(n+1/2)+ \hbar \omega (n+1/2)(1/2)\lambda-\hbar \omega(n+1/2)(1/8)\lambda^2+...$$
From this, we have in your notation that

$E_n^0 = \hbar \omega (n+1/2)$
$E_n^1 = 1/2 \hbar \omega (n+1/2)$
$E_n^2 = -1/8 \hbar \omega (n+1/2)$

and so on. Thus we have figured out our expansion coefficients by Taylor-expanding in $\lambda$.

In this perturbation theory section in Griffiths, you are seeing an alternative way of finding the expansion coefficients where you do not need to solve the Hamiltonian exactly. Instead, you can relate the coefficients to inner products involving the perturbing Hamiltonian and the eigenvectors of the unperturbed Hamiltonian. If you request, I will update my answer to show how one may use perturbation theory to find the exact same coeffients $E_n^1$ and $E_n^2$ above. I think that may be a problem in Griffiths, so I recommend you try that one out.
