LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > *BSD
User Name
Password
*BSD This forum is for the discussion of all BSD variants.
FreeBSD, OpenBSD, NetBSD, etc.

Notices


Reply
  Search this Thread
Old 09-09-2012, 05:46 AM   #1
sasser
Member
 
Registered: Apr 2010
Location: Bucharest
Distribution: Slackware13.37, OpenBSD5.1, FreeBSD9.0
Posts: 40

Rep: Reputation: 0
apache configuration


Hello,

I want to do some configuration to Apache but the file /var/www/conf/httpd.conf has 444 permissions (only read).
What is the correct way to configure Apache? Searching the Internet doesn't help me so far on this issue

I guess it isn't hard to add write permissions to that file and edit it.
But should I stop the apache and edit it? Can I edit it while the apache runs and then restart the apache?
After editing should I change back the permissions to readonly?
Or is some other way around?

Last edited by sasser; 09-09-2012 at 05:49 AM.
 
Old 09-09-2012, 07:11 AM   #2
kirukan
Senior Member
 
Registered: Jun 2008
Location: Eelam
Distribution: Redhat, Solaris, Suse
Posts: 1,278

Rep: Reputation: 148Reputation: 148
While run the apache you can change the httpd.conf, once you change the configuration just confirm the configuration changes
Quote:
apachectl -t
and then
Quote:
/etc/init.d/httpd reload
 
Old 09-09-2012, 07:20 AM   #3
earthw0rmjim
Member
 
Registered: Sep 2011
Distribution: Debian testing
Posts: 62

Rep: Reputation: 12
I usually just edit the file as root (using su), and then restart apache with
Code:
service apache2 restart
 
Old 09-09-2012, 09:14 AM   #4
kirukan
Senior Member
 
Registered: Jun 2008
Location: Eelam
Distribution: Redhat, Solaris, Suse
Posts: 1,278

Rep: Reputation: 148Reputation: 148
Quote:
Originally Posted by earthw0rmjim View Post
I usually just edit the file as root (using su), and then restart apache with
Code:
service apache2 restart
Restart will kill all the process and start so there will be interruption. But reload is reloading the config file without interrupting pending operations...
 
Old 09-09-2012, 12:25 PM   #5
sasser
Member
 
Registered: Apr 2010
Location: Bucharest
Distribution: Slackware13.37, OpenBSD5.1, FreeBSD9.0
Posts: 40

Original Poster
Rep: Reputation: 0
After editing the httpd.conf file, should I switch back the permissions to 444?
 
  


Reply



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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
APACHE configuration hks1233 Linux - Newbie 9 02-20-2011 02:55 PM
Migrating Apache 1.3 configuration files to Apache 2 kaplan71 Linux - Software 0 03-28-2007 11:05 AM
apache configuration simcox1 Linux - Networking 14 10-25-2005 05:46 AM
Apache configuration BoardinBum Linux - Networking 3 12-29-2004 05:53 AM
Apache configuration snurckle Linux - Newbie 4 07-25-2004 10:06 PM

LinuxQuestions.org > Forums > Other *NIX Forums > *BSD

All times are GMT -5. The time now is 05:28 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration