The nineteen-year conflict between King Stephen and Empress Matilda over the English crown had impacts in Worcestershire. Matilda's brother was the Earl of Gloucester, placing Worcester close to one of her most powerful allies. As war broke out in 1138, Stephen attacked Dudley Castle, held by Ralf Pagenal, allied to the Empress. Stephen ravaged the surrounding countryside but could not take the castle. In Easter 1139, Stephen made a royal visit to Worcester and made offerings at the Cathedral. Around this time he also created the Earldom of Worcester, giving the title to Waleran de Beaumont, a close ally. In 1140, Empress Matilda's allies were in Gloucester, while she was under siege in Oxford. Rumours of an imminent attack on Worcester by Matilda's allies drove Worcester's citizens to take refuge in the Cathedral. The attack came in November. Worcester's citizens repulsed the attack at the castle, but houses were burnt, prisoners taken for ransom and livestock stolen. Waleran attacked Sudeley Castle and Tewkesbury in revenge. Miles of Gloucester, the Sheriff, sided with the Empress. He was rewarded with the title of Earl of Hereford. Stephen made the grandson of Urse d'Abitot William de Beauchamp Sheriff in his place. He was put in charge of Worcester's castle in 1145, and Waleran went on a pilgrimage to Palestine. In 1150, Waleran sided with Matilda and defended Worcester against attack by Stephen. Worcester was burnt and plundered, this time by King Stephen, when he took the city. The war came to an end in 1153, with Stephen agreeing that Matilda's heir would succeed him, in return for peace. Henry II restored his authority in the Marches early after his coronation, particularly acting against Roger, Earl of Hereford and Hugh de Mortimer in Shropshire. He visited Worcester and was ceremonially crowned (that is, wore his crown in public) twice in the city. At Easter 1158, one of these occasions, he held a Royal Council at the city. Henry II implemented a number of administrative and legal reforms. He reorganised the English judicial system, implementing circuits, where judges would visit courts in turn. Worcestershire, Shrophsire, Herefordshire and Gloucestershire formed one of these. Henry II's dispute with Thomas Becket reached Worcester as the Bishop Roger attempted to support Becket and the independence of the Church.