4

After successfully installation of Apache2(2.4.4) i tried to start https server but i am getting below error

bimlesh@server:/usr/local/apache2/bin$ ./apachectl start
httpd: Syntax error on line 71 of /usr/local/apache2/conf/httpd.conf: Cannot load modules/mod_authn_core.so into server: /usr/local/apache2/modules/mod_authn_core.so: cannot open shared object file: No such file or directory
bimlesh@server:/usr/local/apache2/bin$ 

I looked at /usr/local/apache2/modules/ and really those .so files are not available. Can anyone please help that how to get rid off.

if i look at /usr/local/apache2/modules/ folder then i see:(no .so files available)

bimlesh@server:/usr/local/apache2/bin$ ls ../modules/
httpd.exp             mod_authn_file.a        mod_cache_disk.a   mod_file_cache.a            mod_logio.la           mod_ratelimit.a        mod_socache_dbm.la
mod_access_compat.a   mod_authn_file.la       mod_cache_disk.la  mod_file_cache.la           mod_mime.a             mod_ratelimit.la       mod_socache_memcache.a
mod_access_compat.la  mod_authn_socache.a     mod_cache.la       mod_filter.a                mod_mime.la            mod_remoteip.a         mod_socache_memcache.la
mod_actions.a         mod_authn_socache.la    mod_cgid.a         mod_filter.la               mod_negotiation.a      mod_remoteip.la        mod_socache_shmcb.a
mod_actions.la        mod_authz_core.a        mod_cgid.la        mod_headers.a               mod_negotiation.la     mod_reqtimeout.a       mod_socache_shmcb.la
mod_alias.a           mod_authz_core.la       mod_dav.a          mod_headers.la              mod_proxy.a            mod_reqtimeout.la      mod_speling.a
mod_alias.la          mod_authz_dbd.a         mod_dav_fs.a       mod_include.a               mod_proxy_ajp.a        mod_request.a          mod_speling.la
mod_allowmethods.a    mod_authz_dbd.la        mod_dav_fs.la      mod_include.la              mod_proxy_ajp.la       mod_request.la         mod_status.a
mod_allowmethods.la   mod_authz_dbm.a         mod_dav.la         mod_info.a                  mod_proxy_balancer.a   mod_rewrite.a          mod_status.la
mod_auth_basic.a      mod_authz_dbm.la        mod_dbd.a          mod_info.la                 mod_proxy_balancer.la  mod_rewrite.la         mod_substitute.a
mod_auth_basic.la     mod_authz_groupfile.a   mod_dbd.la         mod_lbmethod_bybusyness.a   mod_proxy_connect.a    mod_sed.a              mod_substitute.la
mod_auth_digest.a     mod_authz_groupfile.la  mod_deflate.a      mod_lbmethod_bybusyness.la  mod_proxy_connect.la   mod_sed.la             mod_unique_id.a
mod_auth_digest.la    mod_authz_host.a        mod_deflate.la     mod_lbmethod_byrequests.a   mod_proxy_express.a    mod_session.a          mod_unique_id.la
mod_auth_form.a       mod_authz_host.la       mod_dir.a          mod_lbmethod_byrequests.la  mod_proxy_express.la   mod_session_cookie.a   mod_unixd.a
mod_auth_form.la      mod_authz_owner.a       mod_dir.la         mod_lbmethod_bytraffic.a    mod_proxy_fcgi.a       mod_session_cookie.la  mod_unixd.la
mod_authn_anon.a      mod_authz_owner.la      mod_dumpio.a       mod_lbmethod_bytraffic.la   mod_proxy_fcgi.la      mod_session_dbd.a      mod_userdir.a
mod_authn_anon.la     mod_authz_user.a        mod_dumpio.la      mod_lbmethod_heartbeat.a    mod_proxy_ftp.a        mod_session_dbd.la     mod_userdir.la
mod_authn_core.a      mod_authz_user.la       mod_env.a          mod_lbmethod_heartbeat.la   mod_proxy_ftp.la       mod_session.la         mod_version.a
mod_authn_core.la     mod_autoindex.a         mod_env.la         mod_log_config.a            mod_proxy_http.a       mod_setenvif.a         mod_version.la
mod_authn_dbd.a       mod_autoindex.la        mod_expires.a      mod_log_config.la           mod_proxy_http.la      mod_setenvif.la        mod_vhost_alias.a
mod_authn_dbd.la      mod_buffer.a            mod_expires.la     mod_log_debug.a             mod_proxy.la           mod_slotmem_shm.a      mod_vhost_alias.la
mod_authn_dbm.a       mod_buffer.la           mod_ext_filter.a   mod_log_debug.la            mod_proxy_scgi.a       mod_slotmem_shm.la
mod_authn_dbm.la      mod_cache.a             mod_ext_filter.la  mod_logio.a                 mod_proxy_scgi.la      mod_socache_dbm.a
bimlesh@server:/usr/local/apache2/bin$ 
bimlesh sharma
  • 181
  • 1
  • 10

1 Answers1

2

Run

find / -type f -name mod_authn_core.so

or install updatedb ( mlocate, slocate, findutils or sth ) if needed and run

updatedb

and then ( or before )

locate mod_authn_core.so

To find out if these files are somewere else than they should be, and possibly fix location with symbolic link or moving files where they're expected to be.

If there is no file you need, you may need to comment it in httpd.conf ( if it's specific module ), or (re)install apache package(s). I believe mod_authn_core should be in basic package, not in separate module though. Possibly someone removed it blindly or accidentally, or some intruder messed up with system, or disk got broken or whatever else.

PS. Modules usually are under "lib" e.g. /usr/local/lib/apache2 or /usr/lib/apache2, or /usr/lib/apache2/modules or similar, not in /usr/local/apache2/modules, though it usually depends on compilation of package..

You might also run

apache2ctl -t -D DUMP_VHOSTS

to find out what modules were compiled as shared or static. You should also include information about distribution, and note you're building/installing from source.

Also, have look here: http://httpd.apache.org/docs/2.4/install.html#configure

Piotr Wadas
  • 1,838
  • 1
  • 10
  • 13
  • 1
    Could you please read my edited post that will give little more details. – bimlesh sharma Jul 16 '13 at 18:05
  • I ran "find -type f -name mod_authn_core.so", file is not available. – bimlesh sharma Jul 16 '13 at 18:06
  • those you pasted are not ones you need. You need *.so files – Piotr Wadas Jul 16 '13 at 18:06
  • so, if *.so files are not available, you probably need to reinstall the package, and mod_auth_core will be probably inside main package, not additional one. – Piotr Wadas Jul 16 '13 at 18:08
  • note I edited my answer, try with find / -type f -name .. ( with "/" as path in argument ) – Piotr Wadas Jul 16 '13 at 18:10
  • i used `./configure --prefix=/usr/local/apache --enable-shared=max` to configure this. Do you have any other way to install it? – bimlesh sharma Jul 16 '13 at 18:16
  • I guess you should try to install it from package, possibly from some experimental or beta repository if available. And re-read configure --help more carefully. I'm afraid instructions how to build apache is out of scope of question posted here, it's supposed to provide basic help, not to provide sophisticated build instructions.. – Piotr Wadas Jul 16 '13 at 18:20
  • see things are fine during installation but issue with during starting. It looks for module files inside modules folder but that folder having no *.so file, instead of that *.a and *.la of same files are available. I re-compiled https 2.4 but still getting same error. – bimlesh sharma Jul 16 '13 at 18:40
  • Yes, but not looking useful. B'coz it is saying some process and i am following all mandatory one but still same issue. – bimlesh sharma Jul 16 '13 at 19:09