(A). A British soldier, as a Jack Tar is a British sailor. The term arose from the little pocket ledgers served out, at one time, to all British soldiers. In these manuals were to be entered the name, the age, the date of enlistment, the length of service, the wounds, the medals, and so on of each individual. The War Office sent with each little book a form for filling it in, and the hypothetical name selected, instead of John Doe and Richard Roe (selected by lawyers), or M. N. (selected by the Church), was “Tommy Atkins.”The books were instantly so called, and it did not require many days to transfer the name from the book to the soldier.
Source: Dictionary of Phrase and Fable, E. Cobham Brewer, 1894