Apache 2 cannot successfully load module? - apache2

We have an older ubuntu 14 server that is currently working and has apache2 running on and I'm attempting to install an open idc module to get SSO working at our company. I know...Ubuntu 14 is old, but that's a whole other can of worms...
When I run
apachectl -M
It successfully shows auth_openidc_module (shared)
I also verified that ‘auth_openidc.conf’ is in my /etc/apache2/mods-enabled directory
However when I add
in my apache2.conf :
LoadModule auth_openidc_module module/mod_auth_openidc.so
include mods-enabled/auth_openidc.conf
<Location / >
AuthType openid-connect
Require valid-user
</Location>
and perform a 'apachectl -M' command I get the following error.
'Syntax error on line 57 of /etc/apache2/apache2.conf: Cannot load module/mod_auth_openidc.so into server: /etc/apache2/module/mod_auth_openidc.so: cannot open shared object file: No such file or directory
Action '-M' failed.'
Another point of confusion, I don't see any directory named 'auth_openidc_module' or any .so file anywhere within Apache. I have seen some posts that the .so files might be in '/usr/lib64/httpd/modules' but my lib64 directory is blank...
I'm a newbie to all of this...what am I missing?

So I don't have it working successfully yet, but I did get the error 'can't find' error fixed. The directory for modules on our server was '/usr/lib/apache2/modules/' NOT '/usr/lib64/httpd/modules'

Related

httpd.conf new file locations -apache2

I'm trying to add some semblance of security for my website. I've been following this: https://www.tecmint.com/apache-security-tips/ and they want me to edit the httpd file but it doesn't exist in my server. I started doing some more research and I found this https://help.ubuntu.com/lts/serverguide/httpd.html which says it doesn't exist and "all configuration options have been moved to the below referenced directories". So I would appreciate it if someone could tell me which files to add those options to! Also should I edit the apache2.conf file?
Edit: I'm using ubuntu 18.04 LTS
the Main Configuration file for RHEL/CentOS/Fedora is: /etc/httpd/conf/httpd.conf
and for Debian/Ubuntu is: /etc/apache2/apache2.conf.
as you are using ubuntu os so you should edit /etc/apache2/apache2.conf.
for more information and the history about apache2.conf and httpd.conf , as mentioned within ubuntu doc Ubuntu 18.04 Apache2 Web Server Guide:
httpd.conf: historically the main Apache2 configuration file, named
after the httpd daemon. Now the file does not exist. In older versions
of Ubuntu, the file might be present, but empty, as all configuration
options have been moved to the below-referenced directories.

Apache2 [Errno 13] Permission denied error

Within my VirtualHost apache2 config file I have:
<Directory /var/www/antiques/media>
Require all granted
</Directory>
And yet when I'm trying to load an image I'm getting the following error:
[Errno 13] Permission denied: '/var/www/antiques/media/categories'
What am I missing?
If you are not sure how to give permission to file or folder, install FileZilla and connect to your server. Then just go right click on file/folder and find file permissions option. There you can change file/folder permissions much easier.
Define the requirements
Developers need read/write access to files so they can update the website
Developers need read/write/execute on directories so they can browse around
Apache needs read access to files and interpreted scripts
Apache needs read/execute access to serveable directories
Apache needs read/write/execute access to directories for uploaded content
Check out this link for more info about werbserver permissions.

403 Forbidden Error with Apache2

I am trying to set up Apache2 on my Ubuntu system. It's has been installed and working. The problem is that I'm working on an AngularJS project and I need a server for my html pages. Right now the directory is set to:
<Directory /var/www/html>
Options FollowSymLinks
AllowOverride None
Require all granted
</Directory>
When ever I try to change it to a specific path I always get the 403 Forbidden error. The path I want it changed to is:
/home/michael/dev/JavaScript/AngularJS/Quiz App
When the system is set to the default path and I reload my html page using Sublime Text and I get a 404 error. The html page is:
http://localhost/01_01/index.html
I've been up all night trying to fiqure this out and did the best I could to resolve it. I'm open to any possible solutions you guys may have.
It is because Apache2 does not have permission to access path within your home directory. One thing you can do is to create a symbolic link in /var/www/html and pointing it to your code directory.
ln -s "/home/michael/dev/JavaScript/AngularJS/Quiz App" /var/www/html/quizApp
No open the browser and type localhost/quizApp and you should be able to open your app in the browser

Cake php3.0 xampp 3.2.1 error

Hey I had installed xampp on windows xampp control panel 3.2.1 and I am getting this error :
Fatal error: You must enable the intl extension to use CakePHP. in G:\xampp\htdocs\hw\config\bootstrap.php on line 38
I had changed httpd.conf and uncomment this line
LoadModule rewrite_module libexec/apache2/mod_rewrite.so
and change directory attributes :
<Directory />
Options FollowSymLinks
AllowOverride All
Order deny,allow
Deny from all
</Directory>
to this and restarted the apache and I am still getting this message Fatal error:
You must enable the intl extension to use CakePHP. in G:\xampp\htdocs\hw\config\bootstrap.php on line 38
If you have already Change ;extension=php_intl.dll to extension=php_intl.dll (remove the semicolon) in php.ini
Still same error comes.
In both XAMPP and WAMP, mcrypt and mbstring extensions are working by default.
In XAMPP, intl extension is included but you have to uncomment extension=php_intl.dll in php.ini and restart the server through the XAMPP Control Panel.
In WAMP, the intl extension is “activated” by default but not working. To make it work you have to go to php folder (by default) C:\wamp\bin\php\php{version}, copy all the files that looks like icu*.dll and paste them into the apache bin directory C:\wamp\bin\apache\apache{version}\bin. Then restart all services and it should be OK.
You may get the correct ans here :
In both XAMPP and WAMP, mcrypt and mbstring extensions are working by default.
In XAMPP, intl extension is included but in the php.ini you have to uncomment:
extension=php_intl.dll
and restart the server through the XAMPP Control Panel.
In WAMP, the intl extension is “activated” by default but not working. To make it work you have to go to the php folder (by default):
C:\wamp\bin\php\php{version}
copy all the files that looks like icu*.dll and paste them into the apache bin directory
C:\wamp\bin\apache\apache{version}\bin.
Then restart all services and it should be OK.

Apache 2.4.2 (win32), mod_fcgid - Can't find module file

(lastest fcgid module)
OS: Windows Xp prof SP3
I place file mod_fcgid.so in directory (modules)
// Httpd.conf
LoadModule fcgid_module modules/mod_fcgid.so
But. When i try run http (from cmd - for test purpose)
I get error:
httpd: Syntax error on line 515 of C:/Core/Apache24/conf/httpd.conf: Cannot load
C:/Core/Apache24/modules/mod_fcgid.so into server: Nie mo\xbfna odnale\x9f\xe6
okre\x9clonego modu\xb3u.
Path is correct. So what is bad?
This link may help. Here's an example of correct syntax:
IfDefine FCGI
LoadModule fcgid_module modules/mod_fcgid.so
IfDefine
Kindly visit https://www.apachelounge.com/download/
Download zip folder named mod_fcgid
Copy&Paste mod_fcgid.so file in your apache modules folder
Remember to load in your httd.conf file => LoadModule fcgid_module modules/mod_fcgid.so

Resources