当前位置:网站首页>Getting Started with Raspberry Pi (5) System Backup
Getting Started with Raspberry Pi (5) System Backup
2022-08-11 03:19:00 【julay】
目录
一、全卡备份
1.win32DiskImager
新建空img文件
将TF卡插入电脑,可以看到有两个分区,What we want to back up isroot区而不是boot区
So the image file is selected1.img,设备选择G:
Then click Read again
2.SD Card Copier
将TF卡插入树莓派,可看到
Choose where to copy from and where to copy,点击start
等待复制完成
3.终端命令
查询路径
lsblk
备份命令
sudo dd if=/dev/mmcblk0 of=/dev/sda #if:从哪复制
#of:复制到哪
sudo ps -ef | grep dd #View the new terminal interfaceddCommand process number
sudo watch-n 3 kill_USR1 pid #pid:查到的进程号
#发送USR1(用户自定义信号),查看copy进度
#结合watchcan be refreshed in real time
二、rpi-backup压缩备份
备份的是boot区和rootThe used part of the area
1.Check the remaining space of the current system card
df -h
2.备份
(1)备份文件大小为:已用空间1.2
(2)If the remaining space is sufficient, it will be directly stored on the system card,If not enough, save to newSD卡上
(3)Backup to an external device if needed,The device must be mounted to/media,不要挂载到/mnt,Because the created image will be mounted to /mnt进行操作*****
git clone https://github.com/nanhantianyi/rpi-backup.git && cd rpi-backup
sudo bash back.sh xxx.img (xxx.imgis the backup file name,自行修改)
3.扩容
Execute after the system is restored
sudo bash resize.sh
扩容root分区,Raspberry Pi can also be usedraspi-config
sudo raspi-config
选择"Advanced Options"回车
然后选择"A1 Expand Filesystem Ensures that all of ….",回车
Ask to modifyroot分区,直接回车
to the first page,按"Tab"键,选择"Finish",回车
询问是否重启,选择重启
重启完后,输入"df -h",会发现rootThe partition has been expanded successfully
三、参考资料
1.https://blog.csdn.net/lzjsqn/article/details/72058293
2.4.14.114-OPENFANS+20190602-v8 64位debain系统 /usr/sbin/resize.root 脚本
3.https://www.bilibili.com/video/BV1fL411u71E?share_source=copy_web
边栏推荐
- 【idea 报错】 无效的目标发行版:17 的解决参考
- 【Pdf自动生成书签】
- 多商户商城系统功能拆解26讲-平台端分销设置
- Typescript study notes | Byte Youth Training Notes
- LeetCode热题(12.买卖股票的最佳时机)
- The ifconfig compared with IP command
- 轮转数组问题:如何实现数组“整体逆序,内部有序”?“三步转换法”妙转数组
- IDE编译报错:Dangling metacharacter
- Environment configuration of ESP32 (arduino arduino2.0 VScode platform which is easy to use?)
- [DB operation management/development solution] Shanghai Daoning provides you with an integrated development tool to improve the convenience of work - Orange
猜你喜欢
随机推荐
MongoDB 基础了解(二)
(CVPR - 2017) in depth and potential body learning context awareness feature for pedestrian recognition
Docker 链接sqlserver时出现en-us is an invalid culture错误解决方案
"How to kick a bad habit to read notes?
leetcode:358. K 距离间隔重排字符串
Multi-merchant mall system function disassembly 26 lectures - platform-side distribution settings
什么是三方支付?
(CVPR-2017)在身体和潜在部位学习深度上下文感知特征以进行行人重识别
Realization of vending machine function based on FPGA state machine
二叉树相关代码题【较全】C语言
JS-DOM element object
程序化交易与主观交易对盈利曲线的影响!
[BX]和loop
Briefly, talk about the use of @Transactional in the project
代码 Revert 后再次 Merge 会丢失的问题,已解决
【Pdf自动生成书签】
(Nips-2015)空间变换器网络
[DB operation management/development solution] Shanghai Daoning provides you with an integrated development tool to improve the convenience of work - Orange
添加用户报错useradd: cannot open /etc/passwd
互换性与测量技术——表面粗糙度选取和标注方法