My user account doesnt have sudo despite being in sudoers. I cant run new commands i have to execute the binary. Grub takes very long to load with “welcome to grub” message. I just wanted a stable distro as arch broke and currupted my external ssd

    • tal
      link
      fedilink
      arrow-up
      1
      ·
      edit-2
      1 year ago

      Gotcha, so the same spot.

      Well, okay. So whatever is on the drive at failing locations is probably not going to be recoverable. It might still be possible to recover the bulk of the data on the drive, if the filesystem can br’e recovered.

      I can’t speak as to your financial situation or how much you care about that particular data.

      First, it might be possible to hire a data recovery service to deal with it if you really care about it. I have no idea what, if anything, they can do with SSDs that are unreadable. With rotational drives, traditionally the problem was with the drive head, so they’d get a super-dust-free cleanroom, have duplicate hard drives of every model, open up your hard drive in the cleanroom and plop your platters and a fresh drive mechanism together, then pull the data off. That ran like a couple hundred to maybe two thousand bucks. Obviously, that’s not applicable to SSDs, but there may be other things that they can do with them. I also don’t know what they can do with Linux filesystems.

      Second, if you get a new hard drive that is at least as large as the existing one, what can be done is to create a partition on that drive that is at least as large, use ddrescue to copy over what can be copied of the data on the partition and hope that it’s enough for fsck to repair. Then, once you’ve got it working, if the new partition is larger, use resize2fs to grow the filesystem to the partition size. If it’s not possible for fsck to repair it, then just stick a new filesystem on there, probably have to rebuild the music video collection from scratch if possible.

      I can’t promise that the existing data will be recoverable if you get the drive. Even if it is, it’s possible that some music videos may have corrupt data, and it may be hard to easily identify which videos are corrupt. I hate advising people to spend their money, but I can’t think of fantastic alternative approaches at this point; this is what I would do in your shoes at this point.

      So that’s gonna have to be a call that you’re gonna have to make, as to whether you want to get a replacement drive. If you do, it’s possible to try recovering the data.

      If you pulled the music videos off YouTube – I don’t know where else one might have obtained thousands of them – it may be possible to automate re-downloading them, at least the ones that are still on YouTube, using something like yt-dlp. It may be possible to recover the filenames, even if the rest of the filesystem is unrecoverable, which might be used to search for the video. I’d do that via, after using ddrescue to try to pull as much data to the new partition as possible, running strings on the new partition and searching it for filenames.

      So, your call. If you want to try recovery to a new drive, that’s a possibility, but odds are that it won’t be possible to recover everything perfectly-intact.

      I don’t think that there’s a lot more that can be done without a new drive – in theory, it’d be possible to try recovery on the existing drive, but given the state of it, I would guess that it could just wipe out what’s there and still readable, and I’d advise not trying it. So at this point, this is probably blocked on you deciding whether you want to get and actually getting a new drive. If you do, it should be at least as large as the existing one, else it won’t be possible to create a direct copy of the existing partition, which will be a pain for recovery purposes.

      Of the other issues:

      • Boot time. I’d try my suggestion about disconnecting the external drive and seeing if your boot time problem goes away.

      • PATH. Setting PATH to include the /usr/local/sbin, /usr/sbin, and /sbin directories for non-root users should make those commands accessible to non-root users; I describe this in a top-level comment. Alternatively, just running su -l should give you a root shell with a PATH that includes those directories under Debian. I know what has to be done, but not the appropriate place to set it every login for the current desktop environments, as I don’t use them.

      • sudo rights to your user account. As long as you have added your user to the sudo group and logged them out and logged in again, you should be good to go here; I assume that this is working now.

      • Distro. I am inclined to believe that there was likely not anything wrong with your Arch installation other then the failing drive, from what you’ve told us. I’m not going to dissuade you from using Debian – I mean, it’s what I use – but if that was all you were concerned about with Arch, you could probably reinstall it if you were otherwise happy with it and don’t mind doing the reinstall. I can’t help much there, though, as I’ve never installed Arch.

      • mariah@feddit.rocksOP
        link
        fedilink
        arrow-up
        1
        ·
        1 year ago

        I have decided to just unplug the sdd. I have fixed the path issue by adding my user to sudo. Ill stick to debian as im not a hopper. Thanks for helping me

        • tal
          link
          fedilink
          arrow-up
          2
          ·
          1 year ago

          No prob. Hope things go more-smoothly in the future with the machine.