You appear to be making it a lot more complicated than it is. You've for
the -F flag on there which means to force the certain options which
might not name sense. Then you've got "-O ^64bit" to disable the 64bit
feature which means you can only have a partition of around 4 gigs max.
Then you've got "-L '/opt'" which is just the label for the partition,
but I'd remove the / from the beginning of your label so it doesn't
cause confusion or problems later when you use it in your config files.
You also seem to be changing that label between "/home" and "/opt" so
I'm guessing that the -L command doesn't do what you think it's going
(insert mandatory scene from princess bride here).
The biggest problem you have with you command is the number at the end.
That number tells the mkfs to format that much space even if the size of
the partition is different.
I think you'll have much better luck if you try something simple like,
but only do the -L "opt" part if that truly is the label you'd like your
drive to have otherwise change it to something more appropriate or
simply leave it off :
mkfs.ext4 -L "opt" /dev/sdc10
Brian Cluff
On 7/25/21 7:09 PM, Michael via PLUG-discuss wrote:
> gparted is failing me.It is a logical partition(/dev/sdc10) labled
> /home. It is 48 GB large. here is my attempt at using mkfs:
>
> michael@MyNUC:~$ sudo mkfs.ext4 -F -O ^64bit -L '/opt' '/dev/sdc10' 00:00:03
> [sudo] password for michael:
> mke2fs 1.45.5 (07-Jan-2020)
> mkfs.ext4: invalid blocks '00:00:03' on device '/dev/sdc10'
> michael@MyNUC:~$ sudo mkfs.ext4 -F -O ^64bit -L '/opt' '/dev/sdc10' 500
> mke2fs 1.45.5 (07-Jan-2020)
> /dev/sdc10 contains a ext4 file system
> created on Sun Jul 25 21:38:59 2021
> 64-bit filesystem support is not enabled. The larger fields afforded
> by this feature enable full-strength checksumming. Pass -O 64bit to
> rectify.
>
> Filesystem too small for a journal
> Discarding device blocks: done
> Creating filesystem with 125 4k blocks and 64 inodes
>
> Allocating group tables: done
> Writing inode tables: done
> Writing superblocks and filesystem accounting information: done
>
> michael@MyNUC:~$ sudo mkfs.ext4 -F -O ^64bit -L '/opt' '/dev/sdc10' 125 4k
> mke2fs 1.45.5 (07-Jan-2020)
> Usage: mkfs.ext4 [-c|-l filename] [-b block-size] [-C cluster-size]
> [-i bytes-per-inode] [-I inode-size] [-J journal-options]
> [-G flex-group-size] [-N number-of-inodes] [-d root-directory]
> [-m reserved-blocks-percentage] [-o creator-os]
> [-g blocks-per-group] [-L volume-label] [-M last-mounted-directory]
> [-O feature[,...]] [-r fs-revision] [-E extended-option[,...]]
> [-t fs-type] [-T usage-type ] [-U UUID] [-e errors_behavior][-z undo_file]
> [-jnqvDFSV] device [blocks-count]
> michael@MyNUC:~$ sudo mkfs.ext4 -F -O ^64bit -L '/opt' '/dev/sdc10' 125
> mke2fs 1.45.5 (07-Jan-2020)
> /dev/sdc10 contains a ext4 file system labelled '/opt'
> created on Sun Jul 25 21:47:13 2021
> /dev/sdc10: Not enough space to build proposed filesystem while
> setting up superblock
> michael@MyNUC:~$ sudo mkfs.ext4 -F -O ^64bit -L '/home' '/dev/sdc10' 125
> mke2fs 1.45.5 (07-Jan-2020)
> /dev/sdc10 contains a ext4 file system labelled '/opt'
> created on Sun Jul 25 21:47:13 2021
> /dev/sdc10: Not enough space to build proposed filesystem while
> setting up superblock
> michael@MyNUC:~$ sudo mkfs.ext4 -F -O ^64bit -L '/home' '/dev/sdc10' 125
> mke2fs 1.45.5 (07-Jan-2020)
> /dev/sdc10 contains a ext4 file system labelled '/opt'
> created on Sun Jul 25 21:47:13 2021
> /dev/sdc10: Not enough space to build proposed filesystem while
> setting up superblock
> michael@MyNUC:~$
>
> Hmmmmmmm.... not enough space? But gparted says:
>
> All operations completed successfully though the error report says
> otherwise (including saying I created a MSDOS partition when I created
> ext4 partitions).
>
> (error report)
> 48.00 GiB of unallocated space within the partition.
> To grow the file system to fill the partition, select the partition
> and choose the menu item:
> Partition --> Check.
>
> and I run the partition check and the result is:
>
> GParted 1.0.0
>
> configuration --enable-libparted-dmraid --enable-online-resize
>
> libparted 3.3
>
> ========================================
>
> Device:/dev/sda
> Model:ATA KINGSTON SUV500M
> Serial:50026B7783458A92
> Sector size:512
> Total sectors:468862128
>
> Heads:255
> Sectors/track:2
> Cylinders:919337
>
> Partition table:msdos
>
> PartitionTypeStartEndFlagsPartition NameFile SystemLabelMount Point
> /dev/sda2Extended2046468860927bootextended
> /dev/sda6Logical2048410267647ext4/home
> /dev/sda5Logical410267648468860927ext4/
>
> ========================================
>
> Device:/dev/sdc
> Model:USB SanDisk 3.2Gen1
> Serial:none
> Sector size:512
> Total sectors:240353280
>
> Heads:255
> Sectors/track:2
> Cylinders:471280
>
> Partition table:msdos
>
> PartitionTypeStartEndFlagsPartition NameFile SystemLabelMount Point
> /dev/sdc1Primary32240353279lbafat32
>
> ========================================
>
> Delete /dev/sdc1 (fat32, 114.61 GiB) from /dev/sdc 00:00:01 ( SUCCESS )
>
> calibrate /dev/sdc1 00:00:00 ( SUCCESS )
>
> path: /dev/sdc1 (partition)
> start: 32
> end: 240353279
> size: 240353248 (114.61 GiB)
> delete partition 00:00:01 ( SUCCESS )
>
> ========================================
>
> Create Extended Partition #1 (extended, 114.61 GiB) on /dev/sdc
> 00:00:00 ( SUCCESS )
>
> create empty partition 00:00:00 ( SUCCESS )
>
> path: /dev/sdc1 (partition)
> start: 2048
> end: 240353279
> size: 240351232 (114.61 GiB)
>
> ========================================
>
> Create Logical Partition #2 (ext4, 200.00 MiB) on /dev/sdc 00:00:02
> ( SUCCESS )
>
> create empty partition 00:00:01 ( SUCCESS )
>
> path: /dev/sdc5 (partition)
> start: 4096
> end: 413695
> size: 409600 (200.00 MiB)
> clear old file system signatures in /dev/sdc5 00:00:00 ( SUCCESS )
>
> write 512.00 KiB of zeros at byte offset 0 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 67108864 00:00:00 ( SUCCESS )
> write 512.00 KiB of zeros at byte offset 209190912 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 209649664 00:00:00 ( SUCCESS )
> write 8.00 KiB of zeros at byte offset 209707008 00:00:00 ( SUCCESS )
> flush operating system cache of /dev/sdc 00:00:00 ( SUCCESS )
> set partition type on /dev/sdc5 00:00:01 ( SUCCESS )
>
> new partition type: ext4
> create new ext4 file system 00:00:00 ( SUCCESS )
>
> mkfs.ext4 -F -O ^64bit -L '/boot' '/dev/sdc5' 00:00:00 ( SUCCESS )
>
> 64-bit filesystem support is not enabled. The larger fields afforded
> by this feature enable full-strength checksumming. Pass -O 64bit to
> rectify.
> Creating filesystem with 51200 4k blocks and 51200 inodes
> Filesystem UUID: 296fdc84-e20a-4796-92ed-1c161b3701db
> Superblock backups stored on blocks:
> 32768
>
> Allocating group tables: done
> Writing inode tables: done
> Creating journal (4096 blocks): done
> Writing superblocks and filesystem accounting information: done
>
> mke2fs 1.45.5 (07-Jan-2020)
>
> ========================================
>
> Create Logical Partition #3 (ext4, 19.53 GiB) on /dev/sdc 00:00:08
> ( SUCCESS )
>
> create empty partition 00:00:01 ( SUCCESS )
>
> path: /dev/sdc6 (partition)
> start: 415744
> end: 41375743
> size: 40960000 (19.53 GiB)
> clear old file system signatures in /dev/sdc6 00:00:00 ( SUCCESS )
>
> write 512.00 KiB of zeros at byte offset 0 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 67108864 00:00:00 ( SUCCESS )
> write 512.00 KiB of zeros at byte offset 20970995712 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 20971454464 00:00:00 ( SUCCESS )
> write 8.00 KiB of zeros at byte offset 20971511808 00:00:00 ( SUCCESS )
> flush operating system cache of /dev/sdc 00:00:00 ( SUCCESS )
> set partition type on /dev/sdc6 00:00:01 ( SUCCESS )
>
> new partition type: ext4
> create new ext4 file system 00:00:06 ( SUCCESS )
>
> mkfs.ext4 -F -O ^64bit -L '/' '/dev/sdc6' 00:00:06 ( SUCCESS )
>
> 64-bit filesystem support is not enabled. The larger fields afforded
> by this feature enable full-strength checksumming. Pass -O 64bit to
> rectify.
> Creating filesystem with 5120000 4k blocks and 1281120 inodes
> Filesystem UUID: 8dce917e-6a31-4121-914d-b2fe3235c921
> Superblock backups stored on blocks:
> 32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
> 4096000
>
> Allocating group tables: done
> Writing inode tables: done
> Creating journal (32768 blocks): done
> Writing superblocks and filesystem accounting information: done
>
> mke2fs 1.45.5 (07-Jan-2020)
>
> ========================================
>
> Create Logical Partition #4 (linux-swap, 2.11 GiB) on /dev/sdc
> 00:00:04 ( SUCCESS )
>
> create empty partition 00:00:02 ( SUCCESS )
>
> path: /dev/sdc7 (partition)
> start: 235935744
> end: 240353279
> size: 4417536 (2.11 GiB)
> clear old file system signatures in /dev/sdc7 00:00:00 ( SUCCESS )
>
> write 512.00 KiB of zeros at byte offset 0 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 67108864 00:00:00 ( SUCCESS )
> write 512.00 KiB of zeros at byte offset 2261254144 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 2261712896 00:00:00 ( SUCCESS )
> write 8.00 KiB of zeros at byte offset 2261770240 00:00:00 ( SUCCESS )
> flush operating system cache of /dev/sdc 00:00:00 ( SUCCESS )
> set partition type on /dev/sdc7 00:00:02 ( SUCCESS )
>
> new partition type: linux-swap(v1)
> create new linux-swap file system 00:00:00 ( SUCCESS )
>
> mkswap -L '' '/dev/sdc7' 00:00:00 ( SUCCESS )
>
> Setting up swapspace version 1, size = 2.1 GiB (2261774336 bytes)
> LABEL=, UUID=ea5b83f8-f164-402f-8d2b-ef20ed7d0430
>
> ========================================
>
> Create Logical Partition #5 (unformatted, 1.00 MiB) on /dev/sdc
> 00:00:02 ( SUCCESS )
>
> create empty partition 00:00:02 ( SUCCESS )
>
> path: /dev/sdc8 (partition)
> start: 41377792
> end: 41379839
> size: 2048 (1.00 MiB)
>
> ========================================
>
> Create Logical Partition #6 (ext4, 200.00 MiB) on /dev/sdc 00:00:05
> ( SUCCESS )
>
> create empty partition 00:00:01 ( SUCCESS )
>
> path: /dev/sdc9 (partition)
> start: 41381888
> end: 41791487
> size: 409600 (200.00 MiB)
> clear old file system signatures in /dev/sdc9 00:00:01 ( SUCCESS )
>
> write 512.00 KiB of zeros at byte offset 0 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 67108864 00:00:00 ( SUCCESS )
> write 512.00 KiB of zeros at byte offset 209190912 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 209649664 00:00:00 ( SUCCESS )
> write 8.00 KiB of zeros at byte offset 209707008 00:00:00 ( SUCCESS )
> flush operating system cache of /dev/sdc 00:00:01 ( SUCCESS )
> set partition type on /dev/sdc9 00:00:02 ( SUCCESS )
>
> new partition type: ext4
> create new ext4 file system 00:00:01 ( SUCCESS )
>
> mkfs.ext4 -F -O ^64bit -L '/boot' '/dev/sdc9' 00:00:01 ( SUCCESS )
>
> 64-bit filesystem support is not enabled. The larger fields afforded
> by this feature enable full-strength checksumming. Pass -O 64bit to
> rectify.
> Creating filesystem with 51200 4k blocks and 51200 inodes
> Filesystem UUID: dc1ef0e5-fa9f-40b5-aa31-23c36e15960e
> Superblock backups stored on blocks:
> 32768
>
> Allocating group tables: done
> Writing inode tables: done
> Creating journal (4096 blocks): done
> Writing superblocks and filesystem accounting information: done
>
> mke2fs 1.45.5 (07-Jan-2020)
>
> ========================================
>
> Create Logical Partition #7 (ext4, 7.81 GiB) on /dev/sdc 00:00:09
> ( SUCCESS )
>
> create empty partition 00:00:02 ( SUCCESS )
>
> path: /dev/sdc10 (partition)
> start: 41793536
> end: 58177535
> size: 16384000 (7.81 GiB)
> clear old file system signatures in /dev/sdc10 00:00:01 ( SUCCESS )
>
> write 512.00 KiB of zeros at byte offset 0 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 67108864 00:00:00 ( SUCCESS )
> write 512.00 KiB of zeros at byte offset 8388083712 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 8388542464 00:00:00 ( SUCCESS )
> write 8.00 KiB of zeros at byte offset 8388599808 00:00:00 ( SUCCESS )
> flush operating system cache of /dev/sdc 00:00:00 ( SUCCESS )
> set partition type on /dev/sdc10 00:00:03 ( SUCCESS )
>
> new partition type: ext4
> create new ext4 file system 00:00:03 ( SUCCESS )
>
> mkfs.ext4 -F -O ^64bit -L '/opt' '/dev/sdc10' 00:00:03 ( SUCCESS )
>
> 64-bit filesystem support is not enabled. The larger fields afforded
> by this feature enable full-strength checksumming. Pass -O 64bit to
> rectify.
> Creating filesystem with 2048000 4k blocks and 512064 inodes
> Filesystem UUID: dbe1eb24-e142-4b4f-8433-d66620ab0b14
> Superblock backups stored on blocks:
> 32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632
>
> Allocating group tables: done
> Writing inode tables: done
> Creating journal (16384 blocks): done
> Writing superblocks and filesystem accounting information: done
>
> mke2fs 1.45.5 (07-Jan-2020)
>
> ========================================
>
> Create Logical Partition #8 (ext4, 29.30 GiB) on /dev/sdc 00:00:14
> ( SUCCESS )
>
> create empty partition 00:00:03 ( SUCCESS )
>
> path: /dev/sdc11 (partition)
> start: 58179584
> end: 119619583
> size: 61440000 (29.30 GiB)
> clear old file system signatures in /dev/sdc11 00:00:00 ( SUCCESS )
>
> write 512.00 KiB of zeros at byte offset 0 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 67108864 00:00:00 ( SUCCESS )
> write 512.00 KiB of zeros at byte offset 31456755712 00:00:00 ( SUCCESS )
> write 4.00 KiB of zeros at byte offset 31457214464 00:00:00 ( SUCCESS )
> write 8.00 KiB of zeros at byte offset 31457271808 00:00:00 ( SUCCESS )
> flush operating system cache of /dev/sdc 00:00:00 ( SUCCESS )
> set partition type on /dev/sdc11 00:00:05 ( SUCCESS )
>
> new partition type: ext4
> create new ext4 file system 00:00:06 ( SUCCESS )
>
> mkfs.ext4 -F -O ^64bit -L '/usr/src' '/dev/sdc11' 00:00:06 ( SUCCESS )
>
> 64-bit filesystem support is not enabled. The larger fields afforded
> by this feature enable full-strength checksumming. Pass -O 64bit to
> rectify.
> Creating filesystem with 7680000 4k blocks and 1921360 inodes
> Filesystem UUID: 4f65f26e-da3a-41e2-af7a-5e4f08ee9cdf
> Superblock backups stored on blocks:
> 32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
> 4096000
>
> Allocating group tables: done
> Writing inode tables: done
> Creating journal (32768 blocks): done
> Writing superblocks and filesystem accounting information: done
>
> mke2fs 1.45.5 (07-Jan-2020)
>
> ========================================
>
> Create Logical Partition #9 (ext4, 55.46 GiB) on /dev/sdc 00:00:00 ( ERROR )
>
> create empty partition 00:00:00 ( ERROR )
>
> libparted messages ( ERROR )
>
> Unable to satisfy all constraints on the partition.
> --
> :-)~MIKE~(-:
> ---------------------------------------------------
> PLUG-discuss mailing list - PLUG-discuss@lists.phxlinux.org
> To subscribe, unsubscribe, or to change your mail settings:
> https://lists.phxlinux.org/mailman/listinfo/plug-discuss
---------------------------------------------------
PLUG-discuss mailing list -
PLUG-discuss@lists.phxlinux.org
To subscribe, unsubscribe, or to change your mail settings:
https://lists.phxlinux.org/mailman/listinfo/plug-discuss