Skip to content. | Skip to navigation

Personal tools
You are here: Home Docs howto Setting group write permissions using SSH

Setting group write permissions using SSH

Use SSH to set/fix your static web site files' permissions so others can edit, add and update web pages.

Webmaster's Note: This only applies until we change the way we access files on www/athena. We recommending using SecureSSH (or WS_FTP Pro using the sftp mode) to transfer files to the server. Both of the programs can be set to correctly transfer files to the server.

chmod

Quick version: (Assumes the files you want to share are in the '/web/content/www/my-site/' directory.)

  • log into the web server with secureSSH
  • type ' cd /web/content/www/ '
  • Then type ' chmod -R g+rw ./my-site '

To see what this looks like, type, ' ls -la ' in your directory:

ls -la
drwxr-sr-x   5 lusero01 w-uol      4096 Jul 06 09:50 student
-rw-r--r--   1 lusero01 w-uol      7985 Jul 07 15:40 student.htm
-rw-r--r--   1 lusero01 w-uol     10151 Jul 18 16:59 studentlinks.htm
-rw-r--r--   1 lusero01 w-uol     10349 Jan 19 2001  taxfaq.htm
-rw-r--r--   1 lusero01 w-uol     10799 Jan 18 1999  taxpage1.htm
-rw-r--r--   1 lusero01 w-uol      7056 Jul 07 15:40 warning.htm

If you want to share files with others, and your directory list looks kind of like this, it won't work.

For group sharing to work on files this: ' -rw-r--r-- ' should look like this ' -rw-rw-r-- '.

For group sharing to work on folders/directories this: ' drwxr-sr-x ' should look like this ' drwxrwsr-x '.

The fix is, to use 'chmod' to change the file permissions. Your file transfer client may do this, too.

To change the permissions for just one file or folder so it is group-writable, type:

chmod g+rw the-file-or-folder-name

Caveats

  • If you are running a CGI, changing the group permissions may break it!
  • Dreamweaver is a great web page building program, but will not transfer the files correctly.
Document Actions