操作系统升级期间丢失(和DDEV数据库)的Docker量
大约一个月前,我使用DDEV创建了一个Drupal 9实例。快速而简单!在Linux笔记本电脑上,我花了大约8个小时的时间来定制内容类型和视图。
上周,我升级了流行音乐! OS(类似于Ubuntu)笔记本电脑,升级后不得不重新安装DDEV。当我回到本地目录并运行ddev start
...时,我受到了干净的Drupal 9安装屏幕的欢迎。我所有的配置和内容似乎都消失了吗?
有哪些步骤可以解决丢失的状态信息,例如数据库或文件系统?是否有机会在某个地方找到我以前的更改?
About a month ago I created a Drupal 9 instance using DDEV. It was fast and easy! I spent about 8 hours over several user sessions on my Linux laptop customizing my content types and views.
Last week I upgraded my Pop! OS (Ubuntu-like) laptop, and had to re-install ddev after the upgrade. When I went back into my local directory and ran ddev start
... I was greeted with a clean Drupal 9 installation screen. All of my configuration and content seems to be gone?
What steps are there to troubleshoot lost state information, such as a database or filesystem? Are there any chances of finding my previous changes inside the /.ddev/ folder somewhere?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您显然会丢失Docker量(这是保留数据库的位置)。我敢肯定,有一种方法可以返回您的备份并找到它们(它们在/var/lib/docker/卷中),但是这里的真正观点是保留数据库备份。使用
ddev快照
或ddev导出db
不时将这些备份保留。我在每个项目中保留一个.tarballs目录,其中我具有基本的
ddev导出db
输出和文件转储。效果很好。请注意,在正常的操作系统升级后,您不必重新安装DDEV,也不必重新安装Docker。我想正是对Docker的重新安装使您陷入困境。
更多想法:
You apparently lost your Docker volumes (which is where the database is kept). I'm sure there's a way to go back to your backups and find them (they were in /var/lib/docker/volumes), but the real point here is to keep database backups. Use
ddev snapshot
orddev export-db
from time to time and keep those backups around.I keep a .tarballs directory in each project where I have a basic
ddev export-db
output and a files dump. It's worked well.Note that you wouldn't have to reinstall DDEV after a normal OS upgrade, nor would you have to reinstall Docker. I imagine it's the reinstalling of Docker that got you in trouble.
More ideas: