All of lore.kernel.org
 help / color / mirror / Atom feed
From: Patrick <kpa_info@yahoo.fr>
To: linux-mtd@lists.infradead.org
Subject: Error when mounting ubi image
Date: Mon, 27 Feb 2012 12:18:11 +0100	[thread overview]
Message-ID: <4F4B6673.7030509@yahoo.fr> (raw)

Dear mailing-list,

I am still facing some trouble with UBI and UBIFS. I am working on an 
OMAP4 processor with a 3.0.21 kernel and a Micron MT29F4G08ABBDAH4 1GB 
NAND Flash.

I generate the ubi image of my rootfs using the following command:

   mkfs.ubifs -r my_rootfs -o my_image.ubifs -m 2048 -e 129024 -c 4060
   ubinize -o my_rootfs.ubi -m 2048 -p 128KiB -s 512 ubinize.cfg

And the following ubinize.cfg file:

   [ubifs]
   mode=ubi
   image=my_image.ubifs
   vol_id=0
   vol_type=static
   vol_name=my_rootfs

Then I flash this image and mount it with the following commands:

   ubiformat /dev/mtd4 -f my_rootfs.ubi
   ubiattach -p /dev/mtd4
   mount -t ubifs ubi0_0 /media/test/

I then have the following error:

   mount: block device ubi0_0 is write-protected, mounting read-only

And from the kernel (dmesg):

UBI warning: ubi_eba_read_leb: CRC error: calculated 0x34afeca5, must be 
0x74215933
UBI warning: ubi_open_volume: volume 0 on UBI device 0 is corrupted
UBIFS warning (pid 226): init_constants_early: UBI volume is corrupted - 
read-only mode
UBIFS: static UBI volume - read-only mode
UBIFS error (pid 226): mount_ubifs: cannot mount read-write - read-only 
media
UBIFS warning (pid 226): init_constants_early: UBI volume is corrupted - 
read-only mode
UBIFS: static UBI volume - read-only mode
UBIFS: mounted UBI device 0, volume 0, name "my_rootfs"
UBIFS: mounted read-only
UBIFS: file system size:   42190848 bytes (41202 KiB, 40 MiB, 327 LEBs)
UBIFS: journal size:       9033728 bytes (8822 KiB, 8 MiB, 71 LEBs)
UBIFS: media format:       w4/r0 (latest is w4/r0)
UBIFS: default compressor: lzo
UBIFS: reserved for root:  0 bytes (0 KiB)

I couldn't find what I am doing wrong. Any help will be really appreciated !

Thanks in advance

Patrick

             reply	other threads:[~2012-02-27 11:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-27 11:18 Patrick [this message]
2012-02-27 15:20 ` Error when mounting ubi image Patrick
2012-03-09  9:32   ` Artem Bityutskiy

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=4F4B6673.7030509@yahoo.fr \
    --to=kpa_info@yahoo.fr \
    --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.