Most Samsung smartphones can be restored without losing information by using ODIN and downloading your device firmware from sammobile.com. Symptoms like missing IMEI information or device won't send SMS messages can be fixed with a simple operating system refresh. Sometimes when your device becomes stuck on the Samsung Logo on boot this procedure can also repair this symptom.
1. First we'll download odin from here. Next, visit sammobile and download the firmware that corresponds to your device.
2. Once you have both the appropriate firmware and Odin downloaded start up Odin. On your device most of the Samsung line will go into download mode by pressing these three buttons at the same time - Volume down, home button, and power. Once the device shows the warning screen press volume up as directed to enter "Downloading" mode.
3. You should see Odin detect your device by having a COM port detected. Once you have that, click on the AP or PDA depending on the version of Odin you are using. Go to the directory that holds your firmware downloaded. You may have to extract the zip or rar file to see the firmware file that ends in tar.MD5. Once this file is selected Odin will parse the file, Odin may appear to be not responding but give it a min to finish parsing the file. Once you are able to control Odin again or appears ready, click on Start.
4. Odin will begin to start installing the firmware into your phone. This procedure should work to re-install your current firmware or upgrade to a newer firmware. Be sure you are using the correct firmware as you can brick your device and would require steps beyond this article to repair. Always backup information that you don't want to lose even though this only installs to the SYSTEM partition in the phone if something goes wrong you could lose your data.
5. Once completed the phone will restart. Once restarted it is always good to go into Settings - Storage - and click on Cache to clear any information in cache for a pre-existing installation. This will prevent programs from crashing. The cache can get quite large so it is also ok to go here every month or whenever it starts taking up a lot of room on the device and clear the space.
6. The benefit of restoring in this manner is that you can be assured that the system software is current and not corrupted.
I hope this tutorial helps get your device back up and running again.