Install/Migrate DSM 5.2 to 6.0.2

      8 Comments on Install/Migrate DSM 5.2 to 6.0.2

As most of you know by now Jun was able to find a way to install DSM 6 on non Synology boxes. Here is the thread that I recommend reading. At least make an effort and read the OP:

Below is what you need for the operation. I will assume you are doing all this under Windows 10, 8, 7 or XP. If you are on a MAC computer have a look at this post I made on how to burning the image to a USB drive and then mounting the USB drive for editing the content. The rest of the tutorial still applies.

If you are currently using DSM 5.1 or below first update to DSM 5.2. If you are doing a fresh install of DSM 6.0 then carry on with the tutorial and omit references to DSM 5.2.
Win32 Disk Imager to make a bootable USB drive;

– A 4GB (or any size really) USB drive (flash drive) to install the loader. Not that this is necessary but use preferably a brand name (Kingston, SanDisk…);

– A way to read your USB drive VID/PID. Here is a how-to >>> VID and PID;

– A good text editor: Notepad++ I really don’t recommend using Windows’s Notepad;

DSM 6.0.2. The file comes straight from Synology servers;

– Jun’s official v1.01 loader (mirror). This is a hybrid UEFI/BIOS loader so it should work in most machines. Loader supports Intel and AMD CPUs;

Extra.lzma ramdisk. This custom ramdisk is optional but I recommend it. I am just providing it for those who are having issues with network detection or unrecognised HDD controllers. This custom ramdisk contains additional modules (drivers) that were mostly taken from Quicknick’s loader. I don’t warranty they all work but I think most do. You will need to replace (or rename, so you can revert) the default extra.lzma ramdisk from Jun’s loader with this one. See change log at the end of the tutorial for additional modules.
– Make sure your drives are plugged in direct succession starting from the 1st SATA port. Usually the first port is described as SATA0 on motherboards. Check with your MB manufacturer for exact nomenclature.

– OSFMount to modify the grub.cfg file within the loader’s image. This is not strictly necessary as Jun has made it possible to configure what needs to be modified via the Grub Boot Menu. I recommend you use OSFMount for now although it adds an extra step. If you prefer using Jun’s new feature simply skip Point 5, read Note 4 instead and pick up at Point 6.


Use this loader at your own risk. I wont be held responsible for any loss of data or black smokes that may result in the use of this loader. Please note that this loader is based on DSM 6.0 Beta 2 branch 7274 and that a limited amount of drivers are included in the loader. If it is fundamental for you to have a NAS operating as quick as possible I recommend you look at the included drivers first at the bottom of this tutorial. If they are not there you will have to compile your own drivers.
One last thing:
DO NOT UPDATE DSM TO VERSIONS 6.0.3, 6.1 or 6.1.1 with loader v1.01.
You have been warned.
Here we go:

1 – BACKUP your data and save your configuration prior any attempts to migrate from DMS 5.2 to DSM 6.0. I can’t stress this enough. JUST DO IT, as Nike likes to say. Also, print this tutorial if you can. It will make your life easier.

2 – Turn off your NAS and unplug the USB drive you are currently using with DSM 5.2. I recommend you put this USB drive aside in case migration to DSM 6.0 doesn’t go as expected and you need to revert to DSM 5.2. It will just make your life easier.

3 – Now go to your workstation/PC, plug a new USB drive (or the old one if you really don’t have any spare USB drives). Use the link I provided earlier to check your USB drive VID/PID. Write down the info somewhere as we will need it later.

4 – Unzip the loader you downloaded earlier. You will end up with a folder containing several files. Since we are installing on bare-metal you will only need the image file “synoboot.img”.

5 – Now launch OSFMount. Select Mount New, then select the image file (i.e. synoboot.img) to open. Now select partition 0 (the one that is 30 MB). Click Ok. Then at the bottom of the window make sure to un-tick the “Read only drive”. Click Ok. The EFI partition of the image file should now be mounted in file explorer.
At this point you can navigate to the /image/DS3615xs directory and replace the extra.lzma ramdisk with the one provided above. When you are done come back to the root directory and go to the /grub directory and edit the grub.cfg file. Below is what you will see in the file.

I am only showing below the portion of the code that is relevant for the purpose of this tutorial

set extra_initrd="extra.lzma"
set info="info.txt"

set vid=0x058f
set pid=0x6387
set sn=C7LWN09761
set mac1=0011322CA785
set rootdev=/dev/md0
set netif_num=1
set extra_args_3615=''

set common_args_3615='syno_hdd_powerup_seq=0 HddHotplug=0 syno_hw_version=DS3615xs vender_format_version=2 console=ttyS0,115200n8 withefi elevator=elevator quiet'

set sata_args='sata_uid=1 sata_pcislot=5 synoboot_satadom=1 DiskIdxMap=0C SataPortMap=1 SasIdxMap=0'

set default='0'
set timeout='1'
set fallback='1'

:!: You want to modify the following: :!:

Change vid=0x090C to vid=0x[your usb drive vid]
Change pid=0x1000 to pid=0x[your usb drive pid]
Change sn=C7LWN09761 to sn=generate your sn here with DS3615xs model
Change mac1=0011322CA785 to mac1=[your NIC MAC address]. You can also add set mac2=[your NIC MAC address #2] and so on until mac4 if you have multiple NICs. However, this is not necessary.
Optional: Change set timeout=’1′ to set timeout=’4′ – This will allow you more time to make a selection in the Grub Boot Menu when it appears.

Once you are done editing the grub.cfg file, save it and close your text editor. Now in OSFMount click on Dismount all & Exit.

You are now ready to burn the image to your USB drive.

6 – Now use Win32 Disk Imager to burn the image file onto the USB drive. This will also make the USB drive bootable.

7 – Eject and unplug the USB drive from your workstation. Plug it in your NAS (avoid USB 3.0 ports. Use USB 2.0 port if available). Boot your NAS and before doing anything fancy, access your BIOS so to make your USB drive the 1st boot drive if it’s not the case. The loader can boot in UEFI or in legacy BIOS, so you chose what suits you best. Also, make sure your HDDs are booting in AHCI mode and not in IDE, else it wont work. Finally, if disabled, also enable the serial port in BIOS. Some BIOS don’t have this option so don’t get too cranky on this if you can’t find it. Save changes to the BIOS and REBOOT the NAS.

8 – Once rebooted, if you have a monitor connected to your NAS you will see the following Grub Boot Menu:
Zoom in (real dimensions: 717 x 398)Image
If you are on an Intel based machine you can simply let it be and the loader will automatically start. However, if you are on a AMD based machine you will need to select the 4th line and then press enter. ADVICE: even before you see the Grub Boot Menu press the up/down key. This will stop the countdown so you will be able to select the desired line. You won’t see much other than the following after you press enter:
Zoom in (real dimensions: 720 x 400)Image
If you booted the USB drive in EFI mode then you will see the same text without the last 3 lines but that’s ok.

9 – Now go back to your workstation, and launch Synology Assitant or go to Within one minute or so you should normally be able to see your NAS on the local network (it took 55 seconds on a test I did on a VM). Just follow the instructions and either chose “Install” if you wish to have a clean install or chose “Migration” if you are coming from DMS 5.2 and wish to update while retaining your data. You will be asked to provide the .PAT file you downloaded earlier (DSM_DS3615xs_8451.pat).

10 – When the migration is finished you will most probably have to update some of your packages. You can then proceed and update DSM 6.0 up to DSM 6.0.2-8451 update 11. It is possible you might either need to hard reboot or re-image your usb drive. DO NOT UPDATE DSM TO VERSIONS 6.0.3, 6.1 or 6.1.1 with loader v1.01. Make sure to deactivate auto-updates within DSM.

11 – Enjoy. If you have questions or recommendations leave a comment.

Note 1: If after following the tutorial you can’t find your NAS through ou Synology Assistant it is highly possible that the drivers of your NIC are not included in the ramdisk of the loader. In doubt, just ask.

Note 2: Synology increased security in DSM 6.0. Root access through SSH is no longer available out of the box. You can however use your admin account and elevate permissions with the following command

sudo -i

Note 3: Please check you have the right VID/PID prior proceeding. If you get the following error ”Failed to install the file. The file is probably corrupted. (13)” it means your VID and/or PID is wrong. If you are 200% sure that your VID/PID is correct and you still get that error message then try to ‘Force Install’.

Note 4: Changes made to the grub.cfg file can also be done directly during the Grub Boot Menu, so technically you can skip Point 5 and burn the image on the USB drive without editing anything (read Point 6 onward first). If you wish to do the changes from the Grub Boot Menu directly you need to press the letter ‘C’ when you see the Boot Menu. You will literally only have one second, so be fast. Once you press C you will be in a Grub command line environment. To change your VID enter the following:


Do the same for pid, sn and mac1. Press enter at each command. The commands are:


If you have multiple NICs you can also issue mac2, mac3 and mac4 as commands. Maximum is mac4. See below:


If you think you made a mistake in the numbers simply re-issue the command. When you are done press esc and select the appropriate menu entry. Below is an example of how it looks under the Grub command line environment:

Zoom in (real dimensions: 719 x 399)Image

Note 5: If your encounter the “We’ve detected errors on your hard drives [drive number] and the SATA ports have also been disabled” error during installation, try the Force Install menu entry in the Grub Boot Menu. If this does not work then you have to fallback to adding SataPortMap to the grub environment. Press the letter ‘C’ at the Grub Boot Menu and then add the following:

append SataPortMap=XX

where XX is the number of drives. Don’t forget to update this parameter if you add additional drives to your machine.
If you use Force Install, don’t forget to re-select the first line of the Boot Menu once the NAS has rebooted after the installation else the Loader will re-select Force Install and you will be faced with some issues so please beware of this.

What does SataPortMap mean?

SataPortMap=4 means first 4 ports of 1st controler.
SataPortMap=44 means first 4 ports of 1st controler and first 4 ports of 2nd controler.
SataPortMap=422 means first 4 ports of 1st controler, first 2 ports of 2nd controler and first 2 ports of 3rd controler.


######## Know issues #####################
– When running on a slow single core machine, there is a race condition that causes the patcher to load too late. The most obvious sign is that console is not working properly.
– Some ethernet drivers crash when set MTU above about 4096 (Jumbo frame).
– Re-Image your USB stick with the same image if your synology stays in migratable status


Original thread by  Polanskiman

8 thoughts on “Install/Migrate DSM 5.2 to 6.0.2

  1. Bill

    I just bought a new USB stick to do this and there is no VID or PID. It’s only listed as generic. Can I still use this stick if so what do I change the grub.cfg file to?

  2. kenmaster

    When I had simialr problem, I successfully made this with NO STORED DATA LOSS:

    1) Disconnect all the drives
    2) Run the jun’s loader as reinstall
    3) Find device by or Assistant – there were no drives in the system.
    4) Leave browser’s Synology page opened, do not shut down device.
    5) Plug disks back in (no matter, if the machine supports hotswap or not)
    6) After a few minutes repeatedly refresh Synology’s page (see step 4)
    7) After succesfuly loaded installation page reinstall system. Do not forget to check manual upgardes only.

    a) Stored files will be kept untouched, but apps, settings and other data will be removed.
    Settings can be restored via previously saved ones.
    b) If reinstallation crashes, reset your device and go through standard “1st time” instalation process.
    It should go now, because the OS’s partition is formated allready by step 7)

    Note: This is not 100% my own know-how, but I do not remeber its source, sorry.
    I just modified it a bit.

    Note 2:
    Make sure, your HW is OK. I also tested NAS disks separately for their health. After that I tested functionality of HW with two another disks by fresh XPE install.
    Then I used proceeding mentioned above.

  3. Ronny

    I keep getting the Recover button in the Synology Web Assistant after installing the 6.0, whether or not I perform the Recover, it keeps coming back.
    Did anyone have the same issue and how do you solve this?

  4. Pingback: URL

Leave a Reply

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