From: Sven Eisenberg <sven.eisenberg@novero.com>
To: "linux-mtd@lists.infradead.org" <linux-mtd@lists.infradead.org>
Subject: Migrating to UBI Volumes, keeping some data
Date: Mon, 25 Jan 2016 17:21:40 +0100 [thread overview]
Message-ID: <56A64B94.7000808@novero.com> (raw)
Hello all
I'm facing a common mistake with UBI, we have a system that has nand
partitioning on the MTD layer.
Partitions:
mtd1: root
mtd2: dynamic_data
mtd3: other_data
mtd4: static_data
We have learned the lesson with reduced wear leveling and degraded bad
block pools. Now i plan to migrate also systems in the field to a UBI
volume partitioning concept.
The challenge for me is the data migration of the "static_data"
partition, it is quite big and re-writing the data in the field is not
an option.
Erasing and re-writing the other partitions is not a problem in my
situation. We run the kernel from NOR and have initial data to start from.
After thinking about it i have the following theory of how a migration
could work and I'd like to ask if you also think this is a possible way
or if it is a stupid idea maybe:
Target: migrate, but keep the volume in mtd4.
The system is launched with the old mtd partitioning scheme, and does a
flash_eraseall on mtd1, mtd2, mtd3 but not on mtd4.
Then we reboot with only a single full size MTD configured in the kernel.
Will the kernel UBI scan code be able to merge the erased blocks and the
existing blocks from mtd4 into a consistent UBI device?
The erased blocks should be initialized with the UBI headers, so we can
define the remaining UBI volumes in the next step and initialize the
system with data.
I'm aware that by flash_eraseall the erase counters will be lost in mtd1-3.
The kernel level is ~3.10.y.
Thanks and regards,
Sven Eisenberg
--
Sven Eisenberg
Novero gmbh | Meesmannstr. 103 | 44807 Bochum | Germany
Novero GmbH | Parsevalstr. 7a | 40468 Düsseldorf | Germany | Amtsgericht Düsseldorf | HRB 58283 | Umsatzsteueridentifikationsnummer: DE 814973142 | Geschäftsführer: Freddie Geier
next reply other threads:[~2016-01-25 16:21 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-25 16:21 Sven Eisenberg [this message]
2016-01-25 17:19 ` Migrating to UBI Volumes, keeping some data Richard Weinberger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=56A64B94.7000808@novero.com \
--to=sven.eisenberg@novero.com \
--cc=linux-mtd@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.