Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have installed Apache both in /etc/apache2 as in /opt/local/apache.

How can I tell mac to use the /etc/apache and not the other one?

share|improve this question

2 Answers 2

up vote 2 down vote accepted

First, make it so the macports apache install does not run automatically (I'm assuming macports because of the location):

sudo port unload apache2

(I'm also assuming you installed apache2.)

Now the macports apache will only run when asked. If you never plan to use that copy of apache, consider

sudo port uninstall apache2

and it will be gone forever (you might have to uninstall things that depend on apache as well).

Use the Sharing panel in System Preferences to turn on the preinstalled apache, or use the apachectl script as indicated by Indrek; e.g., apachectl start

share|improve this answer
    
thanks, but for now... I just gave up hope upon getting used to mac (kinda hate it), but when I'll have the chance and some spare time, I'll let you know the result –  w0rldart Jan 11 '13 at 9:50
    
it did the job, I had to remove specific apache version but it did the job... thank you –  w0rldart Jan 11 '13 at 10:24

Use the apachectl command. For more information:

apachectl -h 

In your case you need to specify an alternate configuration file with :

apachectl -f your_path/httpd.conf 
share|improve this answer
1  
this is the help flag, I would much like to have an example with what should I do –  w0rldart Jan 10 '13 at 15:08
    
The -h give you the answer : apachectl -f your_path/httpd.conf –  Louis Jan 11 '13 at 10:39
    
thank you, I had seen that... but that was just to load another ServeConfigurationFile, where I needed to completely remove that apache. Edit your answer to add what you just mentioned, and I'll upvote it –  w0rldart Jan 11 '13 at 10:54

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.