Chinese tradition remembers a great flood in the age of the sage kings Yao and Shun, waters so vast they were said to reach the sky and drown the hills. Yao first charged Gun, Yu's father, with controlling it, and Gun tried for nine years using dikes and dams to wall the water back, a method that failed completely and, in the version recorded by the historian Sima Qian, ended with Gun executed or exiled for the failure. Shun then charged Gun's son Yu with the same task.
Yu changed the method entirely. Rather than containing the water, he surveyed the land, cut new channels through mountains, and dredged the riverbeds so the floodwaters could drain to the sea on their own course, a strategy of working with the water's movement instead of opposing it outright. The labor is remembered as taking thirteen years, during which Yu is said to have passed by the gate of his own house three times without going in, once even as he heard his newborn son crying inside, so total was his devotion to finishing the work before turning to his own family.
The flood story is also a founding myth for Chinese geography and administration in the tradition's own telling: as Yu channeled the waters he is credited with surveying and dividing the land into the nine provinces of ancient China, described in the Tribute of Yu chapter of the Book of Documents, so that taming the flood and organizing the realm become a single continuous act of world ordering rather than two separate achievements.