In ancient times, many individuals had to learn a series of ways to flourish and thrive in a civilization. Some of which came through trial and error while others came through plain knowledge. In order to keep a civilization maintained and stable, many people had to abide by a ruler or do things on their own. Each civilization had their differences in the ways they went about maintaining their land but they also had some similarities. For example, most civilizations had deities or gods they followed to help with order, different social classes to keep everything in line and a militia for war.
The period of legalism (247-206 BCE) is a great example of how an empire had to follow the laws of their leader. Invading and conquering other civilizations to gain land or outside resources became the thing to abide by to get what you needed. For instance, Ancient Egypt and Nubia went back and forth invading each other because they both had resources that they wanted and because they wanted to expand their land. Also a critical component to establish a strong civilization was to silicify what role each individual had. In particular, a civilization would have its hunters/gathers, priest, slaves, agriculturist, kings and merchants each of which would have to fulfill its own role in order to maintain a well environment.
In all keeping and maintaining a civilization can be viewed as a difficult thing to do. However, if a civilization has all of its key components to flourish then there would not be a problem for them to be stable and survive during ancient times