The Royal Marines were formed as part of the Naval Service in 1755. However, it can trace its origins back as far as 28 October 1664 when at the grounds of the Honourable Artillery Company "the Duke of York and Albanys maritime regiment of foot" was first formed. The Royal Marines served throughout the Napoleonic Wars in every notable naval battle on board the Royal Navy's ships and participated in multiple amphibious actions. Marines had a dual function aboard ships of the Royal Navy in this period; routinely, they ensured the security of the ship's officers and supported their maintenance of discipline in the ship's crew, and in battle, they engaged the enemy's crews, whether firing from positions on their own ship, or fighting in boarding actions. The marines continued in their on-board function after the war, taking a prominent part in the navy's anti-piracy and anti-slavery actions. In 1855 they were newly designated as the Royal Marines Light Infantry, serving in the Crimean war in numerous amphibious raids on Russian forces.