Monday, April 29, 2024
 Popular · Latest · Hot · Upcoming
29
rated 0 times [  29] [ 0]  / answers: 1 / hits: 35909  / 2 Years ago, wed, july 27, 2022, 1:09:10

I just installed MySQL-server and all of its dependencies, among other necessities.
But when it went to configure mysql-server it failed to do so, and spit out an error. Which error is not relevant here as I managed to locate the problem as a dependency issue between mysql-server and mysql-common. Mysql-common needs to be removed.



But when I go to



apt-get purge remove mysql-common 


It automatically wants to remove everything in association with it as well, including all mysql dependencies, even apache2 and php5..



So what argument needs to be added to apt-get command to uninstall ONLY ONE package, yet leave all others intact.


More From » apt

 Answers
7

apt-get won't let you do that, since it's a potentially dangerous step for a package management system to allow.



As long as you are aware that there may be consequences, use dpkg with the --remove option to do it. For example:



sudo dpkg --remove mysql-common



Note: On my 12.04 system with apache2, php5, mysql-server installed separately, using apt-get to remove mysql-common DOES NOT want to remove apache2 or php5.




From insomnia's comment: If you need to override the dependency system's decision you can (with great care and making sure you know what you are doing) use an additional --force-depends.



sudo dpkg --remove --force-depends mysql-common

[#36261] Thursday, July 28, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
shionnky

Total Points: 276
Total Questions: 104
Total Answers: 108

Location: Montenegro
Member since Thu, Jun 16, 2022
2 Years ago
shionnky questions
;