Move 150+ scripts from root and scripts/ into client/project directories: - clients/dataforth/scripts/ (110 files: AD2, sync, SSH, DB, DOS scripts) - clients/bg-builders/scripts/ (14 files: Lesley mgmt, Exchange, termination) - clients/internal-infrastructure/scripts/ (10 files: GDAP, Gitea, backups) - projects/msp-tools/scripts/ (9 files: CIPP, MSP onboarding, Datto) - projects/gururmm-agent/scripts/ (3 files: API test, JWT, record counts) - clients/glaztech/scripts/ (1 file: CentraStage removal) Also reorganized: - VPN scripts → infrastructure/vpn-configs/ - Retrieved API/JS files → api/ - Forum posts → projects/community-forum/forum-posts/ - SSH docs → clients/internal-infrastructure/docs/ - NWTOC/CTONW docs → projects/wrightstown-smarthome/docs/ - ACG website files → projects/internal/acg-website-2025/ - Dataforth docs → clients/dataforth/docs/ - schema-retrieved.sql → docs/database/ Deleted 24 tmp_*.ps1 one-off debug scripts (preserved in git history). Root reduced from 220+ files to 62 items (docs + directories only). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2.7 KiB
2.7 KiB
Guide: Repurpose Old Windows BitLocker Drive as /home on Arch Linux
Environment
- OS: CachyOS (Arch-based) with btrfs root
- Existing /home: btrfs subvolume (@home) on OS drive
- Secondary drive: 954GB NVMe with Windows BitLocker partition
Goal
Wipe the old Windows drive and mount it as /home on ext4, giving a dedicated large partition for user data separate from the OS.
Steps
Step 1: Identify the Drive
lsblk -o NAME,SIZE,TYPE,FSTYPE,MOUNTPOINT,MODEL
Output:
nvme0n1 953.9G disk SKHynix_HFS001TEJ9X115N
├─nvme0n1p1 4G part vfat /boot
└─nvme0n1p2 949.9G part btrfs /root <-- OS drive
nvme1n1 953.9G disk SKHynix_HFS001TEJ9X115N
├─nvme1n1p1 16M part <-- Windows MSR
└─nvme1n1p2 953.9G part BitLocker <-- Target drive
Step 2: Wipe and Partition
# Wipe all filesystem signatures
sudo wipefs -a /dev/nvme1n1
# Create GPT table with single ext4 partition
sudo parted /dev/nvme1n1 --script mklabel gpt mkpart primary ext4 0% 100%
# Format with label
sudo mkfs.ext4 -L home /dev/nvme1n1p1
Step 3: Copy Existing /home
# Mount new partition temporarily
sudo mount /dev/nvme1n1p1 /mnt
# Copy everything preserving permissions, ACLs, and extended attributes
sudo rsync -aAXv /home/ /mnt/
# Verify
ls -la /mnt/yourusername/
du -sh /mnt/yourusername/
# Unmount
sudo umount /mnt
Step 4: Get UUID
sudo blkid /dev/nvme1n1p1
# UUID="4143f922-455f-4154-8f87-6df123548916" TYPE="ext4"
Step 5: Update /etc/fstab
Replace the existing /home mount entry. If coming from a btrfs subvolume setup:
# BEFORE (btrfs subvolume):
# UUID=8a8b1d34-... /home btrfs subvol=/@home,defaults,noatime,compress=zstd:1 0 0
# AFTER (ext4 on new drive):
UUID=4143f922-455f-4154-8f87-6df123548916 /home ext4 defaults,noatime 0 2
Step 6: Reboot
sudo reboot
Step 7: Verify After Reboot
df -h /home
# Should show /dev/nvme1n1p1 mounted at /home with ~938GB available
mount | grep home
# /dev/nvme1n1p1 on /home type ext4 (rw,noatime)
Notes
- The old btrfs
@homesubvolume remains on the OS drive as an automatic backup. You can delete it later withsudo btrfs subvolume delete /path/to/@homeif you need the space. - ext4 was chosen over btrfs for the /home drive for simplicity and maximum compatibility. If you prefer btrfs features (snapshots, compression), use
mkfs.btrfsinstead. - The
noatimemount option reduces unnecessary writes by not updating file access timestamps. - Pass
0 2in fstab (not0 0) so fsck runs on boot if needed, but after the root filesystem (which is0 1).