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 - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-01-2004, 11:44 PM   #1
rasgward
Member
 
Registered: May 2004
Location: Virginia
Distribution: ubuntu
Posts: 31

Rep: Reputation: 15
apache help...how do I use


hello,
i just downloaded and installed apache 2, can someone tell me how to use it to set up a web server in step by step. Thanks.-Greg
 
Old 11-02-2004, 01:18 AM   #2
robert644
Member
 
Registered: Aug 2004
Location: internet
Distribution: slackware
Posts: 135

Rep: Reputation: 15
with apache 1

#> httpd

starts the web server. The 'files' are located in

/var/www/htdocs/

what i did is erase everything in that directory, and then i put in my own 'index.html' and such is my 'website'

http://67.171.188.37/
 
Old 11-02-2004, 05:34 AM   #3
rasgward
Member
 
Registered: May 2004
Location: Virginia
Distribution: ubuntu
Posts: 31

Original Poster
Rep: Reputation: 15
so...which ip should i personally use from the internet

Thanks,
So, which ip address should i tell people to use when accessing my machine? Thanks. -Greg
 
Old 11-02-2004, 05:37 AM   #4
rasgward
Member
 
Registered: May 2004
Location: Virginia
Distribution: ubuntu
Posts: 31

Original Poster
Rep: Reputation: 15
I tried...

hey I tried #httpd and it said command not found, but if this helps. after install I typed locate httpd and this is what I found. Maybe this will help you help me.
Thanks again!-Greg

/usr/share/man/man8/httpd.8.bz2
/usr/share/doc/qt-3.2.3/doc/html/httpd-example.html
/usr/share/doc/apache2-manual-2.0.48/programs/httpd.xml.meta
/usr/share/doc/apache2-manual-2.0.48/programs/httpd.html
/usr/share/doc/apache2-manual-2.0.48/programs/httpd.xml
/usr/share/ADVX/advx-migrate-httpd-perl.conf
/usr/share/ADVX/compat/httpd-perl.conf
/usr/share/ADVX/compat/httpd.conf
/usr/share/ADVX/advx-migrate-commonhttpd.conf
/usr/share/ADVX/advx-migrate-httpd.conf
/usr/lib/apache2/httpd.exp
/var/log/httpd
/var/lock/subsys/httpd
/etc/rc.d/init.d/httpd
/etc/rc.d/rc0.d/K08httpd
/etc/rc.d/rc1.d/K08httpd
/etc/rc.d/rc2.d/K08httpd
/etc/rc.d/rc3.d/S92httpd
/etc/rc.d/rc4.d/S92httpd
/etc/rc.d/rc5.d/S92httpd
/etc/rc.d/rc6.d/K08httpd
/etc/httpd
/etc/httpd/2.0
/etc/httpd/2.0/extramodules
/etc/httpd/2.0/conf
/etc/httpd/2.0/logs
/etc/httpd/2.0/lib
/etc/httpd/2.0/modules
/etc/httpd/conf
/etc/httpd/conf/addon-modules
/etc/httpd/conf/vhosts
/etc/httpd/conf/vhosts/VirtualHomePages.conf
/etc/httpd/conf/vhosts/DynamicVhosts.conf
/etc/httpd/conf/vhosts/Vhosts.conf
/etc/httpd/conf/apache-mime.types
/etc/httpd/conf/commonhttpd.conf
/etc/httpd/conf/httpd2-perl.conf
/etc/httpd/conf/httpd2.conf
/etc/httpd/conf/magic
/etc/httpd/conf/magic.default
/etc/httpd/conf.d
/etc/httpd/conf.d/56_mod_disk_cache.conf
/etc/httpd/conf.d/55_mod_cache.conf
/etc/httpd/conf.d/30_mod_proxy.conf
/etc/httpd/conf.d/40_mod_ssl.conf
/etc/httpd/conf.d/00_manual.conf
/etc/httpd/conf.d/41_mod_ssl.default-vhost.conf
/etc/httpd/logs
 
Old 11-02-2004, 05:51 AM   #5
judge_neo
Member
 
Registered: Sep 2004
Location: dumfries, scotland
Distribution: Mandrake10.1 ce
Posts: 65

Rep: Reputation: 15
how about

cd /etc/ && ./httpd start

not an apache expert but maybe this will worl?
 
Old 11-02-2004, 07:43 AM   #6
DertyolBA$HTARD
Member
 
Registered: Sep 2004
Location: USA
Distribution: Slackware 10
Posts: 86

Rep: Reputation: 15
What distro are you using?

my httpd is in /var/lib/apache/sbin

Slackware 10

Quote:
can someone tell me how to use it to set up a web server in step by step. Thanks.-Greg
I think you can help yourself, Greg:

man httpd;man httpd.conf

Then go here http://www.catb.org/~esr/faqs/smart-questions.html
And learn how to ask questions
 
Old 11-02-2004, 08:52 AM   #7
r0b0
Member
 
Registered: Aug 2004
Location: Europe
Posts: 608

