It can be a kind of water hammer. Fresh water carries about 5 percent air. Even though it is not large, visible bubbles, it is there. When water comes into a heater, the heat makes the bubbles larger and they settle out to the top of the water. The bubbles collect at (float to) high parts of a system. When you turn the hot water on, the pressure forces air bubbles and water through the pipe - making the vibration (sound) you hear. A slug of water following an air bubble is a hard object - water is 'soft' in that it can flow, but 'hard' in that it can hit like a rock at high speed - that is water hammer. It is something a hot water heating repairman must know.