2 Apache / LAMP in Same Machine - apache

We had an apache installation in our server but with old version (php 5.4). We have then installed LAMP in another location with the latest versions (php 7.1).
Now after restarting the server, the apache is only starting from old conf file. How to make to start from new setup?

Solution:
Step 1: find your apache location with command find / -name apachectl
Step 2: start the exact apache for example if your location is /username/lamp/apache2/conf/httpd.conf
then use this command
/username/lamp/apache2/bin/apachectl start

Related

apache2.4 , where to setup mod_ssl, dont see any mod_ssl.so file

Problem is the plain vanila apache is working, the moment I say sslEngine ON
it gives error, I am not able to find where any ssl setup is?
it does not create any log as well..
How this ssl setup is done? will copying a mod_ssl.so file from outside will work?
Apache version : 2.4.29
Os is RHEL 6.7
If this Red Hat documentation is not wrong the RHEL 6.x releases include Apache/2.2. Since you have Apache/2.4 I'd say you probably have an unofficial binary. Such binaries could of course have been installed in any conceivable way so this answer can easily be wrong. Yet making the hopefully safe assumption that you're still using the package manager and you just switched to a third-party repository you can try this:
yum install mod_ssl
Then tweak /etc/httpd/conf.d/ssl.conf to your liking and restart the service:
service httpd graceful
After a lot of research, I found below command which can help you show the actual issue while restarting. when I ran this it told me that .csr which I was using were wrong. I could not get this when I normally started the Apache but this command helped.
replace below with location where apache is installed and conf file is located, this will print the error ( if any).
/xxx/app/xxx/apache22/0/bin/apachectl_worker -DSSL -k start -f /xxx/app/xxx/apache22/0/conf/xxx.conf

Laravel exception on WAMP windows server

I have installed a Laravel application on WAMP in a window server and I receive this error:
"Call to undefined function Illuminate\Encryption\openssl_cipher_iv_length()"
I cannot figure out the reason.
-- UPDATE --
I found out that MCrypt module is missing from the php extension folder, now the problem is how to install it :)
Solution 1:
Enable this extension (php_mcrypt.dll) in your php.ini file:
extension=php_mcrypt.dll
And then restart WAMP.
Solution 2:
For laravel look into config/app.php under 'cipher' and replace CRYPT_RIJNDAEL_128 with 'AES-128-CBC'
Make sure you update Wampserver, PHP AND Apache:
Exit running Wamp Server
From [Wamp][1]:
- Install the Visual c++ packages,
- Update Wamp Server
- Update PHP
- Update Apache
Switch to the newest PHP:
- Wamp TrayIcon->PHP->Version-> 7.x.x
Switch to the newest Apache Version
- Wamp TrayIcon->Apache->Version-> 2.x.x
Make enable extension=openssl in both php.ini files, php and apache directories

Tactic Installation on centos 7

I am doing installation of tactic 4.5 on centos 7.
i am following
http://community.southpawtech.com/tactic-sys-admin_sys-admin_install-tactic-centos-6.2.html
but in the end when i am trying to access tactic through web
i am getting this error:
The requested URL /tactic was not found on this server.
you need to configure apache properly to fix this.
Copy tactic configuration file in /etc/httpd/conf.d folder
cp /opt/tactic/tactic_data/config/tactic.conf /etc/httpd/conf.d
open httpd.conf file and add Include conf.d/*.conf in the end
systemctl restart httpd.service

How to change uwamp apache version

I would like to use Apache 2.2.31 because that's what my live site on bluehost is running. How do I specify this version in uwamp?
I'm running uwamp on Win 10.
change apache version in uWamp by doing like this :
Downloaded the Apache 2.4 VC14 32bits from ApacheHaus.
Select the 32bits apache version even if windows is 64bits)
Then follow these steps:
Unzip the downloaded apache to UwAmp\bin directory (to obtain UwAmp\bin\apache24)
rename the original UwAmp\bin\apache to UwAmp\bin\apache_old
rename UwAmp\bin\apache24 to UwAmp\bin\apache
copy UwAmp\bin\apache_old\certificat to UwAmp\bin\apache\certificat
copy UwAmp\bin\apache_old\conf\httpd_uwamp.conf to UwAmp\bin\apache\conf\httpd_uwamp.conf
copy UwAmp\bin\apache_old\php.ini to UwAmp\bin\apache\php.ini
merge UwAmp\bin\apache_old\conf\extra with UwAmp\bin\apache\conf\extra
(keep the newest files, just copy the old ones to the new apache dir :
httpd-ahssl.conf, httpd-deflate.conf, httpd-proxy-html.conf, httpd-vhosts.conf)
That's all! Verify by starting uWamp then open localhost and look at the apache version number. Look in the uWamp log messages window for notices or errors if any.
If something went wrong just roll back to the original apache by renaming back the 2 folders:
close uWamp
rename the newest UwAmp\bin\apache to UwAmp\bin\apache_new
rename the original UwAmp\bin\apache_old to UwAmp\bin\apache

Phusion Passenger ngnix.conf location

I have a Rails 3 application that uses Phusion Passenger. I install the standalone version of Passenger using the command "gem install passenger" on my Macintosh MacBook Pro. The application works fine. Now, I want to change some configurations for the ngnix server but I can not find the location of the ngnix.conf file. I have looked in /usr/local and /opt/ and /etc/. Can someone assist me in either finding or creating the ngnix.conf?
Thanks
Look for the nginx.conf file in /opt/nginx/conf
You must have su privileges to edit this file.
Remember to stop and start nginx after making your changes