Rep: Reputation: 50
/etc/init.d/httpd start
 
Old 11-02-2004, 10:29 AM   #8
rasgward
Member
 
Registered: May 2004
Location: Virginia
Distribution: ubuntu
Posts: 31

Original Poster
Rep: Reputation: 15
thanks

Thanks for all the help. your right DertyolBA$HTARD, i should have spent some time on the google and whatnot searching for help. Thanks for pointing that out. Good site for question asking tips. -Greg
 
Old 11-02-2004, 10:36 AM   #9
DertyolBA$HTARD
Member
 
Registered: Sep 2004
Location: USA
Distribution: Slackware 10
Posts: 86

Rep: Reputation: 15
No problem, have you resolved your issue or have you been able to formulate a question?
 
Old 11-02-2004, 10:58 AM   #10
rasgward
Member
 
Registered: May 2004
Location: Virginia
Distribution: ubuntu
Posts: 31

Original Poster
Rep: Reputation: 15
still working on it

Dirt ol bashtard...no I haven't worked it out yet. I am on a remote computer as we speak so when I get home I will work on it. Thanks. -Greg
 
Old 11-02-2004, 01:27 PM   #11
DavidPhillips
LQ Guru
 
Registered: Jun 2001
Location: South Alabama
Distribution: Fedora / RedHat / SuSE
Posts: 7,163

Rep: Reputation: 58
Your ip address needs to be routable. If you are behind a nat router that's connected to the internet you need for it to forward ports 80 and 443 to your machine. If you have the address supplied by your isp you will use that. If your machine has this address you can get it from ifconfig. If the router has the ip address you can get it from the router.

[david@RedHatLinux david]$ /sbin/ifconfig
eth0 Link encap:Ethernet HWaddr 00:xx:xx:xx:xx:xx
inet addr:192.168.1.241 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:52135 errors:0 dropped:0 overruns:0 frame:0
TX packets:43310 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
RX bytes:37145630 (35.4 Mb) TX bytes:6118881 (5.8 Mb)
Interrupt:11 Base address:0x9000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:4141069 errors:0 dropped:0 overruns:0 frame:0
TX packets:4141069 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:269560724 (257.0 Mb) TX bytes:269560724 (257.0 Mb)

lo:2 Link encap:Local Loopback
inet addr:127.0.0.2 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:535 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 b) TX bytes:32100 (31.3 Kb)


For testing you can use this address on the httpd server...

127.0.0.1


Last edited by DavidPhillips; 11-02-2004 at 01:30 PM.
 
Old 11-03-2004, 06:05 AM   #12
rasgward
Member
 
Registered: May 2004
Location: Virginia
Distribution: ubuntu
Posts: 31

Original Poster
Rep: Reputation: 15
ip?

So what's my ip? the inet address, the broadcast, or the mask? I use the eth0 as far as i know. -Greg
 
Old 11-03-2004, 06:08 AM   #13
DertyolBA$HTARD
Member
 
Registered: Sep 2004
Location: USA
Distribution: Slackware 10
Posts: 86

Rep: Reputation: 15


inet addr = ip addr

lo = loopback

eth0 is the first nic on your box.

Last edited by DertyolBA$HTARD; 11-03-2004 at 06:11 AM.
 
Old 11-04-2004, 12:40 AM   #14
rasgward
Member
 
Registered: May 2004
Location: Virginia
Distribution: ubuntu
Posts: 31

Original Poster
Rep: Reputation: 15
I am still confused

Okay,
So istarted the httpd as far as I know. My ip address is 64.4.118.166
So what now? I created a symbolic link from my /home/greg/ directory to /var/www/catalog so I could access my files.
So what am I supposed to type in to find it on the web and how come I can't get it typing the ip address? -Greg
What' the deal with the ports? I can't figure it out,
 
Old 11-04-2004, 08:17 AM   #15
DertyolBA$HTARD
Member
 
Registered: Sep 2004
Location: USA
Distribution: Slackware 10
Posts: 86

Rep: Reputation: 15
Ports provide a way for one host to hold many sessions on the same box, apache should be listening on port 80 for requests.

As far as connecting to your IP do you have DSL or Cable, and is the computer behind a router on your network?
 
  


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
Mail from Apache being rejected - Cannot route to sender apache@localhost.localdomain jimwillsher Linux - Networking 2 01-19-2006 12:41 AM
Apache 1.3.33 (debian built) and Apache SSL does not respond to the proper ports lqorg_user Linux - Networking 0 11-06-2005 04:11 PM
Strange apache trailing / problem - Slack-current, apache 1.3.33 vamp Linux - Networking 1 01-30-2005 07:28 PM
Apache Webserver 403 Forbidden Errors (User not in apache group?) Mankind75 Mandriva 4 07-08-2004 05:30 AM
apache benchmarks (apache v13 / apache v20) ; large differences between benchmarking markus1982 Linux - Software 0 02-08-2003 10:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:08 AM.

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