mod_layout Installation and Segmentation fault

mod_layout is an Apache module that provides both a Footer and Header directive to automagically include output from other URIs at the beginning and ending of a Web page. It can be used to wrap documents for a standard look and feel for a site (or to insert banners on any given document in a site). Currently known to support mod_perl, PHP and Apache JServ. Should support just about any type of handler.

http://freshmeat.net/projects/mod_layout/

Today a client asked to install mod_layout on the server. This was already installed, but not working.

So i download and install it again.

wget http://www.tangent.org/download/mod_layout-3.2.1.tar.gz
tar zxvf mod_layout-3.2.1.tar.gz
cd mod_layout-3.2.1
make
make install

Now i edited httpd.conf

And added LayoutHeader and LayoutFooter Directive as below.


ServerAlias domainstobuy.com
ServerAdmin webmaster@domainstobuy.com
DocumentRoot /home/domains/public_html
BytesLog domlogs/domainstobuy.com-bytes_log
ServerName www.domainstobuy.com

User domains
Group domains
LayoutHeader /home/header.html
LayoutFooter /home/footer.html

CustomLog /usr/local/apache/domlogs/domainstobuy.com combined
ScriptAlias /cgi-bin/ /home/domains/public_html/cgi-bin/

Now restarted Apache

/usr/local/apache/bin/apachectl restart

But getting error like

/etc/init.d/httpd: line 308: 27959 Segmentation fault (core dumped) $HTTPD -t >/dev/null 2>&1
/etc/init.d/httpd restart: configuration broken, ignoring restart
/etc/init.d/httpd restart: (run ‘apachectl configtest’ for details)

The problem is corrected by Editing Makefile of mod_layout and reinstalling it.

cd mod_layout-3.2.1
vi Makefile

Then remove the option -DDEBUG

make
make install

/usr/local/apache/bin/apachectl restart

Now mod_layout working fine.


Posted in Uncategorized. Bookmark the permalink.