* Looking for an alternative to ubimirror
@ 2016-05-27 0:40 PJ
2016-05-27 7:12 ` Richard Weinberger
2016-05-27 7:19 ` Richard Weinberger
0 siblings, 2 replies; 4+ messages in thread
From: PJ @ 2016-05-27 0:40 UTC (permalink / raw)
To: linux-mtd
Hi,
Can anyone please recommend a procedure to copy one UBI volume to another?
I'd like to execute from the bash command line, if possible.
One upon a time I was able to use ubimirror, however that command appears to
have been removed from mtd-utils.
- The source volume will be mounted R/O as it is the rootfs.
- The destination volume will be unrestricted (unmounted).
- Both the source and destination volumes are in the same device.
I checked the FAQ, the archive, and Google but I came up empty, so thanks.
Paul
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Looking for an alternative to ubimirror
2016-05-27 0:40 Looking for an alternative to ubimirror PJ
@ 2016-05-27 7:12 ` Richard Weinberger
2016-05-27 7:19 ` Richard Weinberger
1 sibling, 0 replies; 4+ messages in thread
From: Richard Weinberger @ 2016-05-27 7:12 UTC (permalink / raw)
To: PJ, Artem Bityutskiy; +Cc: linux-mtd@lists.infradead.org
On Fri, May 27, 2016 at 2:40 AM, PJ <paul.j2@rogers.com> wrote:
> Hi,
>
> Can anyone please recommend a procedure to copy one UBI volume to another?
>
> I'd like to execute from the bash command line, if possible.
>
> One upon a time I was able to use ubimirror, however that command appears to
> have been removed from mtd-utils.
>
> - The source volume will be mounted R/O as it is the rootfs.
> - The destination volume will be unrestricted (unmounted).
> - Both the source and destination volumes are in the same device.
>
> I checked the FAQ, the archive, and Google but I came up empty, so thanks.
This happened some time ago:
commit 94a20240f9d6776619d7652013bb10131ddad1fc
Author: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Date: Tue Sep 28 10:47:06 2010 +0300
ubi-utils: remove old ubi-utils
The utilities are unmaintained for long time, and many of them
do not even work, just compile, and no on complains about this.
This suggests they are unused and we can now safely kill them.
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Artem? :-)
--
Thanks,
//richard
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: Looking for an alternative to ubimirror
2016-05-27 0:40 Looking for an alternative to ubimirror PJ
2016-05-27 7:12 ` Richard Weinberger
@ 2016-05-27 7:19 ` Richard Weinberger
2016-05-27 23:13 ` PJ
1 sibling, 1 reply; 4+ messages in thread
From: Richard Weinberger @ 2016-05-27 7:19 UTC (permalink / raw)
To: PJ; +Cc: linux-mtd@lists.infradead.org
On Fri, May 27, 2016 at 2:40 AM, PJ <paul.j2@rogers.com> wrote:
> Hi,
>
> Can anyone please recommend a procedure to copy one UBI volume to another?
>
> I'd like to execute from the bash command line, if possible.
>
> One upon a time I was able to use ubimirror, however that command appears to
> have been removed from mtd-utils.
>
> - The source volume will be mounted R/O as it is the rootfs.
> - The destination volume will be unrestricted (unmounted).
> - Both the source and destination volumes are in the same device.
Did you try dd if=/dev/ubiX_Y ... | ubiupdatevol ...?
--
Thanks,
//richard
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: Looking for an alternative to ubimirror
2016-05-27 7:19 ` Richard Weinberger
@ 2016-05-27 23:13 ` PJ
0 siblings, 0 replies; 4+ messages in thread
From: PJ @ 2016-05-27 23:13 UTC (permalink / raw)
To: 'Richard Weinberger'; +Cc: linux-mtd
Thanks Richard. It works for me.
An example for future reference. Copy /dev/ubi0_0 to /dev/ubi0_1:
The volume size (in bytes) is required when calling ubiupdatevol without an image file. It can be retrieved from ubinfo, something like this:
VOLSIZE=$(ubinfo /dev/ubi0_0 | grep -o '[0-9]\+ bytes' | grep -o '[0-9]\+')
In the ubiupdatevol a single dash ('-') is used in place of an image-file to trigger use of stdin.
dd if=/dev/ubi0_0 | ubiupdatevol /dev/ubi0_1 - -s ${VOLSIZE}
Paul
-----Original Message-----
From: Richard Weinberger [mailto:richard.weinberger@gmail.com]
Sent: Friday, May 27, 2016 3:20 AM
To: PJ
Cc: linux-mtd@lists.infradead.org
Subject: Re: Looking for an alternative to ubimirror
On Fri, May 27, 2016 at 2:40 AM, PJ <paul.j2@rogers.com> wrote:
> Hi,
>
> Can anyone please recommend a procedure to copy one UBI volume to another?
>
> I'd like to execute from the bash command line, if possible.
>
> One upon a time I was able to use ubimirror, however that command
> appears to have been removed from mtd-utils.
>
> - The source volume will be mounted R/O as it is the rootfs.
> - The destination volume will be unrestricted (unmounted).
> - Both the source and destination volumes are in the same device.
Did you try dd if=/dev/ubiX_Y ... | ubiupdatevol ...?
--
Thanks,
//richard
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2016-05-27 23:14 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-05-27 0:40 Looking for an alternative to ubimirror PJ
2016-05-27 7:12 ` Richard Weinberger
2016-05-27 7:19 ` Richard Weinberger
2016-05-27 23:13 ` PJ
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).