UBI volume autoresize fails

Bug #1187885 reported by Benoît Thébaudeau on 2013-06-05
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)

Bug Description

Steps to reproduce:
 - Create some 'target' folder containing any files.
 - `mkfs.ubifs -e 0x1f800 -c 984 -m 0x800 -F -x lzo -d target -o rootfs.ubifs`.
 - Create the following 'ubinize.cfg' file:
 - `ubinize -m 0x800 -p 0x20000 -s 0x200 -o rootfs.ubi ubinize.cfg`.
 - `sudo modprobe nandsim first_id_byte=0x2c second_id_byte=0xf1 third_id_byte=0x80 fourth_id_byte=0x95`.
 - `sudo nandwrite -p /dev/mtd0 rootfs.ubi`.
 - `sudo modprobe ubi mtd=0`.

 - After last command line: "ERROR: could not insert 'ubi': No space left on device".
 - In dmesg:
[47346.410763] [nandsim] warning: read_byte: unexpected data output cycle, state is STATE_READY return 0x0
[47346.410767] [nandsim] warning: read_byte: unexpected data output cycle, state is STATE_READY return 0x0
[47346.410769] [nandsim] warning: read_byte: unexpected data output cycle, state is STATE_READY return 0x0
[47346.410770] [nandsim] warning: read_byte: unexpected data output cycle, state is STATE_READY return 0x0
[47346.410774] NAND device: Manufacturer ID: 0x2c, Chip ID: 0xf1 (Micron NAND 128MiB 3,3V 8-bit), 128MiB, page size: 2048, OOB size: 64
[47346.410789] flash size: 128 MiB
[47346.410790] page size: 2048 bytes
[47346.410792] OOB area size: 64 bytes
[47346.410793] sector size: 128 KiB
[47346.410794] pages number: 65536
[47346.410795] pages per sector: 64
[47346.410796] bus width: 8
[47346.410797] bits in sector size: 17
[47346.410799] bits in page size: 11
[47346.410800] bits in OOB size: 6
[47346.410801] flash size with OOB: 135168 KiB
[47346.410802] page address bytes: 4
[47346.410803] sector address bytes: 2
[47346.410804] options: 0x8
[47346.410996] Scanning device for bad blocks
[47346.411004] [nandsim] warning: write_byte: command (0x0) wasn't expected, expected state is STATE_READY, ignore previous states
[47346.416700] Creating 1 MTD partitions on "NAND 128MiB 3,3V 8-bit":
[47346.416704] 0x000000000000-0x000008000000 : "NAND simulator partition 0"
[47365.434784] UBI: default fastmap pool size: 50
[47365.434791] UBI: default fastmap WL pool size: 25
[47365.434793] UBI: attaching mtd0 to ubi0
[47365.436872] UBI: scanning is finished
[47365.437321] UBI error: autoresize: cannot auto-resize volume 0
[47365.437399] UBI error: ubi_init: cannot attach mtd0
[47365.437954] UBI error: ubi_init: UBI error: cannot initialize UBI, error -28

Expected result: no error, UBI probed successfully.

This test worked fine with some previous Ubuntu versions.

Note that the issue disappears if 'vol_flags=autoresize' is removed from ubinize.cfg, but setting vol_size instead is not an optimal solution.

This looks very much like the issue described here:

ProblemType: Bug
DistroRelease: Ubuntu 13.04
Package: linux-image-3.8.0-23-generic 3.8.0-23.34
ProcVersionSignature: Ubuntu 3.8.0-23.34-generic 3.8.11
Uname: Linux 3.8.0-23-generic i686
ApportVersion: 2.9.2-0ubuntu8.1
Architecture: i386
 /dev/snd/controlC0: bthebaudeau 2634 F.... pulseaudio
CRDA: Error: command ['iw', 'reg', 'get'] failed with exit code 1: nl80211 not found.
Date: Wed Jun 5 20:11:42 2013
HibernationDevice: RESUME=UUID=7893e31d-56e2-480a-b91f-a5143a766ec0
InstallationDate: Installed on 2013-06-03 (2 days ago)
InstallationMedia: Ubuntu 13.04 "Raring Ringtail" - Release i386 (20130424)
 lo no wireless extensions.

 eth0 no wireless extensions.
 Bus 002 Device 002: ID 0e0f:0003 VMware, Inc. Virtual Mouse
 Bus 002 Device 003: ID 0e0f:0002 VMware, Inc. Virtual USB Hub
 Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
 Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
MachineType: VMware, Inc. VMware Virtual Platform
MarkForUpload: True
ProcFB: 0 svgadrmfb
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.8.0-23-generic root=UUID=d55977dd-09cd-4a6f-aa07-27a3b9272183 ro quiet splash
 linux-restricted-modules-3.8.0-23-generic N/A
 linux-backports-modules-3.8.0-23-generic N/A
 linux-firmware 1.106

SourcePackage: linux
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 07/02/2012
dmi.bios.vendor: Phoenix Technologies LTD
dmi.bios.version: 6.00
dmi.board.name: 440BX Desktop Reference Platform
dmi.board.vendor: Intel Corporation
dmi.board.version: None
dmi.chassis.asset.tag: No Asset Tag
dmi.chassis.type: 1
dmi.chassis.vendor: No Enclosure
dmi.chassis.version: N/A
dmi.modalias: dmi:bvnPhoenixTechnologiesLTD:bvr6.00:bd07/02/2012:svnVMware,Inc.:pnVMwareVirtualPlatform:pvrNone:rvnIntelCorporation:rn440BXDesktopReferencePlatform:rvrNone:cvnNoEnclosure:ct1:cvrN/A:
dmi.product.name: VMware Virtual Platform
dmi.product.version: None
dmi.sys.vendor: VMware, Inc.

Benoît Thébaudeau (btheb) wrote :

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Joseph Salisbury (jsalisbury) wrote :

Would it be possible for you to test the latest upstream kernel? Refer to https://wiki.ubuntu.com/KernelMainlineBuilds . Please test the latest v3.10 kernel[0].

If this bug is fixed in the mainline kernel, please add the following tag 'kernel-fixed-upstream'.

If the mainline kernel does not fix this bug, please add the tag: 'kernel-bug-exists-upstream'.

If you are unable to test the mainline kernel, for example it will not boot, please add the tag: 'kernel-unable-to-test-upstream'.
Once testing of the upstream kernel is complete, please mark this bug as "Confirmed".

Thanks in advance.

[0] http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.10-rc4-saucy/

Changed in linux (Ubuntu):
importance: Undecided → Medium
status: Confirmed → Incomplete
Benoît Thébaudeau (btheb) wrote :

Hi Joseph,

I have just performed the test that you asked for, and the result is the same. I update the tags accordingly.


tags: added: kernel-bug-exists-upstream
Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Benoît Thébaudeau (btheb) wrote :

Good news: I can't reproduce this issue with Ubuntu 14.04.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers