Samsung SSD 840 EVO 2.5 Zoll SATA – Firmware update under GNU/Linux

I recently bought a Samsung SSD to replace my HDD in my Arch Linux notebook. It is a “Samsung SSD 840 EVO 2.5 Zoll SATA”. One of the first things I do when I get new hardware is to make sure the latest firmware is installed. Mine did not have the latest firmware update and – as it was to expect – Samsung SSD firmware updates under GNU/Linux are not (officially) supported. Samsung ships only Microsoft Windows software, called “Magician”, which can directly update the firmware or create a live USB-Stick to do the update. Additionally, they provide *.iso image files (one for Microsoft Windows systems and one for Apple computer, respectively) to update the firmware from a live CD. The *.iso image file intended for Microsoft Windows would also work under GNU/Linux, only that my notebook does not have a CD Drive anymore. Obvioulsy, the only option left was to create my own live USB-Stick under GNU/Linux – without using Microsoft Windows and that crappy Samsung “Magician” software. A simple “dd” comand to “burn” the *.iso file on an USB-Stick did not do the trick, as the Isolinux version Samsung uses is over 10 years (!) old.

This article shows how to update the firmware of a “Samsung SSD 840 EVO 2.5 Zoll SATA” under GNU/Linux using a bootable live USB-Stick.

WARNING! The following method should work but is not (officially) supported by Samsung. Do at your own risk! You could brick your device or lose all your data on it. Make sure to backup all your data! Also backup all data you have on the USB-Stick used for the firmware update!

You read the WARNING above and are still brave enough to try the firmware update under GNU/Linux? Good, that’s the spirit! However, if you happen to have Mircosoft Windows installed or a CD Drive I would recommend using one of the official methods available.

First, check your firmware vesion. Issue

to find out under which device your SSD registered. To check the firmware version (“FwRev=…”), issue:

Replace “sdX” with your actual device name.

Now go to Samsung’s download website to find the newest firmware available. If you already have the latest version you can stop right here.

Otherwise, download the firmware (Microsoft Windows *.iso image file) and proceed by zero-ing the USB-Stick you wish to use for the update. Find the device name by plugging in your USB-Stick and issue:

The following command will overwrite the first 512 bytes of the USB-Stick with zeros in order to remove any potentially meta-information (MBR, partition table):

WARNING! You will lose all your data stored on the USB-Stick!

Again, replace “sdX” with your actual device name.

Partition the USB-Stick (replace “sdX” with your device name):

Format the USB-Stick(replace “sdX1″ with your device name):

Now, mount the Samsung firmware *.iso file and the newly formatted USB-Stick (replace “sdX1″ with your device name, “SAMSUNGFIRMWARE.iso” with the correct file name and “MOUNTPOINT1″ and “MOUNTPOINT2″ with the actual mountpoints):

The final step of preparation is to install Syslinux and the Samsung firmware update files to the USB-Stick. (Again, replace “sdX” with your device name and “MOUNTPOINT1″ and “MOUNTPOINT2″ with the actual mountpoints.) Note that below source paths for Syslinux are from an Arch Linux installation. These Syslinux source paths might be different, depending on your GNU/Linux distribution. Adjust the paths accordingly or simply use the files and binaries from the Syslinux source package (they can be obtained from here and work without installation). Issue:

WARNING! As mentioned in the warnings obove, you do this on your own risk! Furthermore, if you are using a notebook, make sure that it is on AC! A powerloss during the firmware update would probably be fatal!

Now, do the firmware update using the USB-Stick… (Follow the instructions on the screen.)

If you get a failure message, saying that the update was unsuccessful, do not worry – it should work anyway, as you will see…

When you check the firmware version under GNU/Linux again, by entering (replace “sdX” with your device name):

you should see that the firmware was successfully updated. Arrr, I love it when things work without Microsoft Windows!

 

14 thoughts on “Samsung SSD 840 EVO 2.5 Zoll SATA – Firmware update under GNU/Linux

  1. I just ran across your site while searching for info on updating the firmware in Samsung SSDs in a Linux environment. I just wanted to drop you and the other contributors a note to thank you for posting all of this — it looks like there’s a lot of great stuff here!

    Regards,
    Tony Rein

  2. Hi,

    thank you so much for this How-To! :)

    … I am setting up a server for another person and was about to get crazy because booting from USB did not work at all. Your post solved my problems and I’m now able to do the firmware update :)

    Regards,
    Thomas L.

  3. Hi, I’m trying to update the firmware for my 840 evo from xubuntu 14.04 32bit on eeepc (asus 1201ha) using a usb dongle.
    I tryed writing the iso using unetbootin and this procedure but the result is the same:

    A:\SAMSUNG\DSRD\dsrdgui0.exe
    Out of interrupt stacks!

    Have you any suggestion?

    Thanks a lot

    Pier

    • Hello Pier,

      what do you mean by “using a USB dongle”? A USB-Stick? Are you using an external USB enclosure to connect the SSD to your EEEPC?
      Not all SATA commands are supported with an USB controller in between. If your SSD is connected to the EEEPC over USB, try to attach it directly to the SATA controller (installing it internally). I’m not sure if this is possible with an EEEPC. If not, do the procedure on a different PC.

      Where exactly do you get that error message? You said you get this message while writing the ISO file to the USB-Stick following the procedure in this blog post. This must be a misunerstanding, because no ISO file gets written to a USB-Stick in this blog post. Additionally, the obove error message is no GNU/Linux shell syntax and results from a Microsoft Windows prompt.

      If you need further help, please be more specific.

      • Hi 6arms1leg,
        no, you are wrong or perhaps I didn’t explain very well.
        With usb-dongle I mean that I used an operating system installed on the usb stick following this procedure to update the firmware, I tryed the FreeDOS too ( https://www.content-space.de/dokuwiki/blog/2012/updating_a_samsung_ssd_840_firmware_with_linux#blogtng__comment_form ), and the ssd is installed inside the eeepc, the hd has been replaced with the sdd.
        The error catched is related to the execution of the dsrdgui0.exe program.
        Instead using the FreeDOS procedure the program start correctly but the update fails reporting a mismatch of the firmare.
        I hope to be clear now, if not let me know.

        Sorry for my bad english ;)

        Regards

        Pier

        • Hello Pier,

          OK, I think I got it now: The procedure documented in this blog post works for you (so does the procedure using FreeDOS in the link you posted), but the execution of the Samsung firmware update itself fails, correct?
          If that’s the case, there is not much I can do. There are only a few things that come to my mind:

          - Are you sure you downloaded the correct firmware update from the Samsung website?
          - Your notebook is shipped with Microsoft Windows. I recommend following the official way by Samsung to update the firmware using it’s “Magician” software (there is an option to create a bootable USB-Stick).
          - Your notebook is an older model and probably doesn’t support the SATA 6 Gb/s standard. Although the SATA standards are backward compatible, maybe this is not true for firmware updates. Try doing the firmware update on a different (newer) PC.

          These are just wild guesses. If these don’t fix the problem, I can’t help you. Sorry.

          • Hi 6arms1leg,
            thanks a lot for your answer.
            I think you’re right about the SATA question, yes the eeepc is old enough and has SATA II controller.
            Anyway, I’m very disappointed with samsung, it’s impossible to think to update a firmware there needs a stunt or do somersault!

            Many thanks

            Pier

  4. Hi – Have a query, will be grateful if someone could help me on this? Samsung has released a firmware update & performance restoration of 840 EVO for Linux and Max. http://www.samsung.com/global/business/semiconductor/minisite/SSD/global/html/support/downloads.html The instructions for doing the update using USB bootable is bit confusing to me, as a total noob. For the update, do I need FreeDOS in USB or just extracting the files would suffice? Have you tried this yet on your SSD? Thanks.

    • Hello Anand,

      first of all, I haven’t tried this method. My SSD is already in use and I’m not sure about what magic this “Performance Restoration” tool exactly does (“Never change a running system.” ;-) ). Additionally, my SSD is locked/encrypted (the 840 EVO supports OPAL) and the “Performance Restoration” tool doesn’t work on locked/encrypted drives. So I can only provide you with theoretical assistance.
      If your SSD is also locked/encrypted using the drive’s SED feature, don’t use the tool.

      As with GNU/Linux support from most companies, Samsung’s installation guide is total crap. Same goes for the files they provide: The *.zip file only comtains the tool’s executable and the firmware files – without FreeDos and Syslinux. Only the *.iso file contains FreeDos, (an old) Isolinux and the tool’s executable (at least, that’s what they claim in their installation guide).

      Here is what I would try:

      Follow this blog post (above) and simply replace the *.iso file in the guide with the *.iso file of the “Performance Restoration” tool to create the bootable USB-Stick.
      To run the “Performance Restoration” tool on your SSD, insert the USB-Stick into the target computer, boot it and follow the onscreen instructions (If you have several drives installed, be sure to select the correct drive!). In case the tool isn’t executed automatically, try running

      perf.exe

      on the FreeDOS prompt.
      If the tool still isn’t executed, the executable is probably missing in the *.iso file. In that case, download the *.zip file, extract it on the USB-Stick’s root and try again.

      Also, make sure that booting from USB-Sticks is enabled in the BIOS as first boot option. If you already have UEFI, switch back to legacy BOIS mode for the moment in the UEFI pre-boot graphical environment (don’t forget to undo the change afterwards, or your computer won’t boot).

      Well, these are the necessary steps… at least in theory. I haven’t done this myself, so I can’t help you any further. Tinkering with your SSD’s firmware is dangerous – you do this at your own risk!
      Shame on Samsung for their embarrassing GNU/Linux support!

      Good luck!

  5. Thanks a lot, allowed me to prepare the bootable USB key without any issue, except this line:

    $ sudo cp -v -r –remove-destination /MOUNTPOINT1/isolinux/btdsk.img /MOUNTPOINT2/syslinux/BTDSK.img

    It didn’t work when capitalizeing the name, the following was enough:

    $ sudo cp -v -r –remove-destination /MOUNTPOINT1/isolinux/btdsk.img /MOUNTPOINT2/syslinux/

  6. Soooooo complicated.

    1/ $ isohybrid ./Samsung_Performance_Restoration.iso
    2/ # dd if=./Samsung_Performance_Restoration.iso of=/dev/sdX
    3/ boot
    4/ PROFIT

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">