compressor would not shut off

refrigerator stop working. replace compressor relay plug it in heard a loud noise coming from the top of the fridge. Freezer and fridge work fine but the compressor wouldn’t cycle(off and on). The compressor stays on for too long. When I turned the food side thermostat switch to off, I heard a crackling noise coming from the defroster control board before the fridge turns off. When I turned the thermostat switch back to on, it repeats the same noise as when I turn it to off. Do I have bad thermostat or a bad defroster control board ?