Badblocks: Value too large for defined data type invalid end block

Bug #1695229 reported by systems-sk
18
This bug affects 4 people
Affects Status Importance Assigned to Milestone
MAAS
Fix Released
High
Lee Trager
2.2
Fix Released
High
Lee Trager

Bug Description

With Maas 2.2 when doing the hardware badblocks test during commissioning you get the following error when the tested disks are too large

----------------------------------- /dev/sdd -----------------------------------
Model: LSI
Serial: xxx
Badblocks exited with 1!
badblocks: Value too large for defined data type invalid end block (4684569600): must be 32-bit value

The disk is 4.8TB in size

How to reproduce:

Let a new system be discovered via Maas.
Commission new system and select "Badblocks" at the Hardware tests scripts.
Then the error occurs.

Expected Result:
The test is performed with this size of disks.

dpkg -l '*maas*'|cat
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-===============================-==============================-============-=================================================
hi maas 2.2.0+bzr6054-0ubuntu1~16.04.1 all "Metal as a Service" is a physical cloud and IPAM
ii maas-cli 2.2.0+bzr6054-0ubuntu1~16.04.1 all MAAS client and command-line interface
un maas-cluster-controller <none> <none> (no description available)
ii maas-common 2.2.0+bzr6054-0ubuntu1~16.04.1 all MAAS server common files
ii maas-dhcp 2.2.0+bzr6054-0ubuntu1~16.04.1 all MAAS DHCP server
ii maas-dns 2.2.0+bzr6054-0ubuntu1~16.04.1 all MAAS DNS server
ii maas-proxy 2.2.0+bzr6054-0ubuntu1~16.04.1 all MAAS Caching Proxy
ii maas-rack-controller 2.2.0+bzr6054-0ubuntu1~16.04.1 all Rack Controller for MAAS
ii maas-region-api 2.2.0+bzr6054-0ubuntu1~16.04.1 all Region controller API service for MAAS
ii maas-region-controller 2.2.0+bzr6054-0ubuntu1~16.04.1 all Region Controller for MAAS
un maas-region-controller-min <none> <none> (no description available)
un python-django-maas <none> <none> (no description available)
un python-maas-client <none> <none> (no description available)
un python-maas-provisioningserver <none> <none> (no description available)
ii python3-django-maas 2.2.0+bzr6054-0ubuntu1~16.04.1 all MAAS server Django web framework (Python 3)
ii python3-maas-client 2.2.0+bzr6054-0ubuntu1~16.04.1 all MAAS python API client (Python 3)
ii python3-maas-provisioningserver 2.2.0+bzr6054-0ubuntu1~16.04.1 all MAAS server provisioning libraries (Python 3)

Related branches

Revision history for this message
Chenjun Shen (cshen) wrote :

According to https://bugzilla.redhat.com/show_bug.cgi?id=1306522 and https://unix.stackexchange.com/questions/152171/badblocks-only-takes-32-bit-integer-as-start-end-values, 32bit limit seems to be intentional.

One quick fix will be to use "badblocks -b 4096" instead of default "1024".

Lee Trager (ltrager)
Changed in maas:
milestone: none → 2.3.0
assignee: nobody → Lee Trager (ltrager)
importance: Undecided → High
status: New → In Progress
Revision history for this message
Lee Trager (ltrager) wrote :

The related branch passes the physical block size to badblocks. Could you please verify this will work for you? You can either test the related branch or boot into rescue mode and run

blocksize=$(sudo -n blockdev --getbsz /dev/disk)
sudo -n badblocks -b $blocksize -v -w /dev/disk

Changed in maas:
status: In Progress → Fix Committed
Changed in maas:
milestone: 2.3.0 → 2.3.0alpha1
Changed in maas:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.