We study thermal processes in infinite harmonic crystals having a unit cell with arbitrary number of particles. Initially particles have zero displacements and random velocities, corresponding to some initial temperature profile. Our main goal is to calculate spatial distribution of kinetic temperatures, corresponding to degrees of freedom of the unit cell, at any moment in time. An approximate expression for the temperatures is derived from solution of lattice dynamics equations. It is shown that the temperatures are represented as a sum of two terms. The first term describes high-frequency oscillations of the temperatures caused by local transition to thermal equilibrium at short times. The second term describes slow changes of the temperature profile caused by ballistic heat transport. It is shown, in particular, that local values of temperatures, corresponding to degrees of freedom of the unit cell, are generally different even if their initial values are equal. Analytical findings are supported by results of numerical solution of lattice dynamics equations for diatomic chain and graphene lattice. Presented theory may serve for description of unsteady ballistic heat transport in real crystals with low concentration of defects. In particular, solution of the problem with sinusoidal temperature profile can be used for proper interpretation of experimental data obtained by the transient thermal grating technique.