The first systematic defence of British ports was carried out by the Romans who built forts at key locations such as Dover and Portsmouth. With the arrival of the Normans in the 11th Century, they further developed many of the old Roman sites and also built new coast defence fortifications. These castle and redoubts were primarily defensive positions to be occupied by infantry. It was however Henry VII who built the first network of defences for harbours, and with the advent of gunpowder, these could be armed with offensive artillery. Many of the coastal defensive fortifications built at the start of the 16th Century, were in many cases, to remain in use until 1945. It was however the Dutch attack on Chatham Dockyard in 1667 that galvanised the drive to protect British Dockyard with fortifications and defence lines. The outbreak of the Napoleonic Wars led to an examination of the existing fortifications at that time such as Portland Castle and Upnor Castle. By and large they were all found to be is a bad state of repair. However between 1795 and 1803 numerous coastal defence batteries were built and fortifications to protect harbours and dockyards. With European peace in 1815, coastal defences again declined sharply in importance.