Apache Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsSystem AdministrationApache Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old August 24th, 2000, 09:50 AM
Wytse Wytse is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2000
Posts: 5 Wytse User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Hi,

I've made a Linux server with Suse 6.4. The server runs apache, php and MySQL.

Everything works fine except that if I upload files to my web directory with ftp I cannot access them. Apache gives the error that I haven't got the permission to read them. If I check the files in the webdir with ls -l it gives that only the root can read the uploaded files.

My question is: how can I upload files with the correct permissions (so everyone can read them)?

Greetings,

Wytse

Reply With Quote
  #2  
Old August 24th, 2000, 10:48 AM
freebsd
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
>>If I check the files in the webdir with ls -l it gives that only the root can read the uploaded files

So what was the output of ls -l for that?

Reply With Quote
  #3  
Old August 24th, 2000, 11:02 AM
Wytse Wytse is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2000
Posts: 5 Wytse User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
>>So what was the output of ls -l for that?

something like:

-rw------- 12 root users .....

I know that I can change it but I don't want that because I want to upload the files from a remote system. I can't always access the server.

greetings,

Wytse

Reply With Quote
  #4  
Old August 24th, 2000, 12:07 PM
freebsd
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
I am not familiar with Suse, but you need to check your /etc/login.conf file if there is one. Also "man umask".
The umask value should be changed to 022. Your umask value is set to 077 currently.
After making the change, run "cap_mkdb /etc/login.conf"

For file:
The umask (022) is to be subtracted from 666 -> 644

For dir:
The umask (022) is to be subtracted from 777, that is 755

[This message has been edited by freebsd (edited August 24, 2000).]

Reply With Quote
  #5  
Old August 25th, 2000, 06:47 AM
Wytse Wytse is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2000
Posts: 5 Wytse User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Thanks for your reply but it still doesn't work:

> I am not familiar with Suse, but you need to check your /etc/login.conf file if there is one.

There is none

> The umask value should be changed to 022. > Your umask value is set to 077 currently.
> After making the change, run "cap_mkdb /etc/login.conf"

The umask value is already 022

Wytse

Reply With Quote
  #6  
Old August 25th, 2000, 01:02 PM
freebsd
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
>>There is none

Then check your shell configure file (in your home directory)

With umask 022, it doesn't matter whether you are ftping to your account or creating new file or new dir, the permissions are the same.
You can "cd ~"
then "touch file"
then "ls -l file"
If such file is -rw------- (600), then umask is 077.
Likewise, if it's -rw-r--r-- (644), then umask is 022.

You need to read manpage to find out how to configure this.

Reply With Quote
  #7  
Old August 26th, 2000, 06:23 AM
Wytse Wytse is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2000
Posts: 5 Wytse User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
> Then check your shell configure file (in your home directory)

There is none

> With umask 022, it doesn't matter whether
> you are ftping to your account or creating
> new file or new dir, the permissions are
> the same.
>
> You can "cd ~"
> then "touch file"
> then "ls -l file"
> If such file is -rw------- (600), then
> umask is 077.
> Likewise, if it's -rw-r--r-- (644), then umask is 022.

If I create a file with toch it has: -rw-r--r-- but if I upload the file with FTP it has: -rw------- ... so it seems to matter ...

Wytse

Reply With Quote
  #8  
Old August 26th, 2000, 02:42 PM
freebsd
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
Which FTP server? If proftpd, check this out -> http://www.proftpd.net/docs/configuration.html#Umask

Reply With Quote
Reply

Viewing: Dev Shed ForumsSystem AdministrationApache Development > Permissions problem


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway