Announcement

Collapse
No announcement yet.

I cannot extend the size of Kubuntu 18.04

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    I cannot extend the size of Kubuntu 18.04

    Dear All,

    I was installing Virtualbox in Kubuntu 18.04 as the screen wrote me that there was a problem due to the lack of space. Therefore I used my USB drive in order to increase the size of Kubuntu 18.04 which is sda7. But it isn't possible!
    Find enclosed the partition:

    Click image for larger version

Name:	partition.jpg
Views:	1
Size:	55.1 KB
ID:	649401

    and my order:

    Click image for larger version

Name:	extens.png
Views:	1
Size:	30.1 KB
ID:	649402

    The error result is:
    Grow partition ‘/dev/sda7’ from 149.01 GiB to 219.22 GiB
    Job: Check file system on partition ‘/dev/sda7’
    Command: e2fsck -f -y -v /dev/sda7
    Check file system on partition ‘/dev/sda7’: Error

    Checking partition ‘/dev/sda7’ before resize/move failed.
    Grow partition ‘/dev/sda7’ from 149.01 GiB to 219.22 GiB: Error

    Please, does someone know what I should do?
    Last edited by nicrnicr; Nov 03, 2018, 11:16 AM.

    #2
    I suspect it's because your partitions are out of order. Thus the free space may not be along side sda7. I no longer have any MSDOS partitioned disks on my system, but "sfdisk -r /dev/sda" will fix the partition order. NOTE THAT YOU A MUCKING ABOUT WITH YOUR PARTITION TABLE! One false move can obliterate your data. Make backups - NOW - and make a backup of your partition table too, then proceed.

    Please Read Me

    Comment


      #3
      Just curious about how those partitions are arranged. You might get some more insight by running
      sudo fdisk -lu
      against that hard drive, to see the start and end of each partition.
      (I am more familiar with GParted Live CD/USB than the KDE partition manager. You can also install gparted from Muon to your hard drive.) In your second graphic, "my order:", the re-size is for 219.22 GiB; why is the "size" in the drop down saying 224,478 MiB (= 224.478 GiB)? Just curious, what if you set the re-size target to, say, 215 GiB? And, yeah, you do want back-ups, of course. If you mess things up, usually TestDisk can put your partition table back together, but that's another sometimes stressful story.
      An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

      Comment


        #4
        Originally posted by Qqmike View Post
        ... 219.22 GiB; why is the "size" in the drop down saying 224,478 MiB (= 224.478 GiB)?
        Nope, you're forgetting the 1024; that's what the "i" indicates. 1 GiB = 1024 MiB, so 224,478 MiB = 219.22 GiB (rounded to two decimals).

        Regards, John Little
        Regards, John Little

        Comment


          #5
          Actually, this may be as simple as running fsck on sda7

          Please Read Me

          Comment


            #6
            @jlittle,
            you're forgetting the 1024;
            Ha! You got me. I didn't think anyone would notice ;-)
            Yes, you're right.
            An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

            Comment


              #7
              Thank you very much oshunluvr, Qqmike & jlittle for your answers.

              At the very begining there was only Windows 7, then I put Kubuntu 14 and I left free space because one never knows. This was usefull as I could afterwards install Kubuntu 16 and some time later a first Kubuntu 18 and then a second one. I think that there are still 50 GB ntfs which should be free at the end but I'm not sure because they are not totally free...

              Each time that I am unhappy with the system, I install another one. I keep the old one if the new one should collapse. As I don't need so much systems, I erased Kubuntu 14, this is why I have place after sda7. If the partition is curious, it might be because I installed Kubuntu sometimes automatically and sometimes not.

              Thank you oshunluvr for giving me the peace of advice to back up (I do it regularly). I'm now learning how to back up a partition table and how to use fsck on sda7. I should write back within two days.

              Comment


                #8
                In case you're not familiar with this...

                If you want to muck about with several installs, using btrfs as the file system (for the OSs that support it at the time of installation, like the *buntus) can make things much easier.

                In particular, your problem with shuffling partitions about can be avoided altogether because you can put many installs in the same partition, where they all share the same free space. Good for smaller SSDs.

                Regards, John Little
                Regards, John Little

                Comment


                  #9
                  Originally posted by jlittle View Post
                  In case you're not familiar with this...

                  If you want to muck about with several installs, using btrfs as the file system (for the OSs that support it at the time of installation, like the *buntus) can make things much easier.

                  In particular, your problem with shuffling partitions about can be avoided altogether because you can put many installs in the same partition, where they all share the same free space. Good for smaller SSDs.

                  Regards, John Little
                  Ah, chip off the old block, that.

                  Please Read Me

                  Comment


                    #10
                    There are utilities that can do it, but direct MBR partition table backup is super simple:

                    sudo dd if=/dev/sda of=sdambr.bin bs=512 count=1

                    then copy sdambr.bin to a thumb drive or other backup location.

                    By way of explanation (in case someone cares) the first 512 bytes of your hard drive contain the boot signature (446 bytes worth) and the partition table (66 bytes). "dd" copies the individual bytes so you now have a byte-for-byte copy of your boot sig and partition table. GPT partition tables are done differently and have their own backups which you can retrieve.

                    Just make sure you get the "if" and "of" straight! They call "dd" "data destroyer" for a reason!

                    If it were my hard drive, I'd fix the partition ordering pronto because that would bug me to no end. Also, at only 16.64GB, you might be able to make a full backup of the ntfs partition and delete it for now, just to get it out of the way.

                    If you consider going to btrfs for *buntus your life will be much simpler in the future, just sayin'

                    Please Read Me

                    Comment


                      #11
                      Thank you very much jlittle and oshunluvr for your further explanations and pieces of advice.
                      As the following thread shows:
                      https://www.kubuntuforums.net/showth...rt-my-computer

                      I've already been trying to install the last Kubuntu (sda7) on a btrfs partition "during two forum pages" after GreyGeek advised me to do so. I suppose it didn't succeed because the computer was trying to create a btrfs inside an ext4.
                      Now I will know that I should use btrfs in the future.

                      I made a copy of my partition table thanks to oshunluvr. I wrote
                      [#]sfdisk -r /dev/sda[/#]
                      but the screen answered that I'm not allowed to open /dev/sda.
                      oshunluvr wrote after that "running fsck on sda7" after that should be ok. I'm now looking how to run fsck on sda7.

                      I also wrote what Qqmike advised:
                      [#]auie@Latitude-E5530:~$ sfdisk -r /dev/sda
                      sfdisk: /dev/sda kann nicht geöffnet werden: Keine Berechtigung
                      auie@Latitude-E5530:~$ sudo fdisk -lu
                      [sudo] Passwort für auie:
                      Festplatte /dev/loop0: 160 MiB, 167788544 Bytes, 327712 Sektoren
                      Einheiten: Sektoren von 1 * 512 = 512 Bytes
                      Sektorgröße (logisch/physikalisch): 512 Bytes / 512 Bytes
                      E/A-Größe (minimal/optimal): 512 Bytes / 512 Bytes

                      Festplatte /dev/loop1: 141,8 MiB, 148664320 Bytes, 290360 Sektoren
                      Einheiten: Sektoren von 1 * 512 = 512 Bytes
                      Sektorgröße (logisch/physikalisch): 512 Bytes / 512 Bytes
                      E/A-Größe (minimal/optimal): 512 Bytes / 512 Bytes

                      Festplatte /dev/loop2: 144,4 MiB, 151375872 Bytes, 295656 Sektoren
                      Einheiten: Sektoren von 1 * 512 = 512 Bytes
                      Sektorgröße (logisch/physikalisch): 512 Bytes / 512 Bytes
                      E/A-Größe (minimal/optimal): 512 Bytes / 512 Bytes

                      Festplatte /dev/loop3: 141,8 MiB, 148623360 Bytes, 290280 Sektoren
                      Einheiten: Sektoren von 1 * 512 = 512 Bytes
                      Sektorgröße (logisch/physikalisch): 512 Bytes / 512 Bytes
                      E/A-Größe (minimal/optimal): 512 Bytes / 512 Bytes

                      Festplatte /dev/loop4: 87,9 MiB, 92114944 Bytes, 179912 Sektoren
                      Einheiten: Sektoren von 1 * 512 = 512 Bytes
                      Sektorgröße (logisch/physikalisch): 512 Bytes / 512 Bytes
                      E/A-Größe (minimal/optimal): 512 Bytes / 512 Bytes

                      Festplatte /dev/loop5: 87,9 MiB, 92119040 Bytes, 179920 Sektoren
                      Einheiten: Sektoren von 1 * 512 = 512 Bytes
                      Sektorgröße (logisch/physikalisch): 512 Bytes / 512 Bytes
                      E/A-Größe (minimal/optimal): 512 Bytes / 512 Bytes


                      Festplatte /dev/loop6: 87,9 MiB, 92123136 Bytes, 179928 Sektoren
                      Einheiten: Sektoren von 1 * 512 = 512 Bytes
                      Sektorgröße (logisch/physikalisch): 512 Bytes / 512 Bytes
                      E/A-Größe (minimal/optimal): 512 Bytes / 512 Bytes

                      Festplatte /dev/loop7: 148,5 MiB, 155652096 Bytes, 304008 Sektoren
                      Einheiten: Sektoren von 1 * 512 = 512 Bytes
                      Sektorgröße (logisch/physikalisch): 512 Bytes / 512 Bytes
                      E/A-Größe (minimal/optimal): 512 Bytes / 512 Bytes

                      Festplatte /dev/sda: 465,8 GiB, 500107862016 Bytes, 976773168 Sektoren
                      Einheiten: Sektoren von 1 * 512 = 512 Bytes
                      Sektorgröße (logisch/physikalisch): 512 Bytes / 4096 Bytes
                      E/A-Größe (minimal/optimal): 4096 Bytes / 4096 Bytes
                      Festplattenbezeichnungstyp: dos
                      Festplattenbezeichner: 0x9a91e749

                      Gerät Boot Anfang Ende Sektoren Größe Kn Typ
                      /dev/sda1 63 80324 80262 39,2M de Dell Dienstprogramm
                      /dev/sda2 * 81920 1617919 1536000 750M 7 HPFS/NTFS/exFAT
                      /dev/sda3 1617920 177500584 175882665 83,9G 7 HPFS/NTFS/exFAT
                      /dev/sda4 177502206 976766975 799264770 381,1G f W95 Erw. (LBA)
                      /dev/sda5 870658803 976766975 106108173 50,6G 7 HPFS/NTFS/exFAT
                      /dev/sda6 854465283 870658739 16193457 7,7G 82 Linux Swap / Solaris
                      /dev/sda7 177502208 490000383 312498176 149G 83 Linux
                      /dev/sda8 637235200 854462463 217227264 103,6G 83 Linux

                      Partition 1 beginnt nicht an einer physikalischen Sektorgrenze.
                      Partition 4 beginnt nicht an einer physikalischen Sektorgrenze.
                      Partition 5 beginnt nicht an einer physikalischen Sektorgrenze.
                      Partition 6 beginnt nicht an einer physikalischen Sektorgrenze.
                      Partitionstabelleneinträge sind nicht in Festplatten-Reihenfolge.

                      auie@Latitude-E5530:~$ [/#]

                      The last part means:
                      Partition 1 don't beginn on a physic secor frontier.
                      Partition 4 don't beginn on a physic secor frontier.
                      Partition 5 don't beginn on a physic secor frontier.
                      Partition 6 don't beginn on a physic secor frontier.
                      The numbers are not in the order of the hd.

                      Comment


                        #12
                        What about the suggestion of oshunluvr,
                        Actually, this may be as simple as running fsck on sda7
                        If I read correctly the error you got, it seems there is a problem with sda7.

                        Looking at the following tells that you should be able to expand sda7:

                        Code:
                        Gerät Boot Anfang Ende Sektoren Größe Kn Typ
                        /dev/sda1 63 80324 80262 39,2M de Dell Dienstprogramm
                        /dev/sda2 * 81920 1617919 1536000 750M 7 HPFS/NTFS/exFAT
                        /dev/sda3 1617920 177500584 175882665 83,9G 7 HPFS/NTFS/exFAT
                        /dev/sda4 [B]177502206[/B] 976766975 799264770 381,1G f W95 Erw. (LBA) [B][COLOR=#ff0000]<-- Extended partition[/COLOR][/B]
                        /dev/sda5 870658803 976766975 106108173 50,6G 7 HPFS/NTFS/exFAT
                        /dev/sda6 854465283 870658739 16193457 7,7G 82 Linux Swap / Solaris
                        /dev/sda7 [B]177502208 490000383[/B] 312498176 149G 83 Linux
                        /dev/sda8 637235200 854462463 217227264 103,6G 83 Linux
                        Did you try GParted (gparted)? It seems that gparetd could check partitions, too, I'm not sure.
                        An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                        Comment


                          #13
                          btw, nicrnicr, I wouldn't worry about your partitions 'out of order.' They all seem to fit together OK, with space to spare, in fact. I have run many systems like this; like you, one thing led to another, and everything gets out of order, but that shouldn't matter--as long as they are not overlapping! ;-)
                          An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

                          Comment


                            #14
                            Originally posted by nicrnicr View Post

                            [#]sfdisk -r /dev/sda[/#]
                            but the screen answered that I'm not allowed to open /dev/sda.
                            oshunluvr wrote after that "running fsck on sda7" after that should be ok. I'm now looking how to run fsck on sda7.
                            You can't do any disk level operations unless you use sudo.

                            Please Read Me

                            Comment


                              #15
                              I wrote
                              Code:
                              auie@Latitude-E5530:~$ sudo sfdisk -r /dev/sda
                              [sudo] Passwort für auie:
                              
                              Die Partitionstabelle wurde verändert.
                              ioctl() wird aufgerufen, um die Partitionstabelle neu einzulesen.
                              Das erneute Einlesen der Partitionstabelle ist fehlgeschlagen.: Das Gerät oder die Ressource ist belegt
                              Der Kernel benutzt noch die alte Tabelle. Die neue Tabelle wird beim nächsten Neustart verwendet werden oder nachdem Sie partprobe(8) oder kpartx(8) ausgeführt haben.
                              Festplatten werden synchronisiert.
                              auie@Latitude-E5530:~$
                              Which means:
                              The partitiontable has been changed
                              ioctl() is being called in order to read the partitionstable again
                              The new reading of the partitionstable failed: The tool is occupied.
                              The kernel uses the old table. The new table will be used after a start or after running partprobe(8) or kpartx(8).
                              Harddrives are being synchronized.

                              When I started again I got (and still have)
                              Code:
                              error: unknown filestystem.
                              entering rescue mode...
                              grub rescue>
                              And the computer wait that I write something after "rescue>"
                              Please, what should I do?
                              Last edited by nicrnicr; Nov 10, 2018, 02:10 AM.

                              Comment

                              Working...
                              X