完全删除mssql linux

时间:2017-07-19 07:10:59

标签: sql-server linux ubuntu server apt-get

有人请帮助:  我的Ubuntu 14服务器有1 GB内存,正在尝试安装,但没有完成。这是一个错误,但现在我不能完全删除它。我尝试安装的任何外部包都失败了,例如 (apt-get install python-requests)我收到此错误

/var/cache/apt/archives/mssql-server_14.0.800.90-2_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

尝试卸载但无法正常工作

root@root: sudo apt-get remove mssql-server

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  libc++1 libjemalloc1 libsss-nss-idmap0
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
  mssql-server
0 upgraded, 0 newly installed, 1 to remove and 172 not upgraded.
184 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
dpkg: error processing package mssql-server (--remove):
 package is in a very bad inconsistent state; you should
 reinstall it before attempting a removal
Errors were encountered while processing:
 mssql-server
E: Sub-process /usr/bin/dpkg returned an error code (1)

我不想丢失我的服务器

1 个答案:

答案 0 :(得分:1)

如果其他外部程序包无法安装,请尝试删除您下载的 /etc/apt/sources.list.d/mssql-server.list 文件以注册Microsoft存储库。运行sudo apt-get update。然后再次尝试安装其他外部软件包,看看是否有问题。这不会删除失败的mssql-server软件包,但它可能会让你回来并运行其他软件包。