On Thursday 03 September 2009 03:06:37 pm Al Bogner wrote:
I am getting crazy with a simple setup of a Webserver with yast.
The message is:
Error
Invalid server name.
A valid domain name consists of components separated by dots.
Each component contains letters, digits, and hyphens. A hyphen may not
start or end a component and the last component may not begin with a digit.
This was configured
New Host Information
Server Identification
Server Name:
pinguin.uni.cc
Server Contents Root:
/srv/www/htdocs/pinguin.uni.cc
Administrator E-Mail:
Server Resolution
VirtualHost (x) Determine Request Server by HTTP Headers
* ( ) Determine Request Server by Server IP
Address
Obviously pinguin.uni.cc is correct.
Maybe I should try it manually, but the last time when I tried it, the 1st
domain worked and after the 2nd one, nothing worked anymore. So I didn't
try it again after someone tells me what to try.
Al
Al,
There are only 3-4 files you need to look at to set up a simply web server.
If you will make sure your config is good in the following files, you *will*
have a running web server.
First, just check /etc/apache2/listen.conf to make sure you are listening on
the normal ports http is port 80, https is port 443. Your file should look
like:
Listen 80
<IfDefine SSL>
<IfModule mod_ssl.c>
Listen 443
</IfModule>
</IfDefine>
</IfDefine>/etc/apache2/httpd.conf
You shouldn't have to change anything. Next check /etc/apache2/default-
server.conf. It should contain the following entries (comments omitted):
DocumentRoot "/srv/www/htdocs"
Options None
AllowOverride None
Order allow,deny
Allow from all
</Directory>
ScriptAlias /cgi-bin/ "/srv/www/cgi-bin/"
AllowOverride None
Options +ExecCGI -Includes
Order allow,deny
Allow from all
</Directory>
<IfModule mod_userdir.c>
UserDir public_html
Include /etc/apache2/mod_userdir.conf
</IfModule>
Include /etc/apache2/conf.d/*.conf
Include /etc/apache2/conf.d/apache2-manual?conf
Your default-server.conf has defined for you your document root
"/srv/www/htdocs", your cgi script directory "/srv/www/cgi-bin" and your user-
dir location (the users personal web pages accessed by
http://www.yoursite.com/~username). This is all you need to run, but the
default-server.conf must be included by httpd.conf
The httpd.conf file (/etc/apache2/httpd.conf) is the normal file for server
configuration. If you look at it, all it really does is to "include" the
pieces of the server you want to run. (i.e. which modules you would like your
server to include and set basic global permissions for directories, etc.)
Your httpd.conf file should look something like this (comments omitted):
Include /etc/apache2/uid.conf
Include /etc/apache2/server-tuning.conf
ErrorLog /var/log/apache2/error_log
Include /etc/apache2/sysconfig.d/loadmodule.conf
Include /etc/apache2/listen.conf
Include /etc/apache2/mod_log_config.conf
Include /etc/apache2/sysconfig.d/global.conf
Include /etc/apache2/mod_status.conf
Include /etc/apache2/mod_info.conf
Include /etc/apache2/mod_usertrack.conf
Include /etc/apache2/mod_autoindex-defaults.conf
TypesConfig /etc/apache2/mime.types
DefaultType text/plain
Include /etc/apache2/mod_mime-defaults.conf
Include /etc/apache2/errors.conf
Include /etc/apache2/ssl-global.conf
<Directory />
Options None
AllowOverride None
Order deny,allow
Deny from all
</Directory>
AccessFileName .htaccess
Order allow,deny
Deny from all
</Files>
DirectoryIndex index.html index.html.var
Include /etc/apache2/default-server.conf
Include /etc/apache2/sysconfig.d/include.conf
Include /etc/apache2/vhosts.d/*.conf
You may not have all of the same modules included, but it should be similar.
Without going any farther, if you restart apache (as root issue "rcapache2
restart" from the command line), you should have a working server. Just point
your browser to http://localhost (if you are working on the server) or
http://yoursite.com (if your name resolution is working) and you should see
the default page saying "It Works!" or some similar nonsense.
FURTHER READING
Normally, httpd.conf is where you would also have all of your server specific
setup, but openSuSE may over-write this file when you update apache2, so by
convention you put all your site specific configuration in httpd.conf.local
and then simply include that file by an entry in /etc/sysconfig/apache2.
There are some things yast is fine for setup with, but when you get to
configuring servers (http, ppp, fax, dns, dhcp, etc..) you really need to do
it with an editor if you ever hope to have an understanding of what it is you
are trying to do. All of the openSuSE configuration files are well commented
and most times you can simply scan through the comments and learn how the
basic configuration works.
--
David C. Rankin, J.D.,P.E.
Rankin Law Firm, PLLC
510 Ochiltree Street
Nacogdoches, Texas 75961
Telephone: (936) 715-9333
Facsimile: (936) 715-9339
www.rankinlawfirm.com
--
To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse+help@opensuse.org