Solved

Apache Configuration

Posted on 2000-04-17
4
195 Views
Last Modified: 2010-04-20
  I've installed Redhat 6.0 on a networked pc.  Samba works fine.  Apache gives me the 'IT WORKED' screen when I hit my site from a workstation web browser (IE5). Ping & telnet works also.
  I cannot, however, make changes to the index file or save anything in the httpd directory. I've gone to the smb.conf file and added 'valid users = {myself}' under {www] share definitions.  I've also given {myself} -privileges -services 'Apache Administration' granted under linuxconf, .  These tabs seem to have no effect.
   The only way I can make changes to index.html is to be logged in at the server console as root and edit with the native netscape browser.
   I'm pretty sure I've got a permissions issue. How do I grant myself editing priviledges? Any help here appreciated!

Thanks - Keith
0
Comment
Question by:stewartkc
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 1

Expert Comment

by:andrewljohn70
ID: 2726078
Hi Kieth,
the files in the http directory all belong to the root.
So if you log in as say 'kieth' you will only be able to view the contents in an editor and not be able to edit and save the file.

To be able to give rights to kieth.
1. log in as root
2. move to the http directory
3. chown -c kieth index.html - this will change the owner of the file index.html to kieth and also show you a comment.

Hope this is what you are looking for.
Happy Apatching!  :)
0
 

Expert Comment

by:castleinfo
ID: 2726087
I'm a little confused.. How else would you edit apart from opening the file ?

Apache security is for people accessing through the web, not for file access.
File access is controled by standard group (nobody) user(nobody) other(none) access.

If you do a chmod 777 filename
this will give everyone access to the file concerned.

Your best bet is to set up Samba then you can access the files over the network.

0
 

Accepted Solution

by:
skyValley earned 100 total points
ID: 2728524
Hello Keith,

Let's try to clarify a few things.

First, check the file permissions for index.html. Assuming it is located in \home\httpd\html issue the command:
ls -l /home/httpd/html/index.html

Look at the file permissions and the owner and group. The file permissions (in case you do not know this) are read, write and execute (r, w and x respectively) and listed for the user, group and others. For example the output of this command on my system is:
-rw-r--r-- 1 root    root    174 Feb 11 08:52 /home/httpd/html/index.html

Which means that root has read and write access but everyone else just has read access. In addition root is the owner and the root group is the group of which it's members can access this file.

You can change file rights with the chmod command. See your man pages for information or someplace like unixhelp (http://unixhelp.ed.ac.uk/ to look at file permissions. As someone else previously mentioned, you can use chmod 777 to grant all access (read, write and execute) to user, group and others.

You can change the owner or the group using the chown or chgrp commands respectively.

You can see what group your current user is a member of with the id command.

Good Luck,
Scott
0
 

Author Comment

by:stewartkc
ID: 2732907
Sky, Thanks for the help. You, at the very least, put me on a path.  Coming from a netware environment makes the crossover a little harder, but some of the concepts are the same.  You don't have to reply, but here's what I did:

Linuxconfig - Group definitions, created 'WEB' group.  Alternate members 'KCS' 'CLS'

Ctrl Alt f1 to prompt-login as root

CD'd to the \html directory

CHOWN :web*
CHMOD g+rwx *

That's all.  Thanks for the pointer to unixhelp.  I've booked it.

If you've got a different method or comments on the above, email me at stewartkc@aol.com.  You get the points!

Tnks again.

Keith
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question