Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

apache upgrade not working. please help

Status
Not open for further replies.

kenhead2002

Programmer
Jun 3, 2002
108
US
i just upgraded and now the new version doesnt seem to like my conf. could you please look it over and tell me whats wrong? Thanks in advance!



ServerRoot "C:/Program Files/Apache Group/Apache2"


PidFile logs/httpd.pid


Timeout 300


KeepAlive On


MaxKeepAliveRequests 100


KeepAliveTimeout 15


<IfModule mpm_winnt.c>
ThreadsPerChild 250
MaxRequestsPerChild 0
</IfModule>


Listen 65.32.226.236:80


LoadModule access_module modules/mod_access.so
LoadModule actions_module modules/mod_actions.so
LoadModule alias_module modules/mod_alias.so
LoadModule asis_module modules/mod_asis.so
LoadModule auth_module modules/mod_auth.so

LoadModule autoindex_module modules/mod_autoindex.so

LoadModule cgi_module modules/mod_cgi.so

LoadModule dir_module modules/mod_dir.so
LoadModule env_module modules/mod_env.so

LoadModule imap_module modules/mod_imap.so
LoadModule include_module modules/mod_include.so

LoadModule isapi_module modules/mod_isapi.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule mime_module modules/mod_mime.so

LoadModule negotiation_module modules/mod_negotiation.so

LoadModule setenvif_module modules/mod_setenvif.so

LoadModule userdir_module modules/mod_userdir.so


ServerAdmin kknapp@tampabay.rr.com


ServerName

UseCanonicalName Off


DocumentRoot &quot;C:\

<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>


<Directory &quot;C:/

Options Indexes FollowSymLinks




Order allow,deny
Allow from all

</Directory>


UserDir &quot;My Documents/My Website&quot;


DirectoryIndex index.html index.html.var


AccessFileName .htaccess


<Files ~ &quot;^\.ht&quot;>
Order allow,deny
Deny from all
</Files>


TypesConfig conf/mime.types


DefaultType text/plain


<IfModule mod_mime_magic.c>
MIMEMagicFile conf/magic
</IfModule>


HostnameLookups Off




ErrorLog logs/error.log


LogLevel warn



LogFormat &quot;%h %l %u %t \&quot;%r\&quot; %>s %b \&quot;%{Referer}i\&quot; \&quot;%{User-Agent}i\&quot;&quot; combined
LogFormat &quot;%h %l %u %t \&quot;%r\&quot; %>s %b&quot; common
LogFormat &quot;%{Referer}i -> %U&quot; referer
LogFormat &quot;%{User-agent}i&quot; agent



CustomLog logs/access.log common



ServerTokens Full


ServerSignature On


Alias /icons/ &quot;C:/Program Files/Apache Group/Apache2/icons/&quot;

<Directory &quot;C:/Program Files/Apache Group/Apache2/icons&quot;>
Options Indexes MultiViews
AllowOverride None
Order allow,deny
Allow from all
</Directory>


Alias /manual &quot;C:/Program Files/Apache Group/Apache2/manual&quot;

<Directory &quot;C:/Program Files/Apache Group/Apache2/manual&quot;>
Options Indexes FollowSymLinks MultiViews IncludesNoExec
AddOutputFilter Includes html
AllowOverride None
Order allow,deny
Allow from all
</Directory>


ScriptAlias /cgi-bin/ &quot;C:/Program Files/Apache Group/Apache2/cgi-bin/&quot;


<Directory &quot;C:/Program Files/Apache Group/Apache2/cgi-bin&quot;>
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>


IndexOptions FancyIndexing VersionSort


AddIconByEncoding (CMP,/icons/compressed.gif) x-compress x-gzip

AddIconByType (TXT,/icons/text.gif) text/*
AddIconByType (IMG,/icons/image2.gif) image/*
AddIconByType (SND,/icons/sound2.gif) audio/*
AddIconByType (VID,/icons/movie.gif) video/*

AddIcon /icons/binary.gif .bin .exe
AddIcon /icons/binhex.gif .hqx
AddIcon /icons/tar.gif .tar
AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv
AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip
AddIcon /icons/a.gif .ps .ai .eps
AddIcon /icons/layout.gif .html .shtml .htm .pdf
AddIcon /icons/text.gif .txt
AddIcon /icons/c.gif .c
AddIcon /icons/p.gif .pl .py
AddIcon /icons/f.gif .for
AddIcon /icons/dvi.gif .dvi
AddIcon /icons/uuencoded.gif .uu
AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl
AddIcon /icons/tex.gif .tex
AddIcon /icons/bomb.gif core

AddIcon /icons/back.gif ..
AddIcon /icons/hand.right.gif README
AddIcon /icons/folder.gif ^^DIRECTORY^^
AddIcon /icons/blank.gif ^^BLANKICON^^


DefaultIcon /icons/unknown.gif


ReadmeName README.html
HeaderName HEADER.html


IndexIgnore .??* *~ *# HEADER* README* RCS CVS *,v *,t


AddEncoding x-compress Z
AddEncoding x-gzip gz tgz


AddLanguage da .dk
AddLanguage nl .nl
AddLanguage en .en
AddLanguage et .et
AddLanguage fr .fr
AddLanguage de .de
AddLanguage he .he
AddLanguage el .el
AddLanguage it .it
AddLanguage ja .ja
AddLanguage pl .po
AddLanguage ko .ko
AddLanguage pt .pt
AddLanguage nn .nn
AddLanguage no .no
AddLanguage pt-br .pt-br
AddLanguage ltz .ltz
AddLanguage ca .ca
AddLanguage es .es
AddLanguage sv .sv
AddLanguage cs .cz .cs
AddLanguage ru .ru
AddLanguage zh-TW .zh-tw
AddLanguage hr .hr


LanguagePriority en da nl et fr de el it ja ko no pl pt pt-br ltz ca es sv tw


ForceLanguagePriority Prefer Fallback


AddDefaultCharset ISO-8859-1


AddCharset ISO-8859-1 .iso8859-1 .latin1
AddCharset ISO-8859-2 .iso8859-2 .latin2 .cen
AddCharset ISO-8859-3 .iso8859-3 .latin3
AddCharset ISO-8859-4 .iso8859-4 .latin4
AddCharset ISO-8859-5 .iso8859-5 .latin5 .cyr .iso-ru
AddCharset ISO-8859-6 .iso8859-6 .latin6 .arb
AddCharset ISO-8859-7 .iso8859-7 .latin7 .grk
AddCharset ISO-8859-8 .iso8859-8 .latin8 .heb
AddCharset ISO-8859-9 .iso8859-9 .latin9 .trk
AddCharset ISO-2022-JP .iso2022-jp .jis
AddCharset ISO-2022-KR .iso2022-kr .kis
AddCharset ISO-2022-CN .iso2022-cn .cis
AddCharset Big5 .Big5 .big5

AddCharset WINDOWS-1251 .cp-1251 .win-1251
AddCharset CP866 .cp866
AddCharset KOI8-r .koi8-r .koi8-ru
AddCharset KOI8-ru .koi8-uk .ua
AddCharset ISO-10646-UCS-2 .ucs2
AddCharset ISO-10646-UCS-4 .ucs4
AddCharset UTF-8 .utf8


AddCharset GB2312 .gb2312 .gb
AddCharset utf-7 .utf7
AddCharset utf-8 .utf8
AddCharset big5 .big5 .b5
AddCharset EUC-TW .euc-tw
AddCharset EUC-JP .euc-jp
AddCharset EUC-KR .euc-kr
AddCharset shift_jis .sjis


AddType application/x-tar .tgz
AddType image/x-icon .ico




AddHandler type-map var





BrowserMatch &quot;Mozilla/2&quot; nokeepalive
BrowserMatch &quot;MSIE 4\.0b2;&quot; nokeepalive downgrade-1.0 force-response-1.0
BrowserMatch &quot;RealPlayer 4\.0&quot; force-response-1.0
BrowserMatch &quot;Java/1\.0&quot; force-response-1.0
BrowserMatch &quot;JDK/1\.0&quot; force-response-1.0


BrowserMatch &quot;Microsoft Data Access Internet Publishing Provider&quot; redirect-carefully
BrowserMatch &quot;^WebDrive&quot; redirect-carefully
BrowserMatch &quot;^WebDAVFS/1.[012]&quot; redirect-carefully
BrowserMatch &quot;^gnome-vfs&quot; redirect-carefully



<IfModule mod_ssl.c>
Include conf/ssl.conf
</IfModule>



NameVirtualHost *

<VirtualHost *:80>

UseCanonicalName off

ServerName
ServerAlias crackerentertainment.com

ServerAdmin kknapp@tampabay.rr.com.com

DocumentRoot c:/
ScriptAlias /cgi-bin/ &quot;c:/
ErrorLog logs/crackerentertainment.com/error.log
CustomLog logs/crackerentertainment.com/access.log common
CustomLog logs/crackerentertainment.com/referer.log referer
CustomLog logs/crackerentertainment.com/agent.log agent

ServerSignature EMail

</VirtualHost>




<VirtualHost *:80>

UseCanonicalName off

ServerName
ServerAlias hleonegraphics.com

ServerAdmin heather@hleonegraphics.com

DocumentRoot c:\
ScriptAlias /cgi-bin/ &quot;c:/
ErrorLog logs/hleonegraphics.com/error.log
CustomLog logs/hleonegraphics.com/access.log common
CustomLog logs/hleonegraphics.com/referer.log referer
CustomLog logs/hleonegraphics.com/agent.log agent

ServerSignature EMail

</VirtualHost>
 
no errors at all actually, the page just wont pull my domains like it used to.
 
it's not pulling my sites from my virtual hosts at all. I expect it to read the virtual host info and pull my sites. as of now i only get a site not found error. Leads me to believe the conf got messed up somewhere.
 
Look in your error logs. What did you upgrade from and what did you upgrade to? Sometimes there will be a default SSL vhost in ssl.conf and you will have to delete it. You should be getting an error complaining about it thou because apache doesn't allow both http and https in the same httpd.conf file.
 
I upgraded from an older version like 1.91 or something to the current downloadable version 2. something. My conf had no changes from the old version to the new but now it will not connect to my pages to pull them. I am completely confused as to what has gone wrong.
 
Use the httpd.conf that came with the upgrade and copy and paste your vhosts into that one.
 
ok heres the deal. when using the httpd.conf that came with the upgrade the server works. However it only pulls from the htdocs where the apache page loads until you replace it with your page. when i paste my virtual host in at the bottom it still works but my path is different than the installed c:/program files/apache group/apache2/htdocs. the true path to my sites is c:/ i change the document root to match c:/ when apache stops connecting completely. The app will no longer start up but I still do not recieve errors. Why can't i change the document root to in previous versions?oes the web page file need to be rooted in htdocs now or am i missing something? i can paste the new conf in here if needed just let me know.
thanks in advance
 
Can you change the ServerName in the &quot;main&quot; to localhost or comment it out? Since you are using vhosts, if a domain can't be found, the first vhost defined becomes the default and the main server will never be served anyway. If it quits serving the test page, we will then know that it is only seeing main and not your vhosts. Other than that your vhosts seem to be setup correctly.

 
I tried uncommenting the servername and it stilll pulls the test page. I am not sure what else i am missing.
 
OK......just a shameless Linux plug...why are you running apache on windows anyway?!?!?! ;-)

So just to get things straight, when you use the default config it serves the default intro page in htdocs. And if you change DocumentRoot to c:\ serves nothing? Or does it still serve the default page? What's the name of the file of your first page (in If it's php you may have some issues there with Apache 2, but there are helpers out there, and you should get a bunch of php gobbledy-gook.
 
ok - the ultimate test. Change the DocumentRoot in main and if it stays the same, apache is reading a different httpd.conf file. Check ServerRoot.
 
alright changed the docroot to c:/ it's still serving the page from htdocs. there is only one file in the conf folder for it to read. i dont understand what else it could be reading. The main page is plain html no php. index.html to be specific. I am kinda at a loss as to what to do now?
 
forgot to restart it.

now i get an error on the docroot section here

# This should be changed to whatever you set DocumentRoot to.
#
<Directory &quot;C:/
and an error here

#
# This controls which options the .htaccess files in directories can
# override. Can also be &quot;All&quot;, or any combination of &quot;Options&quot;, &quot;FileInfo&quot;,
# &quot;AuthConfig&quot;, and &quot;Limit&quot;
#
AllowOverride None

and here

# Also, folks tend to use names such as .htpasswd for password
# files, so this will protect those as well.
#
<Files ~ &quot;^\.ht&quot;>
Order allow,deny
Deny from all
</Files>

and here

# The following directives define some format nicknames for use with
# a CustomLog directive (see below).
#
LogFormat &quot;%h %l %u %t \&quot;%r\&quot; %>s %b \&quot;%{Referer}i\&quot; \&quot;%{User-Agent}i\&quot;&quot; combined
LogFormat &quot;%h %l %u %t \&quot;%r\&quot; %>s %b&quot; common
LogFormat &quot;%{Referer}i -> %U&quot; referer
LogFormat &quot;%{User-agent}i&quot; agent

and here

# The location and format of the access logfile (Common Logfile Format).
# If you do not define any access logfiles within a <VirtualHost>
# container, they will be logged here. Contrariwise, if you *do*
# define per-<VirtualHost> access logfiles, transactions will be
# logged therein and *not* in this file.
#
CustomLog logs/access.log common

and here

#This is where you cgi-bin is
ScriptAlias /cgi-bin/ &quot;c:/
and in my virtual host here

CustomLog logs/crackerentertainment.com/access.log common
CustomLog logs/crackerentertainment.com/referer.log referer
CustomLog logs/crackerentertainment.com/agent.log agent

and my second virtual host here

#This is where you cgi-bin is
ScriptAlias /cgi-bin/ &quot;c:/ErrorLog logs/hleonegraphics.com/error.log
CustomLog logs/hleonegraphics.com/access.log common
CustomLog logs/hleonegraphics.com/referer.log referer
CustomLog logs/hleonegraphics.com/agent.log agent

after uncommentin all these spots i still only get the test page. now i am completely confused.
 
still having problems. please see the errors in the post above. Help if you can.
 
What in the world do you mean, when you say you get errors in those places?
 
those are the places in the conf where i am getting errors when trying to start the service. when i go to test configuration it tells me what line the errors are on. when left uncomented the service will not start.
 
I'll be danged if I can figure this one out. It just doesn't make sense that it is doing what it's doing. We're gonna have to think way outside the box on this one. First, Did you have the original apache run as a service? Did you remove that service when you did the upgrade? Is there any chance that there is more than one instance of apache running? How are you installing apache? msi? If you chose a new location for apache, did you delete the old files? It's acting like it's not reading from the same httpd.conf you are editing.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top