Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

How to re-format and remount and redo LVM volume on SSD

Featured Replies

I followed a guide to install a system on my Rockpro64 but something happened where I had to reinstall it. However, when I reflashed the ubuntu server image and tried re-installing the system it got an error pertaining to one of my disk volumes. So I'm wondering how to re-format and remount and redo the LVM volume my SSD.

Any help or tips would be greatly appreciated!

  • Author

I do not have anything important so yes I can start from scratch no problem. Sorry, so if my SSD is at /dev/nvme0n1 how do I use dd with it?

You could do something like dd if=/dev/zero of=/dev/nvme0 bs=512 count=1 where nvme0 should be the device itself and not the first partition. You can verify this beforehand with fdisk -l. After that you may have to restart the board to make the "new" partition table recognized.

 

  • Author

Okay I will try that thanks, but just to clarify what are you referring to that I can verify beforehand? Because when I do 'fdisk -l' I see that it says nvme0n1 not nvme0.

Alright though I will keep in mind that I may have to restart.

  • Author

ah okay i see, well when i do 'dd if=/dev/zero of=/dev/nvme0n1 bs=512 count=1' i get:

 

1+0 records in

1+0 records out

512 bytes copied, 0.00090138 s, 568 kb/s

does that look right, how can i check i that i wiped it?

  • Author

i see the disk there at the top of the output but not sure what to look for as it seems like there is still space on it, i see:

Disk /dev/nvme0n1: 953GB, 1024209543168 bytes, 2000409264 sectors
Disk model: Sabrent
Units: sectors of 1 * 512 = 512 bytes

Sector size (logical/physical): 512 bytes / 512 bytes

I/O size (minimum/optimal): 512 bytes / 512 bytes

  • Author

Disk /dev/nvme0n1: 953.89 GiB, 1024209543168 bytes, 2000409264 sectors
Disk model: Sabrent                                 
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes


Disk /dev/mtdblock0: 16 MiB, 16777216 bytes, 32768 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes


Disk /dev/mmcblk2: 14.46 GiB, 15518924800 bytes, 30310400 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x0ca53e42

Device         Boot Start      End  Sectors  Size Id Type
/dev/mmcblk2p1      32768 30007295 29974528 14.3G 83 Linux


Disk /dev/zram0: 50 MiB, 52428800 bytes, 12800 sectors
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/zram1: 1 GiB, 1073741824 bytes, 262144 sectors
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/mapper/rockpro64-project: 500 GiB, 536870912000 bytes, 1048576000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

  • Author

specifically how to remount, because I tried installing the system again, but I get a mount error:

rockpro64 systemd[1]: var-lib-bitcoind.ount: Job var-lib-bitcoind.mount/start failed with result 'dependency'

Edited by kkdao

  • Author

I did that haha, but I still get errors related to the systemd.service and the mount point with the drive:( so I need to figure out how to completely start from scratch and go back to default settings on the board.

  • Author

I've actually tried re-flashing the eMMC with Etcher (which is what I'm using instead of SD card) with a new image of the Ubuntu OS, but I still get errors when trying to run the system again. After looking deeper into the errors I have figured out there is an issue with my drive still being mounted somehow. So when I do 'e2fsck -f /dev/nvme0n1' or 'fsck.ext4 /dev/nvme0n1' I get back:

ext2fs_open2: bad magic number in super-block
e2fsck: Superblock invalid, trying backup blocks...
e2fsck: Bad magic number in super-block while trying to open /dev/nvme0n1

 

The superblock could not be read or does not describe a valid ext2/ext3/ext4 filesystem. If the device is valid and it really contains an exy2/ext3/ext4 filesystem (and not swap or ufs or something else), then the superblock is corrupt, and you might try running e2fsck with an alternate superblock:

e2fsck -b 8193 <device>

or

e2fsck -b 32768 <device>

 

but when I try running e2fsck with the suggested alt superblock i get:
/dev/nvme0n1 contains a LVM2_member file system

I did all this in root FYI (sudo -) after SSHing into my system.

 

Another thing I probably should've mentioned at the beginning was WHY this all occurred in the first place and it's because I accidentally unplugged the power cord from the outlet while the system was on and running. So that's why the mount point is somehow messed up seemingly.

Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.