Désinstaller nginx sur centos

Logo Nginx

Petite page de blog après un long moment d’absence sur comment désinstaller nginx sur un centos 7

Désinstallation du package nginx :

# yum remove nginx
Loaded plugins: fastestmirror
Resolving Dependencies
–> Running transaction check
—> Package nginx.x86_64 1:1.16.1-1.el7 will be erased
–> Processing Dependency: nginx for package: 1:nginx-mod-http-xslt-filter-1.16.1-1.el7.x86_64
–> Processing Dependency: nginx for package: 1:nginx-mod-http-perl-1.16.1-1.el7.x86_64
–> Processing Dependency: nginx for package: 1:nginx-mod-stream-1.16.1-1.el7.x86_64
–> Processing Dependency: nginx for package: 1:nginx-mod-mail-1.16.1-1.el7.x86_64
–> Processing Dependency: nginx for package: 1:nginx-mod-http-image-filter-1.16.1-1.el7.x86_64
–> Running transaction check
—> Package nginx-mod-http-image-filter.x86_64 1:1.16.1-1.el7 will be erased
–> Processing Dependency: nginx-mod-http-image-filter = 1:1.16.1-1.el7 for package: 1:nginx-all-modules-1.16.1-1.el7.noarch
—> Package nginx-mod-http-perl.x86_64 1:1.16.1-1.el7 will be erased
—> Package nginx-mod-http-xslt-filter.x86_64 1:1.16.1-1.el7 will be erased
—> Package nginx-mod-mail.x86_64 1:1.16.1-1.el7 will be erased
—> Package nginx-mod-stream.x86_64 1:1.16.1-1.el7 will be erased
–> Running transaction check
—> Package nginx-all-modules.noarch 1:1.16.1-1.el7 will be erased
–> Finished Dependency Resolution

Dependencies Resolved

=========================================================================================================================
Package Arch Version Repository Size
=========================================================================================================================
Removing:
nginx x86_64 1:1.16.1-1.el7 @epel 1.6 M
Removing for dependencies:
nginx-all-modules noarch 1:1.16.1-1.el7 @epel 0.0
nginx-mod-http-image-filter x86_64 1:1.16.1-1.el7 @epel 24 k
nginx-mod-http-perl x86_64 1:1.16.1-1.el7 @epel 54 k
nginx-mod-http-xslt-filter x86_64 1:1.16.1-1.el7 @epel 24 k
nginx-mod-mail x86_64 1:1.16.1-1.el7 @epel 99 k
nginx-mod-stream x86_64 1:1.16.1-1.el7 @epel 171 k

Transaction Summary
=========================================================================================================================
Remove 1 Package (+6 Dependent packages)

Installed size: 2.0 M
Is this ok [y/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Erasing : 1:nginx-mod-http-image-filter-1.16.1-1.el7.x86_64 1/7
Erasing : 1:nginx-mod-http-perl-1.16.1-1.el7.x86_64 2/7
Erasing : 1:nginx-mod-http-xslt-filter-1.16.1-1.el7.x86_64 3/7
Erasing : 1:nginx-mod-mail-1.16.1-1.el7.x86_64 4/7
Erasing : 1:nginx-all-modules-1.16.1-1.el7.noarch 5/7
Erasing : 1:nginx-mod-stream-1.16.1-1.el7.x86_64 6/7
Erasing : 1:nginx-1.16.1-1.el7.x86_64 7/7
warning: /etc/nginx/nginx.conf saved as /etc/nginx/nginx.conf.rpmsave
Verifying : 1:nginx-mod-stream-1.16.1-1.el7.x86_64 1/7
Verifying : 1:nginx-all-modules-1.16.1-1.el7.noarch 2/7
Verifying : 1:nginx-1.16.1-1.el7.x86_64 3/7
Verifying : 1:nginx-mod-mail-1.16.1-1.el7.x86_64 4/7
Verifying : 1:nginx-mod-http-perl-1.16.1-1.el7.x86_64 5/7
Verifying : 1:nginx-mod-http-xslt-filter-1.16.1-1.el7.x86_64 6/7
Verifying : 1:nginx-mod-http-image-filter-1.16.1-1.el7.x86_64 7/7

Removed:
nginx.x86_64 1:1.16.1-1.el7

Dependency Removed:
nginx-all-modules.noarch 1:1.16.1-1.el7 nginx-mod-http-image-filter.x86_64 1:1.16.1-1.el7
nginx-mod-http-perl.x86_64 1:1.16.1-1.el7 nginx-mod-http-xslt-filter.x86_64 1:1.16.1-1.el7
nginx-mod-mail.x86_64 1:1.16.1-1.el7 nginx-mod-stream.x86_64 1:1.16.1-1.el7

Complete!

Suppression des dossiers de configuration et des logs:

rm -R /etc/nginx
rm: descend into directory ‘/etc/nginx’? y
rm: remove directory ‘/etc/nginx/default.d’? y
rm: remove regular file ‘/etc/nginx/nginx.conf.rpmsave’? y
rm: descend into directory ‘/etc/nginx/conf.d’? y
rm: remove regular empty file ‘/etc/nginx/conf.d/adminlinux.fr’? y
rm: remove directory ‘/etc/nginx/conf.d’? y
rm: remove directory ‘/etc/nginx’? y

rm -R /var/log/nginx
rm: descend into directory ‘/var/log/nginx’? y
rm: remove regular file ‘/var/log/nginx/access.log’? y
rm: remove regular file ‘/var/log/nginx/error.log’? y
rm: remove directory ‘/var/log/nginx’? yy

Voilà c’est tout… pour le moment.

Si vous voulez en savoir plus sur nginx n’hésitez pas à aller voir leur documentation ou mes autres articles sur le sujet

Laisser un commentaire

Votre adresse de messagerie ne sera pas publiée. Les champs obligatoires sont indiqués avec *