my target is the following:
1) Remove all other partitions/OS including NOOBS, so at the end only boot and data partition from Raspbian remains (and data partition is expanded for using all available card storage)
2) This is urgently needed because of a) switch from SD to microSD (Pi Mod. B --> Pi 2 Mod. B) and b) the data partition of Raspbian has only ~ 5 MB left which makes it nearly impossible to run the Pi (think about package updates etc.).
I´m really suffering on this topic, I already spent more than 12 hours without success! As a past Windows geek I´d simply use Acronis True Image Home which does the job perfectly - but not for Linux based OS.
Therefore I hope to get a little help of all the experts here.
current partition layout on SD card (df -h):
Code: Select all
Dateisystem Größe Benutzt Verf. Verw% Eingehängt auf rootfs 4,9G 4,6G 4,3M 100% / /dev/root 4,9G 4,6G 4,3M 100% / devtmpfs 230M 0 230M 0% /dev tmpfs 47M 304K 47M 1% /run tmpfs 5,0M 0 5,0M 0% /run/lock tmpfs 94M 0 94M 0% /run/shm /dev/mmcblk0p9 60M 15M 45M 25% /boot tmpfs 94M 4,0K 94M 1% /tmp /dev/mmcblk0p6 3,6G 7,4M 3,4G 1% /media/Storage /dev/mmcblk0p5 127M 101M 26M 80% /media/SYSTEM /dev/mmcblk0p3 27M 423K 25M 2% /media/SETTINGS /dev/mmcblk0p7 79M 8,2M 71M 11% /media/BOOT /dev/mmcblk0p8 3,9G 780M 3,0G 21% /media/root /dev/mmcblk0p11 488M 408K 452M 1% /media/data
Code: Select all
=> /dev/mmcblk0p5 delete => /dev/mmcblk0p6 delete => /dev/mmcblk0p7 delete => /dev/mmcblk0p8 delete => /dev/mmcblk0p11 delete => /dev/mmcblk0p9 KEEP (Raspbian!) => /dev/mmcblk0p10 KEEP (Raspbian!)
- a second Pi hardware (Pi 2 mod. b)
- a new microSD card
- a microSD/SD-to-USB card reader which can be used under Linux
- a GParted in a Linux-VM (usable with USB-card reader)
I used next to this topic these following information (effectively useless so far):
http://raspberrypi.stackexchange.com/qu ... ep-raspian
I already tried a few things (different strategy approaches) and spent almost 12 hours on it with my little basic linux knowledge, not successfully so far:
1) DD-backup from within running Raspbian, restore backup on new SD --> filesystem errors when attempting to boot, not repairable
2) Installed Raspbian from scratch to new blank microSD, which gave the partition layout. Restored TAR backup to new sd card --> also gave errors, don´t remind it correctly (was about 2 months ago, no docu)
I now see the following different strategies:
1) Create a duplicate backup of the SD to the new microSD, remove NOOBS and other unwanted OS (on microSD, not backup source), make some small partition adoptions, expand filesystem, ready
2) Create a backup of only needed Raspbian partitions (boot + data), restore it to new microSD, <do some magic to bring Raspbian to boot>, expand filesystem, ready
Question 1: Which one should I prefer? I tend to #2 because backing up all the anyway unwanted data at #1 only takes unnecessary time.
Question 2: What would be the exact, detailed steps for strategy #2?
I see the following actions, please correct me (order, needed commands, ...):
1) power down Pi mod. B
2) remove SD
3) put SD in sd-to-usb card reader, start Linux on PC with mounted card reader
4) Linux: copy relevant partitions (DD? TAR?) to local partition
5) Linux: switch SD to microSD in card reader and restore backup from local partition to new, empty microSD
6) Linux: make some filesystem adaptions to successfully boot Raspbian: e.g. modify /etc/fstab of root partition
7) Linux: Run GParted and check filesystem. expand data filesystem (or better use raspi-config later?)
8) put microSD back to new Pi 2 mod. B
9) power up Pi mod. B and pray for successful boot
What do you think?!?