02-26-2013
Show the conf:
inux.com/TUTORIALS/LinuxTutorialWebSiteConfig.html
Virtual Hosts:
The Apache web server allows one to configure a single computer to represent multiple websites as if they were on separate hosts. There are two methods available and we describe the configuration of each. Choose one method for your domain:
- Name based virtual host: (most common) A single computer with a single IP adress supporting multiple web domains. The web browser using the http protocol, identifies the domain being addressed.
- IP based virtual host: The virtual hosts can be configured as a single multi-homed computer with multiple IP addresses on a single network card, with each IP address representing a different web domain. This has the appearance of a web domain supported by a dedicated computer because it has a dedicated IP address.
Configuring a "name based" virtual host:
A virtual host configuration allows one to host multiple web site domains on one server. (This is not required for a dedicated linux server which hosts a single web site.)
NameVirtualHost
XXX.XXX.XXX.XXX
<VirtualHost
XXX.XXX.XXX.XXX>
ServerName
www.your-domain.com - CNAME (bind DNS alias www) specified in Bind configuration file (/var/named/...)
ServerAlias
your-domain.com - Allows requests by domain name without the "www" prefix.
ServerAdmin
user1@your-domain.com
DocumentRoot /home/
user1/public_html
ErrorLog logs/
your-domain.com-error_log
TransferLog logs/
your-domain.com-access_log
</VirtualHost>
Last edited by DGPickett; 02-26-2013 at 05:23 PM..
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
Can you please tell me how to identify a 0kb file from a list a files and redirect only those files to a .txt file.
ls -l shows me all the 0kb files...but how to redirect only those files..
Thanks for ur help,
Kumar (3 Replies)
Discussion started by: kumarsaravana_s
3 Replies
2. Shell Programming and Scripting
Hi all,
what will be the code to compare count present in two seperate files
for e.g file (a) contains counts
100
and file (b) contains records
90
since both these files have differnt count so it will display count didnt match
and in case of success it display (5 Replies)
Discussion started by: jojo123
5 Replies
3. Shell Programming and Scripting
Hello Everyone!
I trust you are off to a great week! Trying to output the name and count of each uniquely occurring domain in the current directory for a portion of a script I'm building.
Here's what I'm stuck on:
- Need to find UNIQUE occurences of domains (*@domain.com) in ALL files in... (4 Replies)
Discussion started by: linuxhombre
4 Replies
4. Shell Programming and Scripting
Hey all, I have a file structure that looks something like this:
file1
306708278
88954535
234167885
file2
2012-03-27T12:32:56+00:00 137 Orchotorena 184616310003601409 306708278 es 40.4777947 Majadahonda -3.6416896333333333 0 false atlante83 "<a href=""http://tapbots.com/tweetbot""... (8 Replies)
Discussion started by: dgaff
8 Replies
5. Shell Programming and Scripting
Hey guys,
Sorry for the basic question but I have a lot of files that I want to separate into groups based on filenames which I can then cat together. Eg I have:
(a_b_c.txt)
WB34_2_SLA8.txt
WB34_1_SLA8.txt
WB34_1_DB10.txt
WB34_2_DB10.txt
WB34_1_SLA8.txt
WB34_2_SLA8.txt
77_1_SLA8.txt... (1 Reply)
Discussion started by: Breentax
1 Replies
6. UNIX for Advanced & Expert Users
The company I work for is trying to implement Sudoers.LDAP to centralize their sudoers infrastructure so the access management team and compliance teams don't have to run ragged over all of our servers. The AD team decided it would be better to set up a separate LDAP server rather than put a new... (1 Reply)
Discussion started by: Wolvendeer
1 Replies
7. Shell Programming and Scripting
Hi all,
i have the bash script for remote conection,
for hosts in $(cat /list); do
ssh user1@$hosts "hostname";
done
execute hostname command by all hosts and show standar ouput,
how i can send to file by each host in lists, so
e.g.
$cat list
10.0.0.1
10.0.0.2... (1 Reply)
Discussion started by: aav1307
1 Replies
8. Shell Programming and Scripting
Hi
I have large text file consisting of five columns. Sample of the file is give below:
ed 2-4 12.0 commons that they depended on. मानवों नष्ट किया जिन पर वो आधारित थे।
ed 3-1 12.0 Almost E, but would be over. रचना करीब करीब ई तक जाती है, मगर तब तो नाटक ख़त्म हो... (2 Replies)
Discussion started by: my_Perl
2 Replies
9. Shell Programming and Scripting
I am trying to output all files that are made by this awk to a specific directory.
awk -F '' '{f = $3 ".txt"; print > f}' input.txt
Since the actual data has several hundred files I redirect the output (well tried to) to a directory.
awk -F '' '{f = $3 ".txt"; close($3 ".txt")} print >... (6 Replies)
Discussion started by: cmccabe
6 Replies
10. Shell Programming and Scripting
Input:
I have input file below mentioned.Input file has Yahoo,gmail,yuimn etc..are websites and there are users listed under it. I have many other unique websites but i mentioned just few as below.
For example: Yahoo is website and 123,fsfd are members of website "yahoo". See below input... (19 Replies)
Discussion started by: buzzme
19 Replies
LEARN ABOUT DEBIAN
clfdomainsplit
clfdomainsplit(1) 1 clfdomainsplit(1)
NAME
clfdomainsplit - split Common-Log Format web logs based on domain name
SYNOPSIS
clfdomainsplit [--help] [-i input] [-d defaultfile] [-c cfg-file] [-o directory]
DESCRIPTION
The clfdomainsplit program will split up large CLF format web logs based on domain name. This is for creating separate log analysis passes
for each domain hosted on your server.
OVERVIEW
The input parameter specifies the file to read (default is standard input).
The defaultfile parameter specifies where data goes if it doesn't have a domain (either it has an IP address for the server or it doesn't
have the server-name - the URL is relative to the root of the web server only). The default will be to print them on standard error.
The cfg-file parameter is for specifying the rules for determining what is a different domain name. For example www.coker.com.au belongs
in the same file as coker.com.au and abc.coker.com.au because domain names ending in .au have three major components. The domain names
www.workbenelux.nl and workbenelux.nl belong in the same file because domain names ending in .nl have two major components (as do .com, and
.gov), wheras anything ending in .va belongs to the same organization. The rules are of the form number:pattern which lists the number of
domain parts which are significant (2 for .com and for a simple string comparison, the default will be:
2:com
2:nl
3:au
3:uk
If no config file is specified then it will look for /etc/clfdomainsplit.cfg. Of course comments start with #. Also note that the first
match will be used!
The directory parameter is to specify the location for the files to be created (default is the current directory). I recommend that you
use a directory for this and nothing else as you never know how many files may be created!
EXIT STATUS
0 No errors
1 Bad parameters
AUTHOR
This program, its manual page, and the Debian package were written by Russell Coker <russell@coker.com.au>.
SEE ALSO
clfsplit(1),clfmerge(1)
russell@coker.com.au 0.06 clfdomainsplit(1)