I am on a NetBSD 10 install now after sabotaging my fully good alpine due to 
constraints of sd card. The memory card from which I want to retrieve data is 
mounted at sd0

$ fsck_ffs /dev/sd0a
/dev/rsd0a[1] Floating point exception (core dumped) fsck_ffs /dev/sd0a

$ mount /dev/sd0a /mnt
mount_ffs: /dev/sd0a on /mnt: incorrect super block
I simply don't get this error. fsck on linux doesn't look like this, it 
corrects irrespectively.

Kindly help.
Thanking you
Sagar Acharya
https://humaaraartha.in



21 Jun 2023, 18:21 by m...@petermann-it.de:

> Hi,
>
> On 21.06.23 14:20, Sagar Acharya wrote:
>
>> Also, linux doesn't have fsck_ffs and debian had support for ufs in ufsutils 
>> a long time ago.
>>
>> I highly recommend that for such cases you have a small standalone source 
>> which can be built for correcting such errors which can perhaps have 
>> disklabel, fsck_ffs, etc. A user can use it locally!
>> Thanking you
>> Sagar Acharya
>> https://humaaraartha.in
>>
>
> For serious repair attempts I would always use the USB installation media of 
> the appropriate NetBSD version as mentioned by Martin. This will first boot 
> into the installer (sysinst), but you can exit it via "Utilities menu" -> 
> "Run /bin/sh". Then you are in a shell and can access the whole toolbox to 
> analyze and clarify the situation.
>
> I would proceed like this (assumption: GPT partition layout):
>
> 1) gpt show <device name>
>
> ...to see if the partition table is still intact, if I got the right device 
> and which partitions are present.
>
> Example: gpt show wd0
>
> 2) dkctl <device name> listwedges
>
> ...to list the wedges assigned to the partitions (system internal mapping of 
> parts of a logical disk)
>
> example: dkctl wd0 listwedges
>
> 3) fsck_ffs -f <wedge device node>
>
> ...forced fsck
>
> Example: fsck_ffs -f /dev/rdk3
>
>
> Kind regards
> Matthias
>

Reply via email to