the Qing because they did not control the entire armies. From the 18th century onwards, the Green Standard Army served primarily as a gendarmerie or constabulary, employed to maintain local law and order and quell small-scale disturbances. It also contributed the bulk of forces dispatched in major campaigns. The Green Standard Army was extremely fragmented, with literally thousands of large and small outposts throughout the empire, many with as few as twelve men. It was divided into garrisons of battalion size, reporting through regional brigade generals to commanders-in-chief () in each province. Governors and governors-general each had a battalion of Green Standard troops under their personal command, but their primary duties lay in the judicial and revenue areas rather than coping with invasion or rebellion. During peacetime, it was rare for one officer to command more than 5,000 men. Strictly speaking, the Green Standard Army was not a hereditary force, although the dynasty directed its recruiting efforts primarily at sons and other relatives of serving soldiers. Enlistment was considered a lifetime occupation, but it was generally very simple to obtain a discharge and be reclassified as a civilian. A system of rotation was used for Green Standard troops in frontier areas. In Kashgaria, troops of the Green Standard from Shaanxi and Gansu had to serve for three-year tours of duty, later increased to five years, then returned home. As early as the White Lotus Rebellion of 1794–1804, the Green Standard armies had begun to exhibit a decline in military effectiveness that rendered them utterly ineffective in combating rebels. At least eight factors contributed to this decline: (1) soldiers' pay did not rise with inflation, requiring most to seek outside employment to support their families; (2) wide dispersion of posts prevented centralized training while the armies' policing and civic responsibilities left little time for drilling; (3) wartime forces were created by taking small numbers of soldiers from numerous existing units rather than using existing units, breaking up unit cohesion and leading to "divisive influence, poor coordination, and operative inefficiency"; (4) vacancies in the armies' ranks were either left unfilled so officers could pocket the missing soldiers' allowances or fill positions with personal proteges; (5) rampant gambling and opium addictions; (6) the practice of allowing soldiers to hire substitutes, often beggars, to train and fight in their place; (7) infrequent drilling; (8) lax discipline due to a lack of respect for inept