温馨提示×

ubuntu版本如何备份软件

小新
250
2021-02-01 13:19:00
栏目: 智能运维

ubuntu版本如何备份软件

ubuntu版本备份软件的方法:

1.不要删除/var/cache/apt/archives目录,执行以下命令,生成当前安装软件的内容列表,如:

dpkg -–get-selections | grep -v deinstall >

ubuntu.files

2.把ubuntu.files和archives目录中的所有内容都cp到别的机器对应的目录。

3.重装完成后,配置sources.list,执行如下命令:

sudo apt-get update

sudo apt-get dist-upgrade

dpkg -–set-selections <

ubuntu.files

sudo dselect

4、根据提示按下“i”,然后全部按回车即可。

0