New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a way to check the NAND for issues and fix them #6096

Merged
merged 4 commits into from Oct 11, 2017

Conversation

5 participants
@leoetlino
Member

leoetlino commented Oct 3, 2017

Old versions of Dolphin are so broken regarding NAND handling that
we need this to repair common issues and avoid issues with titles
like the System Menu or the Wii Shop.

This isn't an exhaustive check, but this will catch most issues
and offer to fix them automatically (if possible).

@BhaaLseN

Untested, but LGTM in general. I suppose the first commit is shared with #6094?

Show outdated Hide outdated Source/Core/Core/WiiUtils.cpp
@@ -473,6 +474,7 @@ void MenuBar::UpdateToolsMenu(bool emulation_started)
m_pal_ipl->setEnabled(!emulation_started &&
File::Exists(SConfig::GetInstance().GetBootROMPath(EUR_DIR)));
m_import_backup->setEnabled(!emulation_started);
m_check_nand->setEnabled(!emulation_started);

This comment has been minimized.

@BhaaLseN

BhaaLseN Oct 4, 2017

Member

Does this make sense when there is no NAND at all? But then again, this probably goes for the other menu items there too (like extract certificates etc.)

@BhaaLseN

BhaaLseN Oct 4, 2017

Member

Does this make sense when there is no NAND at all? But then again, this probably goes for the other menu items there too (like extract certificates etc.)

This comment has been minimized.

@leoetlino

leoetlino Oct 4, 2017

Member

In my opinion, yes. Users that only use games can still end up corrupting the NAND (thanks to Dolphin :P), and the NAND stays broken even after making it more complete (by installing system titles).

@leoetlino

leoetlino Oct 4, 2017

Member

In my opinion, yes. Users that only use games can still end up corrupting the NAND (thanks to Dolphin :P), and the NAND stays broken even after making it more complete (by installing system titles).

@JMC47

This comment has been minimized.

Show comment
Hide comment
@JMC47

JMC47 Oct 5, 2017

Contributor

What does it actually try to repair? I haven't gotten it to fix any of my NANDs yet, and it doesn't say why.

Contributor

JMC47 commented Oct 5, 2017

What does it actually try to repair? I haven't gotten it to fix any of my NANDs yet, and it doesn't say why.

@leoetlino

This comment has been minimized.

Show comment
Hide comment
@leoetlino

leoetlino Oct 5, 2017

Member

The repair code only handles the most common issues (with recent-ish versions): missing content/data directories and deleting useless title directories. Older versions are much more broken and it may be impossible to fix the issues because some files are actually missing (or they were copied to the wrong location, etc.)

The failing checks should be logged under the CORE category, WARN/ERROR level.

Member

leoetlino commented Oct 5, 2017

The repair code only handles the most common issues (with recent-ish versions): missing content/data directories and deleting useless title directories. Older versions are much more broken and it may be impossible to fix the issues because some files are actually missing (or they were copied to the wrong location, etc.)

The failing checks should be logged under the CORE category, WARN/ERROR level.

leoetlino added some commits Oct 1, 2017

Add a way to check the NAND for issues and fix them
Old versions of Dolphin are so broken regarding NAND handling that
we need this to repair common issues and avoid issues with titles
like the System Menu or the Wii Shop.

This isn't an exhaustive check, but this will catch most issues
and offer to fix them automatically (if possible).
WiiUtils: Attempt to fix the NAND more aggressively
Change the repair logic to fix issues more aggressively by deleting bad
titles. This is necessary because of a bug in Dolphin's WAD boot code.

The UI code was updated to inform the user about titles that will be
deleted if they continue a repair, before deleting anything.
@leoetlino

This comment has been minimized.

Show comment
Hide comment
@leoetlino

leoetlino Oct 8, 2017

Member

Added a commit to make it fix issues more aggressively.

Member

leoetlino commented Oct 8, 2017

Added a commit to make it fix issues more aggressively.

@JMC47

This comment has been minimized.

Show comment
Hide comment
@JMC47

JMC47 Oct 11, 2017

Contributor

I read through all the messages and they seem to be error free. The more aggressive NAND thing is a live saver for someone like me who has a ton of broken NANDs.

Contributor

JMC47 commented Oct 11, 2017

I read through all the messages and they seem to be error free. The more aggressive NAND thing is a live saver for someone like me who has a ton of broken NANDs.

@leoetlino leoetlino merged commit d26eda3 into dolphin-emu:master Oct 11, 2017

10 checks passed

default Very basic checks passed, handed off to Buildbot.
Details
lint Build succeeded on builder lint
Details
pr-android Build succeeded on builder pr-android
Details
pr-deb-dbg-x64 Build succeeded on builder pr-deb-dbg-x64
Details
pr-deb-x64 Build succeeded on builder pr-deb-x64
Details
pr-freebsd-x64 Build succeeded on builder pr-freebsd-x64
Details
pr-osx-x64 Build succeeded on builder pr-osx-x64
Details
pr-ubu-x64 Build succeeded on builder pr-ubu-x64
Details
pr-win-dbg-x64 Build succeeded on builder pr-win-dbg-x64
Details
pr-win-x64 Build succeeded on builder pr-win-x64
Details

@leoetlino leoetlino deleted the leoetlino:wii-fsck branch Oct 11, 2017

@GlydetheSurfer

This comment has been minimized.

Show comment
Hide comment
@GlydetheSurfer

GlydetheSurfer Oct 20, 2017

checked the nand... said it was damaged... repaired it... went to wii save files.... all the save files of my games were GONE...then again... maybe it was because i played games in the past without allowing the emulator to download the wii system update... or maybe its because i saved files from an outdated version.....whatever the case may be.. i still have to start ALL over on EVERYTHING

GlydetheSurfer commented Oct 20, 2017

checked the nand... said it was damaged... repaired it... went to wii save files.... all the save files of my games were GONE...then again... maybe it was because i played games in the past without allowing the emulator to download the wii system update... or maybe its because i saved files from an outdated version.....whatever the case may be.. i still have to start ALL over on EVERYTHING

@JMC47

This comment has been minimized.

Show comment
Hide comment
@JMC47

JMC47 Oct 20, 2017

Contributor

There are literally two warnings that say savedata could be lost. Why did you ignore them if you didn't backup everything?

Contributor

JMC47 commented Oct 20, 2017

There are literally two warnings that say savedata could be lost. Why did you ignore them if you didn't backup everything?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment