my system shutdown automatically cont an half hour
Try to install a program like HWmonitor (Hardware monitor) to look at your CPU/GPU/etc temperatures. The majority of computers are configured to automatically shutdown/freeze/reboot if the CPU reaches a critical temperature - like 90 or 100 degrees Celsius, for example. It does this to protect the CPU/Computer from being damaged.
If your computer is overheating try to clean out any dust with compressed (canned) air. It's very possible that there is dust clogging your fans and if your fans are clogged there will be no place for the heat that your computer generates to go.
If that doesn't fix it it's possible that the heatsink on your CPU or GPU has become unseated or the thermal interface material (TIM) has dried up. If that's the case, just take the heatsinks off, clean them, then apply new TIM. Arctic silver 5 is a personal favorite of mine but there are better thermal pastes/greases.