Environment:
— Virtual machine on VMWare ESX 4.0
— OS: fully up to date RHEL 5.8
After adding a new (virtual) disk I want to create an ext4 partition on LVM on this disk.
Steps taken so far:
$ sudo /sbin/fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel. Changes will remain in memory only,
until you decide to write them. After that, of course, the previous
content won't be recoverable.
The number of cylinders for this disk is set to 10443.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
Command (m for help): n
p
Partition number (1-4): 1
First cylinder (1-10443, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-10443, default 10443):
Using default value 10443
Command (m for help): t
Selected partition 1
Hex code (type L to list codes): 8e
Changed system type of partition 1 to 8e (Linux LVM)
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
$ sudo /usr/sbin/pvcreate /dev/sdb1
Writing physical volume data to disk "/dev/sdb1"
Physical volume "/dev/sdb1" successfully created
$ sudo /usr/sbin/vgcreate VGora /dev/sdb1
/dev/hdc: open failed: No medium found
Volume group "VGora" successfully created
$ sudo /usr/sbin/lvcreate -l "100%FREE" -n oradata VGora
Logical volume "oradata" created
Creating an ext4 partition fails:
$ sudo /sbin/mke2fs -t ext4 /dev/VGora/oradata
mke2fs 1.39 (29-May-2006)
mke2fs: invalid blocks count - /dev/VGora/oradata
More information on the created partition:
$ sudo /usr/sbin/vgdisplay VGora
--- Volume group ---
VG Name VGora
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 2
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 1
Open LV 0
Max PV 0
Cur PV 1
Act PV 1
VG Size 80.00 GB
PE Size 4.00 MB
Total PE 20479
Alloc PE / Size 20479 / 80.00 GB
Free PE / Size 0 / 0
VG UUID ggjERV-sGbG-1nCv-HW61-LJk4-I7cX-Z3Infh
$ sudo /usr/sbin/lvdisplay VGora
--- Logical volume ---
LV Name /dev/VGora/oradata
VG Name VGora
LV UUID nia1PK-7JJ2-jg5T-uN4X-ggYH-R0mS-oqCooY
LV Write Access read/write
LV Status available
# open 0
LV Size 80.00 GB
Current LE 20479
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:4
$ sudo /sbin/fdisk -l /dev/sdb
Disk /dev/sdb: 85.8 GB, 85899345920 bytes
255 heads, 63 sectors/track, 10443 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 10443 83883366 8e Linux LVM
I can’t find any relevant information on this error and don’t know how to resolve this.
- How can I check the block count? and
- How can I correct it to a valid number for ext4?
I’m trying to test restoring a backed up linux file system /apps (ext3 filesystem)
/dev/cciss/c0d0p7 177G 3.8G 164G 3% /apps
I ran the following command to take a dump:
/sbin/dump -0uz -f /backup_labeir1/apps.dmp /apps
Then I deleted the /apps folder:
rm -rf /apps
And unmounted it:
umount -l /apps
Next I’m trying to make the file-system
mke2fs -j -b 4096 -L data /dev/cciss/c0d0p7
after which I’m planning to do the below steps:
# mkdir /apps
# mount -t ext3 /dev/cciss/c0d0p7 /apps
# cd /apps
# restore -rf /backup_labeir1/apps.dmp .
# reboot
I’ve 2 questions:
- Are my testing steps correct
- When I run the below I get the error:
[root@labeir2 backup_labeir1]# mke2fs -F -j -b 4096 -L data /dev/cciss/c0d0p7
mke2fs 1.39 (29-May-2006)
/dev/cciss/c0d0p7 is apparently in use by the system; mke2fs forced anyway.
/dev/cciss/c0d0p7: Device or resource busy while setting up superblock
But neither the filesystem is mounted nor lsof
shows me any output:
lsof | grep /dev/cciss/c0d0p7
lsof /dev/cciss/c0d0p7
Please help me resolve this.
asked Aug 25, 2015 at 9:51
I got the same error when I tried to format a USB drive on Mac OS X. In my case, unmounting the disk first with diskutil unmountDisk ...
solved the problem.
Details: First, run diskutil list
and check the output to figure out which disk you want to format. (Don’t format your hard drive disk0
!) In my case, it was /dev/disk1
. When I first ran mkfs.ext3 /dev/disk1
, I got the message «Resource busy while setting up superblock». But after I ran diskutil unmountDisk disk1
, mkfs.ext3
worked.
Note: Initially, I tried diskutil eject disk1
, but then the disk is not accessible anymore — e.g. diskutil list
doesn’t show it. diskutil unmountDisk disk1
makes sure that the disk is no longer in use, but mkfs.ext3
can still access it.
answered Jan 23, 2016 at 1:28
/dev/cciss/c0d0p7: Device or resource busy while setting up superblock
From my experience, resource busy cause by multipath device map(might have). (e.g. /dev/mapper/mpathi)
If we have this problem, «mke2fs -t ext4 /dev/mapper/mpathi» and «» will fail.
[root@myserver ~]# multipath -ll mpathi
mpathi (snip:myFCdisk) dm-6 snip:myFCdiskProdName
size=100G features='0' hwhandler='1 alua' wp=ro
|-+- policy='round-robin 0' prio=snip:123 status=active
| `- 6:0:0:7 sdv 65:80 active ready running
`-+- policy='round-robin 0' prio=snip:111 status=enabled
`- 5:0:0:7 sdi 8:128 active ready running
[root@myserver ~]#
[root@myserver ~]# mke2fs -F -t ext4 /dev/mapper/mpathi
mke2fs 1.41.12 (17-May-2010)
/dev/mapper/mpathi: Operation not permitted while setting up superblock
[root@myserver ~]#
[root@myserver ~]# mke2fs -F -t ext4 /dev/sdv
mke2fs 1.41.12 (17-May-2010)
/dev/sdv is apparently in use by the system; will not make a filesystem here!
[root@myserver ~]#
My workaround is removing multipath device map temporarily.
- remove multipath device name.(multipath -f /dev/mapper/mpathi)
- run mke2fs for mpath slave device(e.g. mke2fs -F -t ext4 /dev/sdv)
- rebuild multipath device map.(multipath -r)
Have a good day:)
answered Oct 7, 2015 at 6:15
Environment:
— Virtual machine on VMWare ESX 4.0
— OS: fully up to date RHEL 5.8
After adding a new (virtual) disk I want to create an ext4 partition on LVM on this disk.
Steps taken so far:
$ sudo /sbin/fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel. Changes will remain in memory only,
until you decide to write them. After that, of course, the previous
content won't be recoverable.
The number of cylinders for this disk is set to 10443.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
Command (m for help): n
p
Partition number (1-4): 1
First cylinder (1-10443, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-10443, default 10443):
Using default value 10443
Command (m for help): t
Selected partition 1
Hex code (type L to list codes): 8e
Changed system type of partition 1 to 8e (Linux LVM)
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
$ sudo /usr/sbin/pvcreate /dev/sdb1
Writing physical volume data to disk "/dev/sdb1"
Physical volume "/dev/sdb1" successfully created
$ sudo /usr/sbin/vgcreate VGora /dev/sdb1
/dev/hdc: open failed: No medium found
Volume group "VGora" successfully created
$ sudo /usr/sbin/lvcreate -l "100%FREE" -n oradata VGora
Logical volume "oradata" created
Creating an ext4 partition fails:
$ sudo /sbin/mke2fs -t ext4 /dev/VGora/oradata
mke2fs 1.39 (29-May-2006)
mke2fs: invalid blocks count - /dev/VGora/oradata
More information on the created partition:
$ sudo /usr/sbin/vgdisplay VGora
--- Volume group ---
VG Name VGora
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 2
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 1
Open LV 0
Max PV 0
Cur PV 1
Act PV 1
VG Size 80.00 GB
PE Size 4.00 MB
Total PE 20479
Alloc PE / Size 20479 / 80.00 GB
Free PE / Size 0 / 0
VG UUID ggjERV-sGbG-1nCv-HW61-LJk4-I7cX-Z3Infh
$ sudo /usr/sbin/lvdisplay VGora
--- Logical volume ---
LV Name /dev/VGora/oradata
VG Name VGora
LV UUID nia1PK-7JJ2-jg5T-uN4X-ggYH-R0mS-oqCooY
LV Write Access read/write
LV Status available
# open 0
LV Size 80.00 GB
Current LE 20479
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:4
$ sudo /sbin/fdisk -l /dev/sdb
Disk /dev/sdb: 85.8 GB, 85899345920 bytes
255 heads, 63 sectors/track, 10443 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 10443 83883366 8e Linux LVM
I can’t find any relevant information on this error and don’t know how to resolve this.
- How can I check the block count? and
- How can I correct it to a valid number for ext4?
On Ubuntu 20.04 LTS. I have an AOSP tree checked out at android-10.0.0_r39. The tree builds fine for walleye — I can build an run on a device, no issues. I have no new files in the AOSP repo tree. If I switch to blueline, though, I get:
lunch aosp_blueline-userdebug
...
[ 99% 67222/67226] Target system fs image: out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system.img
FAILED: out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system.img
/bin/bash -c "(if [ -d out/target/product/blueline/system/vendor ] && [ ! -h out/target/product/blueline/system/vendor ]; then echo 'Non-symlink out/target/product/blueline/system/vendor detected!' 1>&2; echo 'You cannot install files to out/target/product/blueline/system/vendor while building a separate vendor.img!' 1>&2; exit 1; fi ) && (ln -sf /vendor out/target/product/blueline/system/vendor ) && (if [ -d out/target/product/blueline/system/product ] && [ ! -h out/target/product/blueline/system/product ]; then echo 'Non-symlink out/target/product/blueline/system/product detected!' 1>&2; echo 'You cannot install files to out/target/product/blueline/system/product while building a separate product.img!' 1>&2; exit 1; fi ) && (ln -sf /product out/target/product/blueline/system/product ) && (( cd out/target/product/blueline/system && findres=$(find lib* -path "lib/bootstrap" -prune -o -path "lib64/bootstrap" -prune -o -path "lib/arm" -prune -o -path "lib/arm64" -prune -o -path "lib/vndk-*" -prune -o -path "lib64/vndk-*" -prune -o -type f \( -false -o -name libadbconnection.so -o -name libadbconnectiond.so -o -name libandroidicu.so -o -name libandroidio.so -o -name libart-compiler.so -o -name libart-dexlayout.so -o -name libart-disassembler.so -o -name libart.so -o -name libartbase.so -o -name libartbased.so -o -name libartd-compiler.so -o -name libartd-dexlayout.so -o -name libartd.so -o -name libartpalette.so -o -name libc.so -o -name libdexfile.so -o -name libdexfile_external.so -o -name libdexfiled.so -o -name libdexfiled_external.so -o -name libdl.so -o -name libdt_fd_forward.so -o -name libdt_socket.so -o -name libicui18n.so -o -name libicuuc.so -o -name libjavacore.so -o -name libjdwp.so -o -name libm.so -o -name libnativebridge.so -o -name libnativehelper.so -o -name libnativeloader.so -o -name libnpt.so -o -name libopenjdk.so -o -name libopenjdkjvm.so -o -name libopenjdkjvmd.so -o -name libopenjdkjvmti.so -o -name libopenjdkjvmtid.so -o -name libpac.so -o -name libprofile.so -o -name libprofiled.so -o -name libsigchain.so -o -name libjavacrypto.so \) -print) && if [ -n "$findres" ]; then echo "APEX libraries found in system image (see comment for check-apex-libs-absence" 1>&2; echo "in build/make/core/main.mk for details):" 1>&2; echo "$findres" | sort 1>&2; false; fi; ) ) && (mkdir -p out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/ out/target/product/blueline/obj/PACKAGING/systemimage_intermediates && rm -rf out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "system_other_size=2952790016" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "system_journal_size=0" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "ext_mkuserimg=mkuserimg_mke2fs" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "fs_type=ext4" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "extfs_sparse_flag=-s" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "squashfs_sparse_flag=-s" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "ext4_share_dup_blocks=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "selinux_fc=out/target/product/blueline/obj/ETC/file_contexts.bin_intermediates/file_contexts.bin" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_avbtool=avbtool" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_system_hashtree_enable=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_system_add_hashtree_footer_args=--prop com.android.build.system.os_version:10 --prop com.android.build.system.security_patch:2020-06-05" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_system_other_hashtree_enable=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_system_other_add_hashtree_footer_args=--rollback_index 1591315200" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_system_other_key_path=external/avb/test/data/testkey_rsa4096.pem" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_system_other_algorithm=SHA256_RSA4096" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_vendor_hashtree_enable=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_vendor_add_hashtree_footer_args=--prop com.android.build.vendor.os_version:10 --prop com.android.build.vendor.security_patch:2020-06-05" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_product_hashtree_enable=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_product_add_hashtree_footer_args=--prop com.android.build.product.os_version:10 --prop com.android.build.product.security_patch:2020-06-05" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_product_services_hashtree_enable=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_product_services_add_hashtree_footer_args=--prop com.android.build.product_services.os_version:10 --prop com.android.build.product_services.security_patch:2020-06-05" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_odm_hashtree_enable=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "avb_odm_add_hashtree_footer_args=--prop com.android.build.odm.os_version:10" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "recovery_as_boot=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "root_dir=out/target/product/blueline/root" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "use_dynamic_partition_size=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo "skip_fsck=true" >> out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (PATH=out/host/linux-x86/bin/:$PATH build/make/tools/releasetools/build_image.py out/target/product/blueline/system out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system_image_info.txt out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system.img out/target/product/blueline/system || ( mkdir -p ${DIST_DIR}; cp out/target/product/blueline/installed-files.txt ${DIST_DIR}/installed-files-rescued.txt; exit 1 ) )"
2020-06-18 22:52:22 - build_image.py - ERROR : Failed to build out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system.img from out/target/product/blueline/system
Out of space? Out of inodes? The tree size of /pool/james/aosp/out/soong/.temp/tmpceCvjm is 153844736 bytes (146 MB), with reserved space of 0 bytes (0 MB).
The max image size for filesystem files is 73134080 bytes (69 MB), out of a total partition size of 73134080 bytes (69 MB).
Traceback (most recent call last):
File "build/make/tools/releasetools/build_image.py", line 789, in <module>
main(sys.argv[1:])
File "build/make/tools/releasetools/build_image.py", line 781, in main
BuildImage(in_dir, image_properties, out_file, target_out)
File "build/make/tools/releasetools/build_image.py", line 423, in BuildImage
BuildImageMkfs(in_dir, prop_dict, out_file, target_out, fs_config)
File "build/make/tools/releasetools/build_image.py", line 334, in BuildImageMkfs
mkfs_output = common.RunAndCheckOutput(build_command)
File "/pool/james/aosp/build/make/tools/releasetools/common.py", line 252, in RunAndCheckOutput
args, proc.returncode, output))
common.ExternalError: Failed to run command '['mkuserimg_mke2fs', '-s', '/pool/james/aosp/out/soong/.temp/tmpceCvjm', 'out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system.img', 'ext4', '/', '73134080', '-j', '0', '-D', 'out/target/product/blueline/system', '-L', '/', '-i', '3256', '-M', '0', '-c', '--inode_size', '256', 'out/target/product/blueline/obj/ETC/file_contexts.bin_intermediates/file_contexts.bin']' (exit code 4):
22:52:21 mkuserimg_mke2fs.py INFO: Env: {'MKE2FS_CONFIG': './system/extras/ext4_utils/mke2fs.conf'}
22:52:21 mkuserimg_mke2fs.py INFO: Running: mke2fs -O ^has_journal -L / -N 3256 -I 256 -M / -m 0 -E android_sparse -t ext4 -b 4096 out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system.img 17855
22:52:21 mkuserimg_mke2fs.py INFO: Env: {}
22:52:21 mkuserimg_mke2fs.py INFO: Running: e2fsdroid -p out/target/product/blueline/system -s -S out/target/product/blueline/obj/ETC/file_contexts.bin_intermediates/file_contexts.bin -f /pool/james/aosp/out/soong/.temp/tmpceCvjm -a / out/target/product/blueline/obj/PACKAGING/systemimage_intermediates/system.img
22:52:22 mkuserimg_mke2fs.py ERROR: Failed to run e2fsdroid_cmd: __populate_fs: Could not allocate block in ext2 filesystem while writing file "com.android.runtime.debug.apex"
e2fsdroid: Could not allocate block in ext2 filesystem while populating file system
mke2fs 1.44.4 (18-Aug-2018)
Creating filesystem with 17855 4k blocks and 3264 inodes
Allocating group tables: done
Writing inode tables: done
Writing superblocks and filesystem accounting information: done
__populate_fs: Could not allocate block in ext2 filesystem while writing file "com.android.runtime.debug.apex"
e2fsdroid: Could not allocate block in ext2 filesystem while populating file system
22:52:33 ninja failed with: exit status 1
#### failed to build some targets (01:27:37 (hh:mm:ss)) ####
Suggestions?
View previous topic :: View next topic | |||||||||||||||||
Author | Message | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
optiluca Guru Joined: 16 Jan 2006 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
richard.scott Veteran Joined: 19 May 2003 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
optiluca Guru Joined: 16 Jan 2006 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
frostschutz Advocate Joined: 22 Feb 2005 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
optiluca Guru Joined: 16 Jan 2006 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
hielvc Advocate Joined: 19 Apr 2002 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
optiluca Guru Joined: 16 Jan 2006 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
Hu Moderator Joined: 06 Mar 2007 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
dmpogo Advocate Joined: 02 Sep 2004 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
optiluca Guru Joined: 16 Jan 2006 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
dmpogo Advocate Joined: 02 Sep 2004 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
optiluca Guru Joined: 16 Jan 2006 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
kernelOfTruth Watchman Joined: 20 Dec 2005 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
Atha Apprentice Joined: 22 Sep 2004 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
Delicates n00b Joined: 19 Jul 2005 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
xdarma l33t Joined: 08 Dec 2003 |
|
||||||||||||||||
Back to top |
|
||||||||||||||||
|
You cannot post new topics in this forum |
-
- #1
Hi guys,
I’m trying to set up OMV on my new NAS with 3 5TB drives (new) and 4 2TB drives (old).
When I’m trying to create a new file system it fails on one drive. On every other drive there weren’t any problems.error message:
Error #0: exception 'OMVExecException' with message 'Failed to execute command 'export LANG=C; mkfs -V -t ext4 -b 4096 -m 0 -E lazy_itable_init=0,lazy_journal_init=0 -O 64bit -L 'Daten5' /dev/sdg1 2>&1': mke2fs 1.42.12 (29-Aug-2014) The file /dev/sdg1 does not exist and no size was specified.' in /usr/share/openmediavault/engined/rpc/filesystemmgmt.inc:601 Stack trace: #0 [internal function]: OMVRpcServiceFileSystemMgmt->create(Array, Array) #1 /usr/share/php/openmediavault/rpc/serviceabstract.inc(124): call_user_func_array(Array, Array) #2 /usr/share/php/openmediavault/rpc/rpc.inc(81): OMVRpcServiceAbstract->callMethod('create', Array, Array) #3 /usr/sbin/omv-engined(524): OMVRpcRpc::call('FileSystemMgmt', 'create', Array, Array, 1) #4 {main}
fdsik output:
Command (m for help): p Disk /dev/sdg: 1,8 TiB, 2000398934016 bytes, 3907029168 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disklabel type: gpt Disk identifier: 3EF85236-045F-4020-BA99-B9DFCE3EA7B9 Device Start End Sectors Size Type /dev/sdg1 2048 3907029134 3907027087 1,8T Linux filesystem
Alles anzeigen
I did find a bug report in Mantis but with no result or any tips how to resolve the problem (http://bugtracker.openmediavault.org/view.php?id=1539)
I’m not that good with linux. I tried google without any success. I know OMV 3 ist still beta and this could be a bug. I’m happy to help out identifying the bug and resolve the issue if you can tell me how
-
- Offizieller Beitrag
- #2
Did you wipe the drive? Look in Physical Devices tab if you didn’t.
-
- #3
Yes I did wipe all the old drives (Quick mode).
I just tested the command from the error message via ssh:
root@NAS:~# mkfs -V -t ext4 -b 4096 -m 0 -E lazy_itable_init=0,lazy_journal_init =0 -O 64bit -L 'Daten5' /dev/sdg1 2>&1 mkfs from util-linux 2.25.2 mkfs.ext4 -b 4096 -m 0 -E lazy_itable_init=0,lazy_journal_init=0 -O 64bit -L Dat en5 /dev/sdg1 mke2fs 1.42.12 (29-Aug-2014) Ein Dateisystems mit 488378385 (4k) Blöcken und 122101760 Inodes wird erzeugt. UUID des Dateisystems: 2844218f-73f0-4c6c-b541-39628d95424b Superblock-Sicherungskopien gespeichert in den Blöcken: 32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208, 4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968, 102400000, 214990848 beim Anfordern von Speicher für die Gruppentabellen: erledigt Inode-Tabellen werden geschrieben: erledigt Das Journal (32768 Blöcke) wird angelegt: erledgt Die Superblöcke und die Informationen über die Dateisystemnutzung werden geschrieben: erledigt
Alles anzeigen
I’m sorry the output is in german.
If you do it manually there doesn’t seem to be a problem. After refreshing the WebGUI the drive gets listed correctly in the File System tab.
I don’t know why the OMV script running the command doesn’t work but at least there seems to be a workaround. If you want me testing something for debugging purposes I’m happy to help out. -
- Offizieller Beitrag
- #4
Try:
dd if=/dev/zero of=/dev/sdg bs=512 count=10000
Then see if you can create a filesystem in the webgui.
-
- #5
I deleted the file system I created manually and did what you asked but I got the same error message.
-
- Offizieller Beitrag
- #6
You shouldn’t have to delete anything if you zero’d the drive with the command I posted.
I would post a new bug on bugtracker. Maybe there is something Volker would have you try.
-
- #7
I did create a file system before manually. I thought I had to remove it first in order to create a new one through the WebGUI. Nevertheless it shouldn’t make any difference because I did use your command after deleting the file system.
I did leave a note in Mantis in the existing bug report (bug report isn’t that old, didn’t want to post a new bug report for the samebug).
edit: I did install OMV2 yesterday night because OMV 3 seemed too unstable for me and there weren’t any problems. Just wanted to let you know.
Ubuntu 12.04 LTS, I’ve added a new drive to the system, partitioned it with fdisk and am now trying to format it with mke2fs. The command is failing because it thinks the inodes_count and number of blocks are zero.
NOTE: -n = simulate actions
$ sudo mke2fs -c -L backups -t ext4 -T default -v -n /dev/sdc1
mke2fs 1.42 (29-Nov-2011)
fs_types for mke2fs.conf resolution: 'ext4'
mke2fs: inode_size (256) * inodes_count (0) too big for a
filesystem with 0 blocks, specify higher inode_ratio (-i)
or lower inode count (-N).
Here’s the partition info from sudo fdisk /dev/sdc using the p command:
Disk /dev/sdc: 146.8 GB, 146814976000 bytes
61 heads, 35 sectors/track, 134308 cylinders, total 286748000 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x8b4573b5
Device Boot Start End Blocks Id System
/dev/sdc1 2048 286747999 143372976 5 Extended
So I added that block count 143372976:
$ sudo mke2fs -c -L backups -t ext4 -T default -v -n /dev/sdc1 143372976
mke2fs 1.42 (29-Nov-2011)
fs_types for mke2fs.conf resolution: 'ext4'
Filesystem label=backups
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
8962048 inodes, 35843244 blocks
1792162 blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=4294967296
1094 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872
Ok, looks good. However, when I remove «-n» to actually perform the action, it says Filesystem larger than apparent device size:
$ sudo mke2fs -c -L backups -t ext4 -T default -v /dev/sdc1 143372976
mke2fs 1.42 (29-Nov-2011)
mke2fs: Filesystem larger than apparent device size.
Proceed anyway? (y,n)
And when I enter y to proceed, I get a screen full of errors:
badblocks: Invalid argument during seek
What am I missing?
EDIT
Here are the contents of /etc/mke2fs.conf:
$ cat /etc/mke2fs.conf
[defaults]
base_features = sparse_super,filetype,resize_inode,dir_index,ext_attr
default_mntopts = acl,user_xattr
enable_periodic_fsck = 0
blocksize = 4096
inode_size = 256
inode_ratio = 16384
[fs_types]
ext3 = {
features = has_journal
}
ext4 = {
features = has_journal,extent,huge_file,flex_bg,uninit_bg,dir_nlink,extra_isize
auto_64-bit_support = 1
inode_size = 256
}
ext4dev = {
features = has_journal,extent,huge_file,flex_bg,uninit_bg,dir_nlink,extra_isize
inode_size = 256
options = test_fs=1
}
small = {
blocksize = 1024
inode_size = 128
inode_ratio = 4096
}
floppy = {
blocksize = 1024
inode_size = 128
inode_ratio = 8192
}
big = {
inode_ratio = 32768
}
huge = {
inode_ratio = 65536
}
news = {
inode_ratio = 4096
}
largefile = {
inode_ratio = 1048576
blocksize = -1
}
largefile4 = {
inode_ratio = 4194304
blocksize = -1
}
hurd = {
blocksize = 4096
inode_size = 128
}