Question SX OS convert hidden partition emuNAND to files on SD card emuNAND?

Discussion in 'Switch - Exploits, Custom Firmwares & Soft Mods' started by gizmomelb, Apr 15, 2019.

  1. gizmomelb
    OP

    gizmomelb GBAtemp Advanced Fan

    Member
    6
    Jul 13, 2006
    Australia
    Hi all,

    the main differences with emuNAND with SX OS are the options to create a hidden partition and put the emuNAND in there before the file partition, or of course to create files on the SD card which contain the emuNAND.

    I was wondering if anyone has been able to convert the hidden partition emuNAND to the files version?

    Why? Frankly it'd save me a lot of time copying profiles, save games etc. from my old smaller SD card to my new larger SD card (where I would prefer to have the emuNAND as files - easier to backup and restore if the kids fark something up).

    Thanks in advance.
     
  2. gizmomelb
    OP

    gizmomelb GBAtemp Advanced Fan

    Member
    6
    Jul 13, 2006
    Australia
    alternatively.. can anyone recommend an easy way to transfer profiles and all saves games from the old emuNAND to files, so I can restore on the new SD card?

    I've backed up the games using edizon but haven't installed all the NSPs from the old setup to the new setup or restored the save games yet. That might be a tomorrow job..

    then it's time to figure out how to copy the profiles from the old setup.
     
  3. thaikhoa

    thaikhoa GBAtemp Advanced Maniac

    Member
    8
    Sep 16, 2008
    1. Backup sysnand (boot0, boot1, rawnand)
    2. Fill zero (00) your SD raw data header (important or it won't boot emunand as files on SD)
    3. Extract emunand (boot0, boot1, rawnand) using dd (Mac or Windows)
    4. Restore sysnand using the extracted dumps.
    5. Create emunand as files on SD or Sysnand if you'd like to shrink the size then transfer to SD.
    6. Restore sysnand backup.

    Open HxD as administrator > tools > open disk
    fill 00 following these areas


    2019-04-15_205508.



    You don't need to transfer profiles/ your savedata at all because they're saved on emunand itself. Better to backup your savedata before doing anything.
     
    Last edited by thaikhoa, Apr 15, 2019
    gnilwob and gizmomelb like this.
  4. gizmomelb
    OP

    gizmomelb GBAtemp Advanced Fan

    Member
    6
    Jul 13, 2006
    Australia
    thanks @thaikhoa but I'm not seeing what my sysNAND has to do with it.

    I want to convert my old emuNAND (which is in the hidden partition on a 128GB SD card) to files, then use the files as emuNAND on my new 400GB SD card.

    The easiest solution would be clone my 128GB card to my 400GB card and use the hidden partition, but some people have errors with SX OS 2.6.1 and hidden partition emuNAND - which I'm trying to avoid if possible.


    sysNAND should have no reason at all to be even touched, much less restored.
     
  5. thaikhoa

    thaikhoa GBAtemp Advanced Maniac

    Member
    8
    Sep 16, 2008
    If you don't need to deal with the sysnand, just skip those steps. You have to merge the unallocated partition after restore the clone image of your 128GB but it will affect the hidden partition emunand. I wouldn't recommend you to do that way. Dump the hidden partition emunand first using dd as my post above.


    But you have to restore emunand to sysnand to recreate emuannd as files on SD (SX won't read rawnand.bin as a whole emunand but to split it to full.00.bin etc), that's why I told you to backup sysnand and restore it back on when everything is finished)
     
    Last edited by thaikhoa, Apr 15, 2019
    gizmomelb likes this.
  6. gizmomelb
    OP

    gizmomelb GBAtemp Advanced Fan

    Member
    6
    Jul 13, 2006
    Australia
    ahh I understand (sorry local time is 15 minutes past midnight and I should go to sleep). Will have another look tomorrow.. that would give me the outcome I want but seems a slightly 'dangerous'' way to do it.

    I might try cloning my 128GB to my 400GB first (won't take that long) then upgrade the emuNAND to 7.0.1 and see if I have any problems with the hidden partition that some other people have had.. thanks for your suggestion, my fault for not reading it correctly as I'm tired.
     
    thaikhoa likes this.
  7. The Real Jdbye

    The Real Jdbye Always Remember 30/07/08

    Member
    18
    GBAtemp Patron
    The Real Jdbye is a Patron of GBAtemp and is helping us stay independent!

    Our Patreon
    Mar 17, 2010
    Norway
    Alola
    There is an easy way to migrate your emuNAND, you can either just clone the SD card and extend the partition, or you can use Win32DiskImager to make an image of the card, restore the image to the new card, and extend.
    But I don't recommend using emuNAND as files on SD card because it comes with a much higher risk of corruption (especially if using exFAT), if an error happens or the console loses power while the emuNAND or the other SD files are being written to, you can lose everything on the card (might be recoverable with data recovery programs), if you have emuNAND as a separate partition, you can lose your emuNAND or your SD files (depending on what was being written to) but you won't lose both. Also, emuNAND as files is much easier for Nintendo to detect.
    And you aren't likely to be moving SD cards very often, so there's not much sense in risking corruption just to have emuNAND as files, when the process of moving emuNAND to files is going to be more effort than just cloning the card.
     
  8. thaikhoa

    thaikhoa GBAtemp Advanced Maniac

    Member
    8
    Sep 16, 2008
    I agree you about the chance of corruption when using emunand as files but it won't that easy for Nin to detect the use of emunand because it mainly uses on offline mode with stealth mode enabled. If Nin can detect emunand as files on SD they will detect other files (.nro, .nsp, .xci etc) and/or SD partitions as well. Fortunately, they wouldn't do that because of user rights.

    emunand as files on SD is easy to deal with Hacdiskmount (to open full.00.bin), modify/ backup/restore emunand partitions to sysnand (if applied) in seconds.
     
    Last edited by thaikhoa, Apr 15, 2019
  9. The Real Jdbye

    The Real Jdbye Always Remember 30/07/08

    Member
    18
    GBAtemp Patron
    The Real Jdbye is a Patron of GBAtemp and is helping us stay independent!

    Our Patreon
    Mar 17, 2010
    Norway
    Alola
    I'm not so sure about that. They don't have to read the file contents, just check if a specific file exists, like Niantic has been doing and getting away with in Pokemon Go. And that's true, they could detect other CFW related files just as easily. Who knows if they will.
     
    thaikhoa likes this.
  10. ttierno2

    ttierno2 Newbie

    Newcomer
    1
    Mar 20, 2019
    United States
    Thaikhoa,

    You seem to know what's going on in the world of hidden emunand very well. I don't want to hi-jack the thread, but my question is 'related'.

    I recently updated my Emunand to 7.0.1 (using SX OS 2.6.1) and I'm experiencing the black screen of death where I can't boot into my Emunand now. I am able to boot into OFW and CFW so I just updated that to 7.0.1 and I'm playing away, but I lost many months of game-saves and I hate starting over!! So my question is, can I somehow access my hidden emunand using windows and retrieve those save files somwhow? I'm less after the ability to restore my emunand-state and more-so want to get my save states back. (I was a moron and didn't back up anything--hard lesson learned)

    Any help would be appreciated! Thanks!
     
  11. thaikhoa

    thaikhoa GBAtemp Advanced Maniac

    Member
    8
    Sep 16, 2008
    You need to extract the rawnand from the hidden emunand using dd command line (terminal on macos). Mount rawnand using hacdiskmount then copy all files/folders from USER/save/ to your PC. use save extractor to extract raw savedata from the source.

    Cheers.
     
    ttierno2 likes this.
  12. ttierno2

    ttierno2 Newbie

    Newcomer
    1
    Mar 20, 2019
    United States
    Well, at least your post gives me hope. I’m on Windows, so is there a dd command line equivalent program for that? Also, is the extraction of the rawnand a standard process (as in the commands would be the same for anyone)? Can I find those commands anywhere. I’d really prefer not to mess things up, again....
     
    Last edited by ttierno2, Apr 19, 2019
  13. gizmomelb
    OP

    gizmomelb GBAtemp Advanced Fan

    Member
    6
    Jul 13, 2006
    Australia
  14. xs4all

    xs4all GBAtemp Fan

    Member
    6
    Jun 9, 2008
    Australia
    Before I go on, this reply will be very detailed and I will try to add as much information as possible. I cringe every time I see replies on how to do something and the information provided is half arsed and you have to fill in the missing gaps.

    For those that want to for some reason to convert/migrate your current Hidden EmuNand or SysNand Backup to EmuNand as Files on microSD, this can be done and can confirm it works, I have recently been playing around with this and have successfully managed to do just that.

    Scenarios that I have successfully converted to EmuNand as Files on microSD:
    Current Hidden EmuNand
    SX OS SysNand Backup Method
    Hekate SysNand Backup Method

    With either SX OS or Hekate NAND backup, yes you could just restore the NAND backup and then create EmuNand as files on SD, this method can be long and tedious, I know I wouldn't do it if I realy have to.

    Why would you want to convert your SysNand backup or Hidden EmuNand to EmuNand as Files on microSD you might ask?
    Possible scenarios:

    - Helpful if you want to go back to a previous FW version of EmuNand for whatever reason.
    - If you want to move to a bigger SD CARD and ditch Hidden EmuNand and start using EmuNand as Files on microSD.
    - If you somehow screwed up your Hidden EmuNand partition or SD CARD, you could just create a new Hidden EmuNand but what if your SysNand is on the latest FW but want an earlier FW on EmuNand?
    - What if your currently using Hidden EmuNand but want to move to EmuNand as Files on microSD so it's easier to backup your EmuNand? Yes you can backup Hidden EmuNand with either some cloning app or manually extracting the BOOT0.bin, BOOT1.bin and rawnand.bin files from the Hidden partition. Manual file extraction and restore method for a noob, can be a very daunting. EmuNand as Files on microSD is by far the easiest way to backup your EmuNand for safe keepings.

    There is a debate which is better, Hidden EmuNand or EmuNand as Files on microSD? For me, I prefer Hidden EmuNand because if the SD CARD gets corrupted, in most cases the hidden partition is not affected only the data partition, so you just pretty much reformat the data partition again and your back in business. However all your saves will be gone and also all the NSP's you installed will also be gone so you have to reinstall these again. Yes it's a pain, it's a small trade off but at least you still have your EmuNand.

    Prerequisites for migrating from Hidden EmuNand to EmuNand as Files on microSD:
    You need the follow files extracted from the Hidden EmuNand partition: Minimum of 64GB SD CARD is required, EmuNand takes up about 30GB of space.
    BOOT0.bin
    BOOT1.bin
    rawnand.bin


    Extracting files from your Hidden EmuNand partition:
    You can either use @thaikhoa method above or you can read through the following threads here on GBATemp which has further discussions about the process;
    Moving from SX OS SD-emunand to SD-hidden_emunand

    Below is from an external site which has some good instructions, site is in Spanish however using site translation can get you started.
    [MANUAL] Extract and inject the SXOS emunand from / into a hidden partition

    What you want to do is extract the BOOT0, BOOT1 and rawnand.bin files ONLY.

    Converting SysNand backups to EmuNand as Files on microSD:
    Depending how you backup your NAND files:
    SX OS Nand Backup:
    Regardless if your SD CARD is either FAT32 or exFAT, the SysNand backup files will be split and will be in the CORRECT file format for EmuNand as Files on microSD, no further action is required unless you have joined all the split files to make rawnand.bin. If this is the case you will have to split the files again back to it's original file, format and size, details on how to do this is further below.
    Hekate Nand Backup:
    SD card as FAT32: 14 split files, your required to join the files to create rawnand.bin.
    SD card as exFAT: rawnand.bin.
    BOOT0 rename to: BOOT0.bin
    BOOT1
    rename to: BOOT1.bin

    EmuNand as Files on microSD File/Folder Structure:
    The following files:
    boot0.bin
    boot1.bin
    full.00.bin
    full.01.bin
    full.02.bin
    full.03.bin
    full.04.bin
    full.05.bin
    full.06.bin
    full.07.bin


    In the following folder: SD CARD\sxos\emunand

    How to Split rawnand.bin file to SX OS Compatible EmuNand as Files on microSD:
    You MUST split the rawnand.bin file in 7 parts that SX OS requires (see above), the file MUST be identical in SIZE and DATA, no more, no less!

    I have tried several apps that can split files by entering a curtain file size, the final output files either DID NOT have the exact file size or DID have the exact files size but data was slightly modified. This was evident when I compared both the rawnand.bin and the split files using a HEX editor. I have been using HxD Hex Editor for some time and I just noticed that it has a Split function!

    Open the rawnand.bin file using HxD Hex Editor and go to: Tools => File Tools => Split...
    File to split:
    Should already be populated.
    Base name for partial files (incl. path): Give the output file a name and save location, name can be anything for the time being as you will need to rename them later.
    Naming pattern for partial files: Leave as default Naming Consecutively.
    Size of partial files: Leave as default Custom, change to bytes, enter the following (Very Important): 4294836224
    Then click OK to start splitting the files, once completed, rename the split files to full.00.bin to full.07.bin (See above).
    To make sure the split files are correct, RIGHT CLICK on the file and check the properties:
    The following files should be the following Size: 3.99 GB (4,294,836,224 bytes)
    full.00.bin
    full.01.bin
    full.02.bin
    full.03.bin
    full.04.bin
    full.05.bin
    full.06.bin

    The last file should have the following Size: 1.12 GB (1,204,682,752 bytes)
    full.07.bin


    Congratulations, you now have ALL the files required for EmuNand Files on mirsoSD, if your using SX OS SysNand backup, the files are already EmuNand as File on microSD ready, no further action is required.

    If your migrating from Hidden EmuNand to EmuNand as Files on microSD, MAKE SURE you BACKUP everything on your SD CARD, specially the following folder "SD CARD\Emutendo", as this folder contains all your game saves and installed NSP's.

    There is two ways to go about this, if your migrating, either start fresh and format either in FAT32 or exFAT or use your current SD CARD.

    Not recommended:
    If you want to use your current Hidden EmuNand SD CARD and want to save time, you *could* use some partition tools to delete the first hidden partition and resize the 2nd data partition to take up all the available space on the SD CARD. This saves you from having to backup your files, format the SD CARD and restore files, but there is a high chance that you or the app might mess something up, loosing everything, so make sure you have a BACKUP! of the files on your SD CARD. I have not done this so can't comment if this works or not.

    Recommended:
    Start fresh either use 3rd party partitioning app or windows disk management tool to delete all the partition on the SD CARD, then create a new partition and format your SD CARD to either FAT32 or exFAT.

    All you have to do now is copy ALL of the SPLIT files plus the BOOT0 and BOOT1 files: Make sure the BOOT0/BOOT1 files are from the same SysNAND backup, as different FW have different BOOT0/BOOT1 files.
    boot0.bin
    boot1.bin
    full.00.bin
    full.01.bin
    full.02.bin
    full.03.bin
    full.04.bin
    full.05.bin
    full.06.bin
    full.07.bin

    To your SD CARD\sxos\emunand folder, then proceed to copy back ALL the files you backed up previously.

    To make sure the files above is working as EmuNand Files on microSD, boot into your SX OS boot menu, you should see the EmuNAND enabled option, this tells you that your files are all good and ready to go. If not, double check to make sure the files are in the correct folder.
    If the EmuNAND option is NOT enabled, you did something wrong, go back and double/triple check you have done everyone correctly.
    Added Notes: If your still having issues with EmuNAND after going through the steps, only other thing I can think of is that you may have a bad/corrupted rawnand backup.

    Moving forward, make regular backups of your EmuNand files and if you have the space for it, also backup all the files on your SD CARD. This saves you from having to re install ALL your NSP's again.
     
    Last edited by xs4all, May 9, 2019
    Hero-Link, aarstar, etraxz and 4 others like this.
  15. Dark Ronin

    Dark Ronin GBAtemp Regular

    Member
    4
    Oct 5, 2015
    Russia
    This is a brilliant post. In needs to be added to manuals since here describes the only way to split back your nand for SXOS.
    Thank you Sir, you've made my day.
     
  16. xs4all

    xs4all GBAtemp Fan

    Member
    6
    Jun 9, 2008
    Australia
    Edited my guide to clean it up a little with extra helpful info.
     
    Last edited by xs4all, May 9, 2019
Loading...