当前位置:网站首页>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
边栏推荐
- AI+医疗:使用神经网络进行医学影像识别分析
- Detailed explanation of new features of ES advanced array function syntax
- 二叉树相关代码题【较全】C语言
- js中的this问题
- 轮转数组问题:如何实现数组“整体逆序,内部有序”?“三步转换法”妙转数组
- 互换性与测量技术——表面粗糙度选取和标注方法
- 【DB运营管理/开发解决方案】上海道宁为您提供提高工作便利性的集成开发工具——Orange
- AI+Medical: Using Neural Networks for Medical Image Recognition and Analysis
- Unity2D animation (1) introduction to Unity scheme - animation system composition and the function of use
- Logstash日志数据写入异常排查问题总结
猜你喜欢

阿里低代码框架 lowcode-engine 之自定义物料篇

The problem that Merge will be lost again after code Revert has been solved

A Practical Arrangement of Map GIS Development Matters (Part 1)

alibaba数据同步组件canal的实践整理

DOM-DOM树,一个DOM树有三种类型的节点

多商户商城系统功能拆解26讲-平台端分销设置

二叉树相关代码题【较全】C语言

解决vim与外界的复制粘贴(不用安装插件)

【idea 报错】 无效的目标发行版:17 的解决参考

DNS分离解析和智能解析
随机推荐
JS-DOM element object
Traversal of DOM tree-----modify styles, select elements, create and delete nodes
OpenCV founder: Open source must not be completely free!
面试常考的7种排序算法
Meaning of df and df -lh
分布式和集群的区别和联系
大马驮2石粮食,中马驮1石粮食,两头小马驮一石粮食,要用100匹马,驮100石粮食,如何分配?
[Pdf generated automatically bookmarks]
Detailed explanation of new features of ES advanced function syntax
"How to kick a bad habit to read notes?
Talk about the understanding of RPC
轮转数组问题:如何实现数组“整体逆序,内部有序”?“三步转换法”妙转数组
输入起始位置,终止位置截取链表
Idea (preferred) cherry-pick operation
Add support for Textbundle
CSDN blog replacement skin
Economic Misunderstandings in the Crypto World: Is Cash a Savings?Scarcity creates value?
SQL 开发的十个高级概念
E-commerce project - mall time-limited seckill function system
【Pdf自动生成书签】