Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Creating the Backup
- 1. Download 'win32diskimager'
- 2. install it
- 3. run it
- In the imager:
- 1. click the folder icon
- 2. select a folder to create the image in
- 3. type an image name
- Then:
- 1. click the 'Read' button
- Be patient this will take a good while depending on SD card size and speed.
- ## Shrinking Image size with PiShsrink
- ### Installation
- #### Windows preperation
- 1. Install WLS 2 on windows using this command:
- ```powershell
- wls --install
- ```
- 2. Go to the microsoft store and install 'Ubuntu' and 'windows terminal'
- 3. Launch ubuntu and follow the prompts
- 4. it will ask you to restart do it
- 5. Upon restart you should see a terminal pop up that installs ubuntu (if not start ubuntu app or open an ubuntu shell in 'windows teminal' by right clicking the new tab
- #### Pishrink
- 1. Go to 'https://github.com/Drewsif/PiShrink' and donwload the script
- 2. Extract it
- 3. Copy paste the contents to the image directory (the folder you saved the image file in)
- 4. Open an ubuntu shell using the windows terminal
- 5. type the following commands
- ```bash
- sudo apt update
- sudo apt install parted
- ```
- #### Usage
- 1. Launch a new ubuntu shell
- 2. cd to the directory of your image and pishrink files (my case external drive e:)
- 3. Type the following commands
- ```bash
- cd ./
- cd mnt
- cd e/ #your drive letter
- ls #view the folders
- cd 'Mainsail sd clone' #your image containing folder
- ```
- Your directory should now be:
- ```bash
- user@desktop-a35sdf:/mnt/e/mainsail sd clone
- ```
- 4. Now run this command:
- ```bash
- sudo ./ pishrink.sh image_file_name.img
- ```
- Let the script do its thing and don't close the terminal, restart the computer or remove the drive
- When done you should see a message stating the following:
- `pishrink.sh: Shrunk image_file_name.img fom 60G to 7.6G`
- ## Restoration
- 1. Get a fresh SD card that's the same capacity or more
- 2. Format it to fat32 (for Nintendo switch use guiformat tool)
- 3. Boot win32diskimager
- 4. Select the image file
- 5. Select the new SD card drive
- 6. Click write
- Be patient.
- # Do not remove the SD when imager or script is running
- # Make sure the PC is plugged in before you attempt this and charged above 70%
- # Do not format the SD when the system asks
- # Do not power off the PC
- ==Source:== https://www.youtube.com/watch?v=77vOeofG0Kg
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement