The invention provides a multi-way valve and a tunnel boring machine. The multi-way valve comprises a main oil inlet, an oil inlet control port, a main oil return port, a main oil drainage port and a plurality of reversing valve groups, wherein the reversing valve groups are used for controlling actuating elements respectively. Each reversing valve group is provided with a pilot-operated reversing valve and an electromagnetic reversing valve. The pilot-operated reversing valve comprises a first oil inlet, a first oil return port and two first working ports, hydraulic oil pumped from the main oil inlet is led into the first oil inlet, and the first working ports are connected with the actuating elements. The electromagnetic reversing valve comprises a second oil inlet, a first oil drainage port and two second working ports, hydraulic oil pumped from the oil inlet control port is led into the second oil inlet, and the second working ports are connected to two ends of the pilot-operated reversing valve to realize reversing thereof. Compared with the prior art, the multi-way valve has the advantages that the requirement to cleanliness of hydraulic oil is low, feedback oil ways are not easy to be blocked, automatic control is easy to realize and the like.