Question Hp xeon z400 shutdown suddenly

Jul 28, 2020
So i was playing a game on my pc and suddenly it shuts down and started to give me 4 short beeps with red light, and i thought it was just my RAM so i tested all of my RAMS and nothing was working, then i removed my GPU and then started my computer but this time it was giving me 5 beeps, i tried my old GPU and it was back to 4 beeps, so until this point point it was clear that my motherboard died, but then i tried a few things such as changing the processor, checking the wires and capacitors and everthing was fine until i removed the on board battery for a few minutes and put it back in the pc and then turned the power on, it turned on without me pushing the power button gave one beep and red light then turned off but this time with no power in motherboard, which indicated that this is a power supply error, i am so confused which one is it.

PC Specs

Intel xeon z400 W5580 3.27 GHz (Hp)
RX 570 4GB
16 GB of RAM (4 sticks of 4 GB)
2x500 GB HDD and a 128 GB SSD
Default HP 475 Watt power supply


Without trying known good parts you won't find the flaw. Changing the CPU is not the same as changing the motherboard, and yes it may be the power supply also but no way to know for sure without changing the parts.