Lu Mai was born in 739, during the reign of Emperor Xuanzong. His territory of origin is variously reported in the official histories as Fanyang or Henan Municipality . He was from "The second house of northern ancestry" of the prominent Lu clan of Fanyang, and he was a distant relative of Lu Han, who served as a chancellor during the reign of Emperor Xuanzong's great-grandson Emperor Dezong. Lu Mai's direct male-line ancestors, for several generations, including his grandfather Lu Keming and father Lu Zhao, served as local officials. Lu Mai was described as filially pious, loving to his siblings, and careful in his youth, and his maternal uncle Cui Youfu, also a chancellor during Emperor Dezong's reign, loved and respected him.
Early career
After Lu Mai passed the imperial examinations, he successively served as a scribe for the crown prince and sheriff of Lantian County. As his written judgments were considered superb, he was then made a secretary at Hunan Municipality. After higher level officials recommended him for his literary talent, he successively served as You Bujue, a low level official at the legislative bureau of government ; Shiyushi, an imperial censor; Xingbu Yuanwailang, a low-level official at the ministry of justice, and Libu Yuanwailang, a low-level official at the ministry of civil service affairs. During a famine caused by a locust infestation, Lu requested an assignment to the Yangtze River region, because at that time his uncle and siblings were all in that region. He was thus made the prefect of Chu Prefecture. He later returned to the capital Chang'an to serve as Simen Langzhong, a supervisorial official at the ministry of justice and then You Jianyi Daifu, an advisor at the legislative bureau. While serving there, he often submitted suggestions to the emperor. He later served as imperial attendant, when he was set to be evaluated for a further evaluation for promotion. He declined, on the basis that he had not served long as jishizhong and therefore should not be considered for yet another promotion at that time. For this, he was much respected by others, and he was later promoted to be Shangshu You Cheng, one of the secretaries general of the executive bureau. While he was serving there, there was an occasion when the minister of palace affairs, Yuan Gen, was supposed to serve as the ceremonial sacrifice leader for sacrifices to Emperor Dezong's deceased wife Empress Wang. Yuan declined on the basis that the sacrifices to Empress Wang were set on a day that one of his parents had died, and the imperial censors submitted an indictment against Yuan for insubordination. A number of officials were convened to discuss the indictment, and Lu pointed out that Yuan's duty should be first to the state, and he should not have declined on the basis of a family matter. Yuan was thus fined.
Chancellorship, resignation, and death
In 793, Lu Mai was given the designationTong Zhongshu Menxia Pingzhangshi, making him a chancellor de facto, serving with Jia Dan, Lu Zhi, and Zhao Jing. As Lu Zhi and Zhao effectively were the lead chancellors, Lu Mai was not much involved in the major decisions, and he was said to be cautious and obedient to the law. He was also praised for personally attending the funeral of a cousin, as at that time, chancellors often considered themselves too important to attend the funerals of distant relatives. In 796, Lu Mai suffered a stroke while at the office of the chancellors, and was taken home in a litter. He offered to resign, but Emperor Dezong declined. As Lu Zhi had by this point been demoted and exiled, Zhao had died, on an occasion when Jia was away observing a memorial for a parent, there was no chancellor on duty, and Emperor Dezong had to send eunuchs to the office of the chancellors to make sure that the affairs of the state were being attended to. Lu Mai subsequently submitted five petitions offering to resign, and in 797, Emperor Dezong approved his resignation and made him Taizi Bingke, an advisor to his crown princeLi Song. Lu died in 798 and was given posthumous honors. As his two marriages did not yield a son, his heir Lu Ji was a son of a cousin.