Announcement

Collapse
No announcement yet.

using testdisk after problem occurred by partitioning

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

    using testdisk after problem occurred by partitioning

    Dear All,

    I'm using testdisk to repair a HD, which is no longer readable, after having wanted to move the rightest partition to the right, and after an error occurred.
    It wrote me that the HD is to small, because there are too many GB and that the problem is concerning the two or three partitions which have the same name HPFS - NTFS.
    I have now the window that you see enclosed and I would be happy if you could help to decide what to do.
    Attached Files
    Last edited by nicrnicr; Oct 11, 2023, 07:00 AM.

    #2
    Which error occured doing what exactly with which program?

    "HPFS - NTFS" is not the name or label of the partitions but the partitions' file system type.
    Debian KDE & LXQt • Kubuntu & Lubuntu • openSUSE KDE • Windows • macOS X
    Desktop: Lenovo ThinkCentre M75s • Laptop: Apple MacBook Pro 13" • and others

    get rid of Snap script (20.04 +)reinstall Snap for release-upgrade script (20.04 +)
    install traditional Firefox script (22.04 +)​ • install traditional Thunderbird script (24.04)

    Comment


      #3
      Thank you Schwarzer Kater for your answer,

      I beg your pardon.
      I wanted to write again
      Code:
      testdisk
      in a shell, but the screen asked again
      Code:
      create a log file?
      and I've been afraid that it could interfer with the ongoing process.
      I now stopped this ongoing process and took screen captures of the testdisks screens:
      Attached Files

      Comment


        #4
        This is what follows:
        Attached Files

        Comment


          #5
          Thank you very much for viewing.

          I've been looking around.
          This is clear:
          Code:
          The following partition can't be recovered:
          Partition Start End Size in sectors
          > HPFS - NTFS 60800 254 63 67405 253 49 106109249
          In order to save as much partitions as possible, the only following changes are possible
          1)
          Code:
          Partition               Start        End    Size in sectors
          1   P FAT16 >32M               0   1  1     4 254 63      80262 [DellUtility]
          2   P HPFS - NTFS              5  25 21   100 181 17    1536000 [RECOVERY]
          3   * HPFS - NTFS            100 181 18 11049   0 23  175884288 [OS]
          4   L Linux Swap           11049  32 54 12068 251  5    16383984
          5   L Linux                12069  28 56 15893 146 61        61440000
          6   D Linux                15893 179 31 47503 102 23    507809792
          7   L Linux                41062 223 58 54584 165 45     217227264
          8   D Linux                47503 134 56 51150 169 27      58591232
          9   D Linux                52862  60 63 59419 104 13     105340928
          10 D HPFS - NTFS      54196   1 14 60800 254 63  106109249
          ​

          or
          Code:
          Partition               Start        End    Size in sectors
          1   P FAT16 >32M               0   1  1     4 254 63      80262 [DellUtility]
          2   P HPFS - NTFS              5  25 21   100 181 17         1536000 [RECOVERY]
          3   * HPFS - NTFS            100 181 18 11049   0 23   175884288 [OS]
          4   L Linux Swap           11049  32 54 12068 251  5     16383984
          5   L Linux                12069  28 56 15893 146 61         61440000
          6   L Linux                15893 179 31 47503 102 23      507809792
          7   D Linux                41062 223 58 54584 165 45     217227264
          8   L Linux                47503 134 56 51150 169 27        58591232
          9   L Linux                52862  60 63 59419 104 13       105340928
          10 D HPFS - NTFS        54196   1 14 60800 254 63  106109249
          I've been looking the starts and ends of sectors; I choose the second one; and now I have to restart the computer...
          Last edited by Snowhog; Oct 12, 2023, 02:25 PM.

          Comment


            #6
            I also have had to swap
            Code:
            1   P
            3   *
            with
            Code:
            1   *
            3   P
            The partitions are now readable.
            But sda7 cannot start.
            I get the following message:
            Code:
            error: invalid magic number
            error: you need to load the kernel first
            Attached Files
            Last edited by nicrnicr; Oct 12, 2023, 02:56 PM.

            Comment


              #7
              Perhaps a corrupt /boot/vmlinuz on /dev/sda7?
              You could try reinstalling the kernel for this partition… And update GRUB there, too.
              Debian KDE & LXQt • Kubuntu & Lubuntu • openSUSE KDE • Windows • macOS X
              Desktop: Lenovo ThinkCentre M75s • Laptop: Apple MacBook Pro 13" • and others

              get rid of Snap script (20.04 +)reinstall Snap for release-upgrade script (20.04 +)
              install traditional Firefox script (22.04 +)​ • install traditional Thunderbird script (24.04)

              Comment


                #8
                Thank you for viewing and thank you Schwarzer Kater for your suggestion.

                I guess the problem is that there is only one / for the first linux partition and no / and no /home for the second linux.
                Please, do you know how I can change this?

                Comment


                  #9
                  The error messages you listed usually mean the drive/partition is corrupted. You could try fixes like those Schwarzer Kater​ suggests, but you may be chasing a rabbit down a very deep hole.

                  If the partitions are readable/mountable (or at a minimum SDA7), I would very strongly suggest coping off all the data you need to save and then wiping it clean and starting over.

                  Please Read Me

                  Comment


                    #10
                    Originally posted by nicrnicr View Post
                    Thank you for viewing and thank you Schwarzer Kater for your suggestion.

                    I guess the problem is that there is only one / for the first linux partition and no / and no /home for the second linux.
                    Please, do you know how I can change this?
                    "/" and "/home" are just mount points for some partition (technically, file systems are mounted not partitions actually)

                    I'm unclear what you're asking for here. Please be specific like including the partition device names and what you are trying to do.

                    It seems maybe you are booting into the install on sda6 and wish to access the other partitions - sda7, sda8, sda9

                    If so, then just make mount points and mount them. For example, open Konsole and type:

                    cd /mnt
                    sudo mkdir sda7 sda8 sda9
                    sudo mount /dev/sda7 /mnt/sda7
                    sudo mount /dev/sda8 /mnt/sda8
                    sudo mount /dev/sda9 /mnt/sda9


                    You now have access to sda7, sda8, sda9.

                    Please Read Me

                    Comment


                      #11
                      Thank you oshunluvr, I would like to add "/" at the sda8 and "/home" at the sda7.

                      Yes I've been thinking about installing everything again.

                      Comment


                        #12
                        Originally posted by nicrnicr View Post
                        Thank you oshunluvr, I would like to add "/" at the sda8 and "/home" at the sda7.
                        It doesn't really work that way. You can't have two "/" mount points at one time. "/" is the system root mount point. Whatever install you boot to will be "/".

                        "/home", if it exists as a separate partition is mounted in /etc/fstab to the /home folder.

                        I assume you have a second install on sda8 and when you boot to it sda7 is /home, but when you boot sda6, /home is a folder and not sda7.

                        Are you asking to have sda7 mounted at /home when using sda8 and sda6?

                        If yes, boot to sda6, edit /etc/fstab and add the line:

                        Code:
                        /dev/sda7 /home ext4 defaults 0 2
                        then when you reboot sda7 will be /home.

                        Note that any files currently in /home on sda6 will be hidden and made inaccessible by the mount.

                        Please Read Me

                        Comment


                          #13
                          Thank you very much oshunluvr but I abandoned the idea of adding / and /home; because it seems too complicated to write
                          Code:
                          mkdir
                          and
                          Code:
                          mnt
                          in the good partitions.
                          I'm saving everything in order to install again.

                          Comment

                          Working...
                          X