Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
This is a stupid question but here goes:
Im running mandrake 7.2.
When I type http://localhost or http://ip_address in a browser I get the apache page.
I want to replace this page with my own page but I dont know where this is stored on my machine
Where is it located & in which directory ???????
Can someone please tell me
Sorry, I spoke to soon, I still cant find it.
I cd to /usr/local but apache isnt there.
Any ideas where else it might be ?
All I have in /usr/local is:
bin
doc
games
include
info
lib
libexec
man
mysql
mysql-test
sbin
share
sql-bench
src
var
As far as I know Apache is working cos when I view it in a browser it says "if you can see this page, Apache is set up properly".
Nice one, I got it.
/var/www/html is what I was looking for.
The reason I didnt read the man pages is because I thought the installation was corrupt as there is no 'htdocs' anywhere on my system.
I tried find the way you said infernal but it couldnt find it, & locate didnt find it either.
Thanks again for helping everyone.
P.S. Am I supposed to stick my public_html directory in /var/www/html, or is that a bad idea security wise ??
Ye I did make a non root user & I also set up a public_html directory in it.
I just didnt know where the option was so I could access it using http://localhost/~amp2000
I will soon though
Guess I should read the documentation a bit more...
htdocs is for newer versions of apache. EXTREMELY newer. You've got to be right up to date. If you're running the default apache set up by pretty much any distro, including Mandrake 8.1, your webroot is, as was mentioned, /var/www/html, not apache/htdocs.
Citizen Bleys: you wrote
.................................................................................................... .....
I tried creating a directory called /home/citizenbleys/public_html, but http://toshiharu/~citizenbleys/ doesn't work
.................................................................................................... .....
Check out the 5th line in vinaypai's last post ,
You have to edit something in httpd.conf
The easiest way to find your web root directory is
1. $locate httpd.conf ( or find / -name 'httpd.conf' if locate doesn't find anything for you ).
Your output of locate (or find) will have the full path to the httpd.conf file use this in place of /path/to/httpd.conf
2. $grep DocumentRoot /path/to/httpd.conf
this will turn up DocumentRoot "/path/to/your/web/root/directory"
To enable user home directories. Accessable by http://127.0.0.1/~username :
1. $vi /path/to/httpd.conf
2. do a search (use the '/' key) for UserDir this will turn up a spot with (use the 'n' key to advance to next search result occurence) about 12 lines commented out. Just remove the comment character.
3. #/etc/rc.d/init.d/httpd restart
And your done !
note: some of these commands might need to be done as root instead of username
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.