The physical conditions in typical starburst galaxies are investigated through critical infrared (IR) line ratios, as previously suggested by Lutz et al. (1998, A&A, 333, L75). The calculations by a composite model which consistently accounts for the coupled effect of shock and photoionization by hot stars definitely fit the observed line ratios of single objects and explain the observed relation between [OIV]/([NeII]+0.44[NeIII]) and [NeIII]/[NeII]. The shock velocity and the gas density are the critical parameters. Most of the shocks are produced in low density-velocity (n_0 = 100 cm-3 and V_s = 50 - 100 km/s) clouds which represent the bulk of the ionized gas in starburst galaxies. However, though they are by many orders less numerous, high-velocity (= 400 - 600 km/s) shocks in dense (= 500 - 800 cm-3) clouds are necessary to reproduce the critical IR line ratios observed in the low-excitation Starburst Nucleus Galaxies (SBNGs: M82, M83, NGC 253, NGC 3256, NGC 3690, and NGC 4945). These model predictions are in good agreement with the powerful starburst-driven superwinds and highly pressured ISM observed in SBNGs. On the contrary, the high-excitation HII galaxies (II Zw 40 and NGC 5253) do not show any clear signature of large scale outflows of gas. This difference between HII galaxies and SBNGs can be interpreted in terms of temporal evolution of their starbursts.