LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-23-2006, 06:12 AM   #1
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Rep: Reputation: 15
Using Apache (NEWBIE)


Hi,

I have "apparently" installed apache on my web server, which uses CentOS as its Operating Syetem.

however i am new to apache. And i would like to start hosting my websites on the web server.

It is a rack server with CentOS installed

please advise

brad
 
Old 08-23-2006, 06:15 AM   #2
w3bd3vil
Senior Member
 
Registered: Jun 2006
Location: Hyderabad, India
Distribution: Fedora
Posts: 1,191

Rep: Reputation: 49
well you need to have a look at
/etc/httpd/httpd.conf
file for further configuration.
chkconfig httpd on <--to make it start on a reboot
service httpd restart <--to restart when you make changes to httpd.conf
read docs on setting up apache and ask a specific problem. we will be glad to help out.
 
Old 08-23-2006, 06:29 AM   #3
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Original Poster
Rep: Reputation: 15
I could not find the httpd filen where you said. when i go to
/etc/httpd/ the httpd.conf file is not their. However i can see this file on my system in THREE places(and dont know whether there is more):

/etc/httpd/conf/httpd.conf
/usr/local/apache2/conf/httpd.conf
/usr/local/apache2/conf/original/httpd.conf

which one shall i edit. And what exactly needs to be done?.... i will be looking at the text file.
 
Old 08-23-2006, 08:01 AM   #4
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Original Poster
Rep: Reputation: 15
Hello,

1.
thankyou very much for your previous comments.
I have now gone through the httpd.conf file and made changes. But which one of the ones mentioned above is the one i should edit?

And what is my next step then?

2.
At the moment i have my web server in the office as i am currently working on it, but once it is ready i will take it to our ISP to keep it in one of their rooms with a special connectiona and ip. However i would like to test it here to see if it serves the websites correctly, amongst other things e.g. FTP. How do i can i view the websites i put on this web server from other computers?


kind regards
Brad
 
Old 08-23-2006, 09:11 AM   #5
w3bd3vil
Senior Member
 
Registered: Jun 2006
Location: Hyderabad, India
Distribution: Fedora
Posts: 1,191

Rep: Reputation: 49
my mistake../etc/httpd/conf/httpd.conf
if you want to host a single website, there is no editing needed to be done. all you got to do is place the website contents in the folder /var/www/html.

chkconfig httpd on <--to make it start on a reboot
service httpd restart <--to restart when you make changes to httpd.conf

try using scp instead of ftp. does the same work, but I dont think there is a gui for it. anyhow, setup ftp by installing the rpm package of vsftpd, insert your centos cd and go the place where you have the rpms stored.
mount /dev/cdrom /mnt
rpm -ivh vsftp*.rpm
service vsftpd start
chkconfig vsftpd on

conf file is in /etc/vsftd/vsftd.conf

you can view the system by just typing the ipaddress of it in any other browser, or your own for that matter.
 
Old 08-24-2006, 01:53 AM   #6
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Original Poster
Rep: Reputation: 15
hi,
Thankyou very much for all your help.

i have two websites on my web server, as i have specified on the httpd.conf as follows:

<VirtualHost *:80>
ServerAdmin bradleytosso1@hotmail.com
DocumentRoot /var/www/html/rock-interactive.com
ServerName www.rock-interactive.com
ServerAlias rock-interactive.com *rock-interactive.com
# ErrorLog logs/dummy-host.example.com-error_log
# CustomLog logs/dummy-host.example.com-access_log common
</VirtualHost>
<VirtualHost *:80>
ServerAdmin bradleytosso1@hotmail.com
DocumentRoot /var/www/html/aboutourrock.com
ServerName www.aboutourrock.com
ServerAlias aboutourrock.com *aboutourrock.com
# ErrorLog logs/dummy-host.example.com-error_log
# CustomLog logs/dummy-host.example.com-access_log common
</VirtualHost>


i would like to view the documents i have put in aboutourrock.com.

I got the ip addres of my comp by typing /sbin/ifconfig and looking at inet addr. There where two inet addr, one under eth0 and also under lo. I tried these ip adresses on a web browser on the other computers at work and they did no work.

please advise

brad
 
Old 08-24-2006, 02:06 AM   #7
shibucv
LQ Newbie
 
Registered: Apr 2006
Location: cochin
Distribution: Ubuntu 6.06.1 LTS, Debian Lenny
Posts: 12

Rep: Reputation: 0
hi ... just check that you are able access port number 80 on the server from your end...also see if you are not running any firewall on the server.

[linux@ibm ~]$ telnet IP-address 80
 
Old 08-24-2006, 02:30 AM   #8
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Original Poster
Rep: Reputation: 15
hi,

1. Accessing my website from another computer
i typed telnet IP-address 80 on the terminal window and got this response:
IP-address/80: Name or service not known

i then went to security setttings and disabled my firewall.
Now the response i get is as follows:
IP-address/80: Temporary failure in name resolution

2 vsftpd
i insatlled vstpd. Howeever when i type /usr/local/sbin/vsftpd &
i get the follwoing error:
500 OOPS: could not bind listening IPv4 socket

regards
bard


kind regards
Bradley
 
Old 08-24-2006, 05:23 AM   #9
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Original Poster
Rep: Reputation: 15
Please help
 
Old 08-24-2006, 08:32 AM   #10
w3bd3vil
Senior Member
 
Registered: Jun 2006
Location: Hyderabad, India
Distribution: Fedora
Posts: 1,191

Rep: Reputation: 49
could you paste the output of
chkconfig --list httpd
and
chkconfig --list vsftpd
 
Old 08-25-2006, 03:47 AM   #11
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Original Poster
Rep: Reputation: 15
everything is off
 
Old 08-25-2006, 03:48 AM   #12
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Original Poster
Rep: Reputation: 15
httpd 0ff 1ff 2ff 3ff 4ff 5ff 6ff
 
Old 08-25-2006, 03:49 AM   #13
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Original Poster
Rep: Reputation: 15
vsftpd 1ff 2ff 3ff 4ff 5ff 6ff
 
Old 08-25-2006, 09:14 AM   #14
w3bd3vil
Senior Member
 
Registered: Jun 2006
Location: Hyderabad, India
Distribution: Fedora
Posts: 1,191

Rep: Reputation: 49
you havent followed exactly as I said.
do this
chkconfig vsftpd on
chkconfig httpd on
service vsftpd restart
service httpd restart
 
Old 08-29-2006, 01:51 AM   #15
bradsmiley
Member
 
Registered: Aug 2006
Posts: 37

Original Poster
Rep: Reputation: 15
hi i did as you said abaove. I type it into the terminal window.

Should i include it in the httpd.conf document?

Now i can view my website when i type http://localhost/ or the internal LAN ip address of the computer. I still need to text whether i can view the website from a computer outside the LAN and on the internet, using the external ip of the router. I will do this in the next 20 mins (waiting for my friends to get into work).

However i still get errors when i type the following:

telnet IP-address 80
IP-address/80: Temporary failure in name resolution

/usr/local/sbin/vsftpd &
[root@localhost ~]# 500 OOPS: could not bind listening IPv4 socket


httpd 0: off 1: off 2: on 3: on 4: on 5: on 6: off
vsftpd 0: off 1: off 2: on 3: on 4: on 5: on 6: off

Thanks for all your help.
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Newbie Apache question MontyPY Linux - Software 6 03-03-2005 03:59 AM
newbie apache question... jjd228 Linux - Networking 1 01-08-2004 12:57 PM
Apache install, for the newbie... mattbuechler Linux - Newbie 5 07-01-2003 01:44 PM
Newbie with Apache sienarot Linux - Newbie 5 03-13-2003 12:28 PM
apache newbie p_murugappan Linux - Networking 1 06-20-2001 09:05 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 10:26 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration