Link to home
Start Free TrialLog in
Avatar of n00b0101
n00b0101

asked on

How to reload a .conf file without restarting the server?

The server has a bunch of .conf files for virtual hosts and I want to reload one.  How can I do this without restarting the server?
Avatar of JonMarkGo
JonMarkGo

I assume you mean apache. Try httpd reload and if  that doesn't work, httpd restart
Avatar of n00b0101

ASKER

There isn't a way to just reload the .conf file?  I don't want to have to restart the apache server.
try opening it, adding a space to it, then removing the space and saving it.  works with web.config files that usually have to wait for the server to update them.  you have to try it on the .conf thats on the live server.  if not, look on google for a add-on refresh button.
httpd reload should do that....
And if httpd reload doesn't work, httpd restart is a pretty painless process. Apache should only be down for a matter of seconds, if even that long...
When I try either httpd reload or httpd restart, I get this:


Usage: httpd [-D name] [-d directory] [-f file]
             [-C "directive"] [-c "directive"]
             [-k start|restart|graceful|graceful-stop|stop]
             [-v] [-V] [-h] [-l] [-L] [-t] [-S]
Options:
  -D name            : define a name for use in <IfDefine name> directives
  -d directory       : specify an alternate initial ServerRoot
  -f file            : specify an alternate ServerConfigFile
  -C "directive"     : process directive before reading config files
  -c "directive"     : process directive after reading config files
  -e level           : show startup errors of level (see LogLevel)
  -E file            : log startup errors to file
  -v                 : show version number
  -V                 : show compile settings
  -h                 : list available command line options (this page)
  -l                 : list compiled in modules
  -L                 : list available configuration directives
  -t -D DUMP_VHOSTS  : show parsed settings (currently only vhost settings)
  -S                 : a synonym for -t -D DUMP_VHOSTS
  -t -D DUMP_MODULES : show all loaded modules
  -M                 : a synonym for -t -D DUMP_MODULES
  -t                 : run syntax check for config files
ASKER CERTIFIED SOLUTION
Avatar of JonMarkGo
JonMarkGo

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
hello just try to

/etc/init.d/httpd reload
/etc/init.d/http restart

or

service httpd restart
service http reload

first one should working
Avatar of Tintin
What Linux distro are you running?