On a newly installed machine, transport bolts and uneven feet can cause severe vibration. In normal use, a very small or overloaded wash can become unbalanced during spin.
A hum that grows with speed can indicate bearings, impacts may indicate dampers or a counterweight, and metal scraping can involve the drum or a trapped object. Do not run the appliance if hand rotation reveals play and rough noise.
You can check a solid level floor, stable feet and even loading. Internal springs, counterweights and cabinet work should be handled by a technician.