[email protected]:~# fdisk -l|more
disk /dev/mmcblk0: 29.7 GiB, 31914983424 bytes, 62333952 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: 0xd9baabc9
Device Boot Start End Sectors Size Id Type
/dev/mmcblk0p1 8192 532480 524289 256M c W95 FAT32 (LBA)
/dev/mmcblk0p2 540672 62333951 61793280 29.5G 83 Linux
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: 100T2B0A-00SM50
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 33553920 bytes
Disklabel type: dos
Disk identifier: 0x0a477230
Device Boot Start End Sectors Size Id Type
/dev/sda1 65535 589814 524280 256M c W95 FAT32 (LBA)
/dev/sda2 589815 67697654 67107840 32G 83 Linux
/dev/sda3 67697655 76086134 8388480 4G 82 Linux swap / Solaris
/dev/sda4 76086135 1953525167 1877439033 895.2G 83 Linux
[email protected]:~# mkfs -t vfat /dev/sda1
mkfs.fat 4.1 (2017-01-24)
[email protected]:~# mkfs -t ext4 /dev/sda2
mke2fs 1.44.5 (15-Dec-2018)
Creating filesystem with 8388480 4k blocks and 2097152 inodes
Filesystem UUID: 7d8f26cd-2e9c-4b5b-84d5-cee147a34be8
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624
Allocating group tables: done
Writing inode tables: done
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done
[email protected]:~# mkfs -t ext4 /dev/sda4
mke2fs 1.44.5 (15-Dec-2018)
Creating filesystem with 234679879 4k blocks and 58671104 inodes
[email protected]:~# mount /dev/sda1 /mnt/boot/
[email protected]:~# rsync -axHAWXS --numeric-ids --info=progress2 /boot /mnt
[email protected]:~# mount /dev/sda2 /mnt/root/
[email protected]:~# rsync -axHAWXS --numeric-ids --info=progress2 / /mnt/root
2,742,993,749 89% 22.39MB/s 0:01:56 (xfr#58784, to-chk=0/72686)
[email protected]:~# mount /dev/sda4 /mnt/home/
[email protected]:~# rsync -axHAWXS --numeric-ids --info=progress2 /home /mnt
[email protected]:/mnt/root/home# rm -rf weberjn/
[email protected]:/mnt/root/home# ll
total 0
[email protected]:/mnt/root/etc# blkid
/dev/mmcblk0p1: LABEL_FATBOOT="boot" LABEL="boot" UUID="F661-303B" TYPE="vfat" PARTUUID="d9baabc9-01"
/dev/mmcblk0p2: LABEL="rootfs" UUID="8d008fde-f12a-47f7-8519-197ea707d3d4" TYPE="ext4" PARTUUID="d9baabc9-02"
/dev/mmcblk0: PTUUID="d9baabc9" PTTYPE="dos"
/dev/sda1: SEC_TYPE="msdos" UUID="BA86-457C" TYPE="vfat" PARTUUID="0a477230-01"
/dev/sda2: UUID="7d8f26cd-2e9c-4b5b-84d5-cee147a34be8" TYPE="ext4" PARTUUID="0a477230-02"
/dev/sda3: PARTUUID="0a477230-03"
/dev/sda4: UUID="901daf85-0613-4908-9276-c33b0483a30a" TYPE="ext4" PARTUUID="0a477230-04"
[email protected]:~# cat /mnt/root/etc/fstab
proc /proc proc defaults 0 0
PARTUUID=d9baabc9-01 /boot vfat defaults 0 2
PARTUUID=0a477230-02 / ext4 defaults,noatime 0 1
PARTUUID=0a477230-04 /home ext4 defaults,noatime 0 1
[email protected]:/boot# cat cmdline.txt
dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=0a477230-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait
[email protected]:~# reboot
[email protected]:~ $ df -hT
Filesystem Type Size Used Avail Use% Mounted on
/dev/root ext4 32G 2.6G 28G 9% /
devtmpfs devtmpfs 1.8G 0 1.8G 0% /dev
tmpfs tmpfs 2.0G 0 2.0G 0% /dev/shm
tmpfs tmpfs 2.0G 8.5M 1.9G 1% /run
tmpfs tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs tmpfs 2.0G 0 2.0G 0% /sys/fs/cgroup
tmpfs tmpfs 2.0G 0 2.0G 0% /tmp
/dev/mmcblk0p1 vfat 253M 40M 213M 16% /boot
/dev/sda4 ext4 881G 153M 836G 1% /home
tmpfs tmpfs 391M 0 391M 0% /run/user/1001