apache httpd如何查看我安装了哪些模块,启用了哪些模块

Life is short , play more!
本文来自lihao's Blog,转载请注明。

apache httpd如何查看我安装了哪些模块,启用了哪些模块

通常我们知道如何当前启动的服务加载/启用了哪些模块,但是我想知道我安装的所有的模块(而不是我当前已经启用加载的模块),并启用一些未加载的模块如何处理呢?

1. 首先查询当前httpd(apache2) 加载了哪些模块

httpd -M 或者 apache2ctl -M

Loaded Modules:
 core_module (static)
 mpm_prefork_module (static)
 http_module (static)
 so_module (static)
 auth_basic_module (shared)
 auth_digest_module (shared)
 authn_file_module (shared)
 authn_alias_module (shared)
 authn_anon_module (shared)
 authn_dbm_module (shared)
 authn_default_module (shared)
 authz_host_module (shared)
 authz_user_module (shared)
 authz_owner_module (shared)
 authz_groupfile_module (shared)
 authz_dbm_module (shared)
 authz_default_module (shared)
 ldap_module (shared)
 authnz_ldap_module (shared)
 include_module (shared)
 log_config_module (shared)
 logio_module (shared)
 env_module (shared)
 ext_filter_module (shared)
 mime_magic_module (shared)
 expires_module (shared)
 deflate_module (shared)
 headers_module (shared)
 usertrack_module (shared)
 setenvif_module (shared)
 mime_module (shared)
 dav_module (shared)
 status_module (shared)
 autoindex_module (shared)
 info_module (shared)
 dav_fs_module (shared)
 vhost_alias_module (shared)
 negotiation_module (shared)
 dir_module (shared)
 actions_module (shared)
 speling_module (shared)
 userdir_module (shared)
 alias_module (shared)
 substitute_module (shared)
 rewrite_module (shared)
 proxy_module (shared)
 proxy_balancer_module (shared)
 proxy_ftp_module (shared)
 proxy_http_module (shared)
 proxy_ajp_module (shared)
 proxy_connect_module (shared)
 cache_module (shared)
 suexec_module (shared)
 disk_cache_module (shared)
 cgi_module (shared)
 version_module (shared)
 php5_module (shared)
Syntax OK

 

2. 如果我想知道我安装了哪些模块呢

ls /usr/lib64/httpd/modules/

lib64 是你安装的httpd的操作系统位数。

httpd在centos和redhat中为httpd, ubuntu中为apache2

如下是我在服务器上的httpd安装的所有modules, 安装了并不代表着启用。 

libphp5.so mod_authn_file.so mod_cgi.so mod_headers.so mod_proxy_balancer.so mod_suexec.so
mod_actions.so mod_authnz_ldap.so mod_dav_fs.so mod_ident.so mod_proxy_connect.so mod_thumbnail.so
mod_alias.so mod_authz_dbm.so mod_dav.so mod_include.so mod_proxy_ftp.so mod_unique_id.so
mod_asis.so mod_authz_default.so mod_dbd.so mod_info.so mod_proxy_http.so mod_userdir.so
mod_audioconvert.so mod_authz_groupfile.so mod_deflate.so mod_ldap.so mod_proxy_scgi.so mod_usertrack.so
mod_auth_basic.so mod_authz_host.so mod_dir.so mod_log_config.so mod_proxy.so mod_version.so
mod_auth_digest.so mod_authz_owner.so mod_disk_cache.so mod_log_forensic.so mod_reqtimeout.so mod_vhost_alias.so
mod_authn_alias.so mod_authz_user.so mod_dumpio.so mod_logio.so mod_rewrite.so
mod_authn_anon.so mod_autoindex.so mod_env.so mod_mime_magic.so mod_setenvif.so
mod_authn_dbd.so mod_cache.so mod_expires.so mod_mime.so mod_speling.so
mod_authn_dbm.so mod_cern_meta.so mod_ext_filter.so mod_negotiation.so mod_status.so
mod_authn_default.so mod_cgid.so mod_filter.so mod_proxy_ajp.so mod_substitute.so

 


发表评论

电子邮件地址不会被公开。 必填项已用*标注