Fedora Linux Support Community & Resources Center
  #1  
Old 5th February 2007, 02:47 AM
razvan_vlad Offline
Registered User
 
Join Date: Jan 2007
Posts: 36
how to add websites on a fedora server

hi guys. i know it might seem .. funny.. but.. after i fallowed all the steps in those how to's .. i can't get my websites directed to their specific directories on a fedora 6 server.

i use ISPConfig , and every service is working fine. if i connect to the main address of the server, it does show me the index.html file from /var/www/web.
but after i set-up the virtualhosts based on IP, i can't connect to any other website. is there anything else that keeps track of this path for a website's files , other than httpd.conf .. where you set-up the virtualhosts tags ?

i do have Domain Names for websites and i just want to know how do i have to set-up those things to work. im so confused about this .. redirection to the right file...


and another thing.. anyone knows why after i create a user login in ISPConfig... and then i try to log in using that user name.. ... i can't log in? it gives me wrong username or password. but i put there the right things.

id be thankfull to any help,
Razvan
Reply With Quote
  #2  
Old 5th February 2007, 06:08 AM
Jman Offline
Registered User
 
Join Date: Mar 2004
Location: Minnesota, USA
Age: 31
Posts: 7,909
What is this ISPConfig thing?

What do you mean after you set up the virtual hosts you can't connect to any other website? Can you not access external sites from the server, or when you accessed your sever by IP it didn't serve web pages?

Is this IP based or name based? See the Apache virtual host documentation for the difference.
Reply With Quote
  #3  
Old 5th February 2007, 06:12 AM
razvan_vlad Offline
Registered User
 
Join Date: Jan 2007
Posts: 36
it is IP based. what i mean is that after i set up the virtual hosts.. , i can't get the right site i want from my server. it does work just for the index.html page in the /web/html directory.
for example.. i have 2 websites on my server and i gave each one an IP. if i go online from other computer i can't connect to any of those.

the ISPConfig is the control panel.
Reply With Quote
  #4  
Old 5th February 2007, 06:47 AM
marcrblevins Offline
Registered User
 
Join Date: Jun 2006
Location: Texas
Age: 46
Posts: 4,167
Are you using dynamic ip addresses for both site. Can you ping both IP addresses?
Reply With Quote
  #5  
Old 5th February 2007, 07:03 AM
razvan_vlad Offline
Registered User
 
Join Date: Jan 2007
Posts: 36
no. i don't use dynamic ip. i only have static ips. as i said.. i can reach the server from internet, but just for the defult page (index.html). if i change that with an other page.. i can get that one. but i want to have more websites on my server and the thing is that i can't reach them.
anyone knows all the steps and can guide me through this? do you guys have any .. "how to.." document .. with all the steps required to add websites in fedora??? and i mean.. ALL THE STEPS.. cause.. .. .i found lots of articles saying.. how to set up virtual hosts.. .. or.. multi-ip for a server.. but.. no article saying exactly how to make all the settings.. step-by-step.. .. to get a website installed on a server and running online.
Reply With Quote
  #6  
Old 5th February 2007, 08:28 AM
zivko_sudarski Offline
Registered User
 
Join Date: Feb 2007
Location: Novi Sad
Age: 34
Posts: 88
install Webmin

go to http://www.webmin.com/
and download
webmin-1.320-1.noarch.rpm

rpm -ivh webmin-1.320-1.noarch.rpm
then : https://localhost:10000 login with your root password.....
this is GUI for configuring Apache.......

See where is doc_root for host that you create....
Reply With Quote
  #7  
Old 5th February 2007, 01:12 PM
michaelsmith Offline
Registered User
 
Join Date: Feb 2007
Posts: 22
I also have this problem. I have a fresh install of Fedora core6 setup as a web server. Now I have setup virtual host for my 3 web sites. I have tried both name based and ip bases virtual hosts and both fail to work. Now if I connect to the loacl host I get my default web page in /var/www/html/ when I try any other of my sites it fails. Now the interesting thing is that the httpd gui doesn't change the httpd.conf in etc/httpd/conf/ but instead changes /etc/httpd/conf.d/system-config-httpd.conf ????? I have a dynamic dns pointing to my net ip and the IP reflects the correct address. I have setup forwarding on my speedtouch and it is open on portscan. I also tesed it with my Windows pc with firewall and it showed up stealth as it should. This means the speedtouch is working. So the problem looks to be with virtual hosting. I tried manual configuration of httpd.conf and that didn't work. I have followed the Howtos and the man pages with no result. I should atleast see my default test page but that doesn't work from the internet. I can do it locally only. Any ideas???? I have been using linux for a while and pre fer to manually configure most settings. I am currently working on my DNS skills hoping that this is the problem .. I also turned off ipv6tables and iptables to see if that fixed things//


Michael Smith
Reply With Quote
  #8  
Old 5th February 2007, 01:24 PM
razvan_vlad Offline
Registered User
 
Join Date: Jan 2007
Posts: 36
hey michaelsmith,

