A hydraulic cylinder, comprising: a cylinder body; a first piston disposed in the cylinder body and movable along an axial direction of the cylinder body; a piston rod with one end connected on the first piston and extending along the axial direction of the cylinder body; wherein the cylinder body has a first cavity for introducing and discharging hydraulic fluid, the first cavity is positioned on one side of the first piston facing away from the piston rod; wherein the piston rod has a second cavity extending along the axial direction of the cylinder body, the hydraulic cylinder further comprises a second piston, the second cavity is movable relative to the second piston, the second piston is fixed relative to the cylinder body; the second cavity comprises an accommodating cavity positioned on one side of the second piston facing the first piston, the accommodating cavity is configured to discharge the hydraulic fluid when the first cavity is supplied with hydraulic fluid, and the accommodating cavity is configured for being supplied with hydraulic fluid when the first cavity discharges the hydraulic fluid, an air vent communicating with the atmosphere is formed in the second cavity which is positioned at the part of the second piston facing away from the first piston; the cylinder body has a third cavity for introducing and discharging hydraulic fluid, the third cavity is formed between the piston rod and the cylinder body and communicated with the accommodating cavity; and the first cavity is configured to discharge the fluid when the third cavity is supplied with hydraulic fluid to push the piston rod to retract into the cylinder body, and the third cavity is configured to discharge the hydraulic fluid when the first cavity is supplied with hydraulic fluid to push the piston rod to extend out of the cylinder body, wherein the hydraulic cylinder further comprises a connecting unit for fixing the second piston with respect to the cylinder body, wherein the connecting unit is connected with the second piston and extends to the first piston, a through hole is formed in the first piston to allow the connecting unit to pass through, and the connecting unit passes through the through hole and is connected with the cavity wall of the first cavity, characterized in that the connecting unit comprises a tubular piece, one end of the tubular piece adjacent to the second piston is communicated with the accommodating cavity, one end of the tubular piece away from the second piston is for inputting the hydraulic fluid into the accommodating cavity and discharging the hydraulic fluid in the accommodating cavity. a cylinder body; a first piston disposed in the cylinder body and movable along an axial direction of the cylinder body; a piston rod with one end connected on the first piston and extending along the axial direction of the cylinder body; wherein the cylinder body has a first cavity for introducing and discharging hydraulic fluid, the first cavity is positioned on one side of the first piston facing away from the piston rod; wherein the piston rod has a second cavity extending along the axial direction of the cylinder body, the hydraulic cylinder further comprises a second piston, the second cavity is movable relative to the second piston, the second piston is fixed relative to the cylinder body; the second cavity comprises an accommodating cavity positioned on one side of the second piston facing the first piston, the accommodating cavity is configured to discharge the hydraulic fluid when the first cavity is supplied with hydraulic fluid, and the accommodating cavity is configured for being supplied with hydraulic fluid when the first cavity discharges the hydraulic fluid, an air vent communicating with the atmosphere is formed in the second cavity which is positioned at the part of the second piston facing away from the first piston; the cylinder body has a third cavity for introducing and discharging hydraulic fluid, the third cavity is formed between the piston rod and the cylinder body and communicated with the accommodating cavity; and the first cavity is configured to discharge the fluid when the third cavity is supplied with hydraulic fluid to push the piston rod to retract into the cylinder body, and the third cavity is configured to discharge the hydraulic fluid when the first cavity is supplied with hydraulic fluid to push the piston rod to extend out of the cylinder body, wherein the hydraulic cylinder further comprises a connecting unit for fixing the second piston with respect to the cylinder body, wherein the connecting unit is connected with the second piston and extends to the first piston, a through hole is formed in the first piston to allow the connecting unit to pass through, and the connecting unit passes through the through hole and is connected with the cavity wall of the first cavity, characterized in that the connecting unit comprises a tubular piece, one end of the tubular piece adjacent to the second piston is communicated with the accommodating cavity, one end of the tubular piece away from the second piston is for inputting the hydraulic fluid into the accommodating cavity and discharging the hydraulic fluid in the accommodating cavity.