How to change file rights?

Discussion in 'General' started by djkoelkast, Aug 6, 2007.

  1. djkoelkast

    djkoelkast New Member

    Hi,

    I have Debian 4.0 + ISPC but now all files are uploaded through SCP as root, the users can't change/delete files now. How can I change the file rights so the users who log in through FTP can change them?
     
  2. bschultz

    bschultz Member

    run this command as root

    Code:
    chown newusername file.txt 
     
  3. djkoelkast

    djkoelkast New Member

    great! Can I also do this for all files/folders in that particular webXX/ folder?
    and username is the ftp login name?
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Yes, when you use the -R switch:

    chown -R newusername file.txt

    Yes.
     
  5. ustoopia

    ustoopia Member

    to change the group also (i advise to do so) use this:

    Code:
    chown -R web16_user:web16 /var/www/web16/web
    In this example I used web16 but ofcourse you must use something else there
     
  6. falko

    falko Super Moderator Howtoforge Staff

    If you want to change the group, but not the owner, you can also use
    Code:
    chgrp -R web16 /var/www/web16/web
     
  7. djkoelkast

    djkoelkast New Member

    cool, thanks a lot
    I don't use webXX prefix, I don't know which site is which web number, I use the domainname as prefix but I understand what to do ;)
     

Share This Page