hmm.. i donno anything about that.. speedtouch but if you say it is working then.. it should work.
the thing is that.. i can access my default webpage (/var/www/html/index.html ) from the outside internet.

the thing is that:
1) you must have a registered DNS (go to www.dyndns.com they have free static or dynamic dns)
2) you must edit your hosts file in /etc directory, and add the ip of the server there, specify the domain and host name (be aware to have every ip with it's own host and domain in a single line)
3) again.. check that if you use a router, it does have the http port (80) opened
4) the default page should work without virtual hosts.
5) try again
Reply With Quote
  #9  
Old 5th February 2007, 01:44 PM
razvan_vlad Offline
Registered User
 
Join Date: Jan 2007
Posts: 36
the thing is that i tried to access the websites .. and they work just in my local network. (i have a network .. with a router. the router does have http port opened. )

the outside internet can't access the websites. it can access only the default webpage.

is there anything that i'm doing wrong?

and.. an extra detail.. when you register the DNS, it asks u for an IP. what IP should i use there? the server's ip address? the router's IP address? or the virtual IP that i gave on the derver, for that particular website?
Reply With Quote
  #10  
Old 5th February 2007, 01:57 PM
michaelsmith Offline
Registered User
 
Join Date: Feb 2007
Posts: 22
from what I understand is that if you see the default webpage from the internet the virtual hosting should work. I use dyndns too I have the correct ip stored at the DNS. My router points port 80 tcp >to my NIC 10.0.0.200 on my server. Apache should be able to resolve the rest from the http header info contained in the data comming in on port 80 to the NIC ...and yours does because you can see your default page....I wish I could... I can't connect even with the hosts file entered. I am going to setup a local DNS I think.

Michael Smith
Reply With Quote
  #11  
Old 5th February 2007, 02:03 PM
razvan_vlad Offline
Registered User
 
Join Date: Jan 2007
Posts: 36
hmm i don't have an ideea what is wrong with urs... but... i guess u can access internet from the server right? if you can't.. you have to specify the right dns provided from your ISP. and yes.. i do have set-up a local DNS on my router.. (but be aware.. those have to be the DNS from your ISP; the router usually recognize them .. if not.. on your windows computer.. run a cmd and type in "ipconfig /all"..
this would show your configuration. and ur DNS.
Reply With Quote
  #12  
Old 5th February 2007, 02:19 PM
michaelsmith Offline
Registered User
 
Join Date: Feb 2007
Posts: 22
Computer 1 me Nil
Reply With Quote
  #13  
Old 5th February 2007, 05:44 PM
tw56 Offline
Registered User
 
Join Date: Oct 2005
Location: GA, USA
Posts: 311
I have set it up in the past and all works well with name based virtual hosting. The ip in dyndns to point to is the ip of your router. Then any name based virtual hosts can be reached by that same ip address. In the router config you point requests for port 80 to the internal ip of the fedora server. Then all requests for port 80 are forwarded to the fedora server and it directs it to the correct folder. The default folder is /var/www/html. My website no 1 is at /var/www/website1, and my website 2 is at /var/www/website2. Website 3 is at /var/www/website3. You must set up virtual hosting in the /etc/httpd/conf/httpd.conf file. I hope this will give you guys a start on figuring it out.
Reply With Quote
  #14  
Old 5th February 2007, 06:02 PM
tw56 Offline
Registered User
 
Join Date: Oct 2005
Location: GA, USA
Posts: 311
In section 3 of the httpd.conf file.
NameVirtualHost *:80
# Virtual host 0
<VirtualHost *:80>
DocumentRoot /var/www/html
ServerAdmin you@yourdomain.com
DirectoryIndex index.html index.php index.htm index.shtml index.php3 index.phtml home.html
ServerName yourregisteredname.dynalias.net
</VirtualHost>

# Virtual host 1
<VirtualHost *:80>
DocumentRoot /var/www/yourvirtualhostname #I name the folder the name of the virtualhost.
ServerAdmin you@yourdomain.net #So it is at /var/www/yourvirtualhostname
ServerName yourotherregisteredname.dynalias.net
DirectoryIndex index.html index.htm index.shtml index.html.var welcome.html
</VirtualHost>

Good luck. Hope I didn't have any typos and you can make sense of it.
Reply With Quote
  #15  
Old 5th February 2007, 06:16 PM
tw56 Offline
Registered User
 
Join Date: Oct 2005
Location: GA, USA
Posts: 311
PS . After you make changes to the httpd.conf file.

service httpd restart
Reply With Quote
Reply

Tags
add, fedora, server, websites

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
fedora 8 showing websites vs windows websites FreeAngel Using Fedora 2 13th January 2008 02:04 PM
Multiple websites on same server straytalk Servers & Networking 4 16th February 2007 01:17 PM
Unable to browse websites other than Fedora krokos Using Fedora 2 26th November 2006 09:02 PM
Fedora only goes to some websites? agentstewie Servers & Networking 19 31st August 2006 04:16 AM
Fedora Websites and Representation... Mtnear Fedora Focus 3 14th March 2006 02:49 AM


Current GMT-time: 20:51 (Sunday, 25-06-2017)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat