Koozali.org: home of the SME Server

What does this mean?

WEBlance

What does this mean?
« on: December 14, 2006, 10:40:40 PM »
In the start of file httpd.conf in ./etc/httpd/conf this text is displayed:

Manual changes will be lost when this file is regenerated

I understand that there is a file somwhere on the server that contains the "original" settings. Where is this file located, if I need to correct this source?

/Carl

Offline cactus

  • *
  • 4,880
  • +3/-0
    • http://www.snetram.nl
Re: What does this mean?
« Reply #1 on: December 14, 2006, 11:08:43 PM »
Quote from: "WEBlance"
In the start of file httpd.conf in ./etc/httpd/conf this text is displayed:

Manual changes will be lost when this file is regenerated

I understand that there is a file somwhere on the server that contains the "original" settings. Where is this file located, if I need to correct this source?

/Carl
Have a look at the manual and the development guide about the templating system and the (internal) configuration databases. A lot is explained there.

In short:
All (at least all important) configuration files are templated. You will have to change templates or database values and regenerate the configuration files to keep your changes permanent. If you modify the configuration file directly changes will be overridden the next time the configuration files are expanded.
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

WEBlance

What does this mean?
« Reply #2 on: December 14, 2006, 11:15:13 PM »
Just to skip the hard part (reading a lot of manuals), do anyone know where the httpd.conf template is located?

Yes I know, I'm lazy!!!

Offline cactus

  • *
  • 4,880
  • +3/-0
    • http://www.snetram.nl
What does this mean?
« Reply #3 on: December 14, 2006, 11:21:29 PM »
Quote from: "WEBlance"
Just to skip the hard part (reading a lot of manuals), do anyone know where the httpd.conf template is located?

Yes I know, I'm lazy!!!
Yes but I think you should read it anyhow. All templates are located in the /etc/e-smith/templates* directory. Original templates are in the ./templates folder, custom ones go into the templates-custom directory. Custom templates do not exist by default but you will need to create the directory structure if it does not exist. Copy the original template fragment there, make you modifications and expand your template and restart the service that belongs to the configuration files:

you can expand like this:
Code: [Select]
expand-template /path/to/actual/configuration/file

For the httpd the last actiosn would be:
Code: [Select]
expand-template /etc/httpd/conf/httpd.conf
/etc/rc7.d/S86httpd-e-smith restart


But don;t say i did not warn you when you run into trouble.. please read the section about the template system before you start. It is well worth the time.
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

WEBlance

What does this mean?
« Reply #4 on: December 14, 2006, 11:45:40 PM »
Thank You very much!!! I've been havin problems with the httpd,conf since I upgraded my SME 6.0.1 to 7. Several lines in the httpd.conf were wrong, and now I finally can fix the problem.

I know that the best would be to install a fresh SME 7 and start from the bottom, but I haven'd had the time and strenght to do it . . . yet.

/Carl

Offline Boris

  • *
  • 783
  • +0/-0
What does this mean?
« Reply #5 on: December 17, 2006, 12:20:50 AM »
All versions of SME (and former E-Smith) had template system. The problem and solution applied to to all of them.
...