of the Royal Military College 2 April 1813, but was compelled by ill-health to leave it in August following. On Napoleon's return from Elba, Shaw joined Wellington's army in Belgium as deputy assistant quartermaster-general of the 3rd or light division, under command of Alten. At Quatre Bras (16 June 1815) his superior officer was disabled during the first ten minutes of the action, and Shaw was left the only officer of the quartermaster-general's staff with the division during that and the succeeding days. On the 17th Shaw reconnoitred the line of march for his division from Pyrmont and the Brye Road, crossing the Dyle at Waye, a movement separate from the rest of the army, and of great delicacy, as it was performed in the presence of the French advance from the field of Ligny (Notes on Waterloo, pp. 17–18). On 18 June Alten's division was posted between the Charleroi Road and La Haye Sainte. Enormous masses of cavalry and artillery having collected in its front, Shaw received Alten's permission to form the division in a novel order of battle, designed to render the transition from line to a formation to resist cavalry as swift as possible. The formation, carried out in the presence of Wellington, consisted of oblongs placed in two lines in exchequer. The oblongs, mostly formed on the two centre companies of battalions, had their faces and flanks four ranks deep; but to preserve the closest affinity to line-formation, each flank had the width of a subdivision only. The division took this formation about 4 P.M., and in it successfully withstood some of the most formidable attacks of cavalry masses on record (ib. pp. 98–102, 114–21). During the day Shaw called the duke's attention to a dangerous gap in the line of battle in rear of La Haye Sainte (ib. pp. 127–9). Shaw had one horse killed and another wounded under him. He received a brevet majority in July 1815. When the army broke up in Paris at the end of the year, Shaw was deputed by the Duke of Wellington to make arrangements with the French government for the retention of Calais. He was stationed at Calais as English commandant and military agent, with the rank of an assistant quartermaster-general, until the final withdrawal of the allies in November 1818. The presence of a French garrison caused many difficulties, which were successfully overcome by Shaw. The emperor of Russia presented him with a diamond ring for his services in embarking the Russian contingent of eight thousand men in October 1818. In 1819 Shaw was promoted to a brevet lieutenant-colonelcy on the special recommendation of Wellington. He had previously been placed on regimental half-pay on 25 March 1817.
In 1820 Shaw married at Ayr Mary Primrose Kennedy, sister, and ultimately heiress of David Kennedy of Kirkmichael, Ayrshire, and granddaughter of Sir John Whiteford, bart. He was appointed in 1826 assistant adjutant-general at Belfast, whence he was transferred later in the year to the northern district of England, and stationed at Manchester, where he remained nine years. He was called upon to provide for the suppression of various threatened outbreaks, due to the discontent of workmen when the laws against ‘combination’ were still existing and enforced, and his services were acknowledged by the home office as well as at the horse guards. On his departure the inhabitants of Manchester presented him with a valuable service of plate. A report, laying down general principles for preserving order during labour disputes, now fully recognised, although novel at the time, was addressed by him to the police commissioners. Sir Charles Napier called it ‘a masterly affair.’ Shaw assumed the additional name of Kennedy on succeeding through his wife to the estates and barony of Kirkmichael. His name first appears in the ‘Army List’ as ‘Shaw Kennedy’ in April 1834. He refused an offer from Sir Robert Peel of the post of first commissioner of the new police, being reluctant to quit his own profession. He accepted the post of inspector-general of the Irish constabulary in 1836. He raised and organised that force, consisting of eight thousand men, and introduced a system of drill and field exercise of his own devising. He held the command for two years, resigning at his own request in 1838, in which year he was made a C.B. He had become a brevet-colonel the year previous. From that time until 1852 he resided chiefly on his estate at Kirkmichael, leading a very retired domesticated life. He became a major-general in 1846, and in 1848 was summoned at short notice to take command at Liverpool during the chartist alarms. Later in the same year he was appointed, together with Lord Hardinge, an extra general officer on the Irish staff under Sir Edward Blakeney [q. v.] Ill-health prevented him from accepting this appointment and the government of Mauritius offered to him without solicitation the year after. In 1852 he accepted the command of the forces in North Britain, but his health becoming worse he had to resign it, and removed to Bath. He became a lieutenant-general and colonel 47th Lancashire foot in 1854, a full general in 1862, and K.C.B. in 1863.
Although an almost incessant sufferer,