Apache wont start on MacOS Monterey - macos

$ /usr/local/opt/httpd/bin/httpd -D FOREGROUND
dyld[27461]: Symbol not found: _apr_bucket_alloc_aligned_floor
Referenced from: /usr/local/Cellar/httpd/2.4.51/bin/httpd
Expected in: /usr/lib/libaprutil-1.0.dylib
Abort trap: 6
edit:
brew reinstall apr-util has resolved this

Thanks - this fix worked for me too. This appears to be an essential step. After upgrading to Monterey I followed the steps at
https://getgrav.org/blog/macos-monterey-apache-multiple-php-versions
but could not get apache to work. When I ran ps -aef | grep httpd it showed that the server was not running, even though the brew services command claimed it was. After running the reinstall command set out above, everything worked as before the upgrade. For background, I am running Mac OS Monterey on a Mac mini with Apple M1 chip 16GB RAM. My httpd.conf settings are the same as when I was on Big Sur. I can't imagine how you worked this out, but thanks again.
OK - apparently my response above was not sufficiently clear:
Thomas posted the error message he got when he found that the Apache server would not start when being set up on Mac OS Monterey. The question he implicitly asked (and answered himself) is in the title of the post - ie., why won't the server start? The error message he got gives us a clue - the process is looking for a component (apr-util) which it can't find in the place it expects to find it. He found that by re-installing apr-util he could get the Apache server to start as normally expected. I had the same problem (Apache apparently correctly installed on Monterey but not starting) and I found that by re-installing apr-util as he had that the problem was solved - ie., my Apache server now starts as expected on Mac OS Monterey. As I had wasted about a week futilely trying to solve this problem I am very grateful for Thomas' contribution. I hope this is now clear.

Related

Homebrew upgrade results in clang install every time

Recently with macos 12.6 - after running
homebrew upgrade
I was getting a prompt to install clang. I was not paying attention to the console and installed it. But it kept on happening and I kept on installing clang. As this issue might repeat I would like to share my solution
#1 - this is related to xcode unapplied update to OS 16 and it's packages. Launch Xcode and update everything requested
#2 -
xcodebuild -runFirstLaunch
You can also use this command.
Hopefully my steps will solve your issue. Couldn't find solution anywhere, so decided to share it here

Mamp Pro 4: Apache won't start

I used Mamp Pro 4 for a while with no problem on my Mac (Os X 10.11), then, suddenly, Apache won't start. I got an error: "Check the log" but log is empty.
I have made several test:
reinstalled Mamp Pro 4 (4.0.6);
rebuild permissions using utility disk and Onyx
update Mac os X El Captain to Sierra;
started Apache/MySql as "www" or as "user"
Note:
1) starting system Apache it works
2) using MAMP (not pro) Apache works fine.
Any other suggestions ? Thanks
Fixed!! The issue was in SSL. For some reasons it stopped to works. No logs and no warning occurred: just an empty log. I deleted the SSL and created a new certificate. Now Apache works fine as well.
Have you tried to force-quit apache? I got this issue sometimes as well and using the terminal-commands sudo killall httpd and sudo killall mysqld fixed this issue.
Sometimes I have to repeat the commands a few times.
Upgraded to mamp pro 4.2.1. Now apache won't start. followed directions here: https://appsolute.zendesk.com/hc/en-us/articles/215197286
Nothing in activity monitor.
Nothing in log file.
Resolved by deleting hosts in mamp pro, where the document root had been deleted.
If you are seeing a red circle-arrow next to the Hosts link in the upper left, find the hosts that are not resolving properly to a document root, then fix them or delete them. That resolved it.

Installing Jenkins on MAC OS X El Capitan

This is probably a stupid question but I can't get Jenkins installed on my MAC. I've searched the web and tried various different tutorials but it does not seem to work for me. Moreover it seems that nobody experiences the same problem. I've downloaded the Jenkins Installer from here. After running the installation process, the script tries to connect to http://localhost:8080 but I get the error message that the browser cannot connect to the server. Can anyone help me with this?
Thanks!
And again the solution was quite simple. The connection problem arises when you either don't or you have Java < 1.7 installed. What I did:
deleted my previous Jenkins installation by running /Library/Application\ Support/Jenkins/Uninstall.command
installed JDK 8 (OS X 64bit) from here
reinstalled MAC Jenkins from here
Works fine!

MAMP Pro 3.05 on Mavericks updated to Yosemite - Apache does not start

I have been running MAMP Pro 3.05 successfully in Yosemite up to DP4 on a partition that was a clean install of Yosemite.
I now have run the installer for DP5 over my Mavericks install, and now that MAMP Pro install will not start Apache. It says to check the logs, but I don't see anything pertinent.
I'm assuming that since this is a pre-existing install, something in its config is wrong for Yosemite's Apache.
Any ideas?
MAMP Folks just posted the workaround
Workaround for the 10.10 Preview 5 bug: Rename the file “envvars” located in /Applications/MAMP/Library/bin into “_envvars”
Test Update: It works!
Works for Yosemite release too!
Just found workaround from MAMP on Twitter
Workaround for the 10.10 Preview 5 bug:
Rename the file “envvars” located in into “_envvars”
This works also for Mamp Pro 2.1.1 on Yosemite.
MAMP Folks just posted the workaround
Workaround for the 10.10 Preview 5 bug: Rename the file “envvars”
located in /Applications/MAMP/Library/bin into “_envvars”
Test Update: It works!
Apparently the MAMP folks are working on a work-around:
https://twitter.com/mamp_en/status/496655943506350081
Follow their account for updates.
MAMP Pro 3.0.7.3 should run fine on Yosemite, but after installing it on a brand new machine, I experienced the same problem.
In my case, the problem occurred because I had defined Additional Parameters for my virtual host that contained quotes. By default, Yosemite keyboard settings are set to convert straight quotes to smart quotes ("no-cache" became “no-cache”. Depending on font and font size, this may not be immediately obvious). This made Apache crash, even when the host was disabled.
To change this settings, go to System Preferences -> Keyboard. In the Text tab, uncheck Use smarts quotes and dashes.
Today, I upgraded to MAMP Pro 3.0.7.3 after I upgraded to OSX Yosemite 10.10 (official release) and I experienced this same problem. Apache could not start and it has an empty log file.
I tried this fix, but I noticed that the file is named "envvars_" not "envvars". I renamed it to envvars, restarted MAMP Pro and apache could not start and it had an empty log file. I also noticed that the envvars file had been renamed to envvars_ after I had renamed it.
I was running MAMP 3.0.5 on Mavericks. After upgrading Mavericks to El Capitan, I ran into the same issue. Mysql did start normally but Apache did not.
After renaming envvars to _envvars in the folder /Applications/MAMP/Library/bin such as suggested for Yosemite, I was able to start Apache as before.
So, this fix works for El Capitan as well!
I didn't get it working by changing envvar to _envvar but was able to resolve by changing the apache port from 8888 to 80 then noticed I was missing the mod_example.so. See how I resolved below:
Why won't Apache Server start in MAMP?
I tried that solution and others over and over and did not work until I realised I should be restarting completely MAMP, after doing so, this simple change from envvars to _envvars worked like a charm.
You can completely restart MAMP checking if there's any process going on, open the terminal:
ps -cvx | grep "mysql"
That will output a list of the processes that involves mysql at the time, with a PDI associated, so you only have to take that number and:
kill PDI
Where PDI is the number associated to the process, after that, if you write again the command ps -cvx | grep "mysql" the pointer should be empty.
Once done, only execute MAMP.
The approved answer didn't work for me because the _envvars file was already there. I had to download the latest version of MAMP and install it and it worked.
Sometimes, it's not always the envars files that's the culprit. If you've been editing the vhost file at /Applications/MAMP/conf/apache/extra/httpd-vhosts.conf, a syntax error could cause MAMP's apache to not start without a warning.
In that case, you can run the following command and see if any errors are encountered.
sudo apachectl stop
Try this::
Rename the file “envvars” located in /Applications/MAMP/Library/bin into “_envvars” only for OS X Yosemite.
I got MAMP v3.4 working.
I renamed "envars_" to "_envars" ... but that didn't work.
I had to also go into preferences, and hit the "Set Web & MySql ports to 80 & 3306" button!
Works!

Trying to Run middleman on mac

Answering my own question for anyone else having this issue. (using the search terms i thought of because they didn't bring up the answers for me).
Trying to install and run middleman following the getting started guide on their website with Mac OS X 10.9.2. When trying to run bundle install getting errors about openSSL and event machine.
Gist of Errors.
Refrence to an answer that someone on IRC helped me find.
Aparently this is caused by a mismatch in expected versions with something called Clang which is part of the Xcode tools for mac. The update to Xcode tools causes this to fail. Using the command:
ARCHFLAGS=-Wno-error=unused-command-line-argument-hard-error-in-future bundle install
seems to work to resolve this issue.

Resources