Let us consider a routine mechanics problem.A block of $ 10kg $ rests on another block of $ 2kg $ on a frictionless table.Let $ \mu = 0.2 $ be the coefficient of friction(let's neglect the difference between coefficients of static and kinetic friction here)between the surfaces of the two blocks.
A horizontal force of $ 10N $ is applied on the lower block.Now,the maximum force of friction( $F_\mu $)that can be applied on either block by the other surface is equal to $$ F_\mu\,_\max = \mu R $$ where $R$ is the normal contact force between the two blocks.As the blocks don't accelerate vertically, $$ R= 10g \approx 100N $$ Therefore, $$ F_\mu\,_\max = 0.2 \times 100 = 20N $$ The newton's 2nd law for the lower block in the horizontal direction would be $$ 10 - Friction = 2kg \times a_2 $$ and that for the upper block would be $$ Friction = 10kg \times a_1 $$ Clearly,the maximum force of friction is more than the force applied($10N$).So,frictional force will ensure that none of the blocks have any acceleration.
But,if you look at both the blocks as a single system,the only net external force is $F=10N$ and hence the acceleration of the centre of mass of the system is $ a= \frac{10}{10+2} = \frac{5}{6} m/s^2 .$
Since both of the the above results contradict each other,(unless the blocks accelerate in the opposite directions with same magnitudes of acceleration,which is not the case),I assume that its fairly wrong to say that the blocks have zero individual accelerations(with respect to ground).I seriously suspect that the acceleration of either block in my equation is of the frame of reference of the other block,rather than ground;but I fail to see how.I think my question is mostly a confusion in writing newton's 2nd law for different reference frames when friction is involved.