Hey so I had this problem with Xperia M5 that I couldnt update directly from the device, so I installed Xperia Companion and then the phone said "unfortunately, update service has stopped"
The solution is to begin the updating process on the PC and directly when you click next turn off the phone then put it into recovery mode by pressing power + volume down
Hope this helped someone else and also Sony fix your phones