Progress of silicon-based technology is nearing its physical limit, as the minimum feature size of components is reaching a mere 10 nm. The resistive switching behavior of transition metal oxides and the associated memristor device is emerging as a competitive technology for next-generation electronics. Significant progress has already been made in the past decade, and devices are beginning to hit the market; however, this progress has mainly been the result of empirical trial and error. Hence, gaining theoretical insight is of the essence. In the present work, we report the striking result of a connection between the resistive switching and shock-wave formation, a classic topic of nonlinear dynamics. We argue that the profile of oxygen vacancies that migrate during the commutation forms a shock wave that propagates through a highly resistive region of the device. We validate the scenario by means of model simulations and experiments in a manganese-oxide-based memristor device, and we extend our theory to the case of binary oxides. The shock-wave scenario brings unprecedented physical insight and enables us to rationalize the process of oxygen-vacancy-driven resistive change with direct implications for a key technological aspect—the commutation speed.