BSD Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsOperating SystemsBSD Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now!
  #1  
Old July 11th, 2004, 09:02 PM
cbchev68 cbchev68 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2003
Location: NH
Posts: 228 cbchev68 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 12 h 25 m 38 sec
Reputation Power: 6
Is this the correct way to start Apache2?

I am trying to get Apache2 to start on bootup, on freeBSD 5.2.1; installed from ports.

In /etc/rc.conf I added

apache2_enable="YES"

This seems to start Apache on bootup, was the the 'correct' way? when I say that, I want to make sure I am starting it the way it was intended.

I am confused mainly because there is /etc and /usr/local/etc
Is there a standard in freeBSD as to what configuration files should be in each directory?

Thanks for any and all input.

Reply With Quote
  #2  
Old July 11th, 2004, 10:16 PM
stevengs stevengs is offline
Permanently Banned
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2004
Location: Germany
Posts: 394 stevengs User rank is Lance Corporal (50 - 100 Reputation Level)stevengs User rank is Lance Corporal (50 - 100 Reputation Level)stevengs User rank is Lance Corporal (50 - 100 Reputation Level) 
Time spent in forums: 3 Days 4 h 36 m 24 sec
Warnings Level: 10
Number of bans: 1
Reputation Power: 0
apache places a startup script (apache2.sh) in the startup script directory (/usr/local/etc/rc.d/). It is dependant on the variables:

apache2_enable (probably the most pertinent)
apache2ssl_enable
apache2limits_enable
apache2_flags
apache2limits_args

at boot up the script apache2.sh is started, and if the variable apache2_enable is set to yes (by rc.conf) then it starts apache. You can manuall start and stop the apache httpd a number of ways. Probably the most convenient is with apachtctl. (man apachectl)

apachectl stop (start/restart/fullstatus/...)

there are of course other ways to acheive both of these (such as> kill -HUP pid_of_parent_httpd), but these work fine for me.


I believe the general rule of thumb on the placement of configuration files (and someone will surely correct me if I am wrong) is that the config files for the base system (group, passwd, rc.conf, profile, cron, etc.) go in /etc and the config files for everything not belonging to the base system (apache, bind, mysql, etc. ) should go in /usr/local/etc. The binarys are handled similarly. So far, the ports I have installed have all behaved as they should, using the standard unix locations.

-Steven
______________
My mother told me to stand up to homicidal maniacs. –Baldrick
Yes, if this is the same mother who confidently claimed that you are a tall handsome stallion of a man, I should treat her opinions with extreme caution. –Edmund Black Adder

Reply With Quote
Reply

Viewing: Dev Shed ForumsOperating SystemsBSD Help > Is this the correct way to start Apache2?


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway