Previous Thread
Next Thread
Print Thread
Rate Thread
#265709 12/31/2003 11:11 AM
Joined: Apr 2003
Posts: 359
Enthusiast
Enthusiast
Joined: Apr 2003
Posts: 359
I'm VERY new to the world of puTTy and SSH and I'm looking for the correct format in setting the file permissions of all files inside of one directory at once instead of setting them for each file.

Any help on this is greatly appreciated.

Sponsored Links
Joined: Feb 2002
Posts: 2,286
Veteran
Veteran
Joined: Feb 2002
Posts: 2,286

chmod -R 777 /your-directory

Where chmod is the command
-R means recursive
777 is the level of permissions
/your diretcory would include all files in that directory.


Fans Focus - Focusing on Fans of Sport

(Okay - mainly football (the British variety wink at the moment - but expanding all the time....)
Joined: Feb 2002
Posts: 2,286
Veteran
Veteran
Joined: Feb 2002
Posts: 2,286
BTW chmod --help should give you a few tips


Fans Focus - Focusing on Fans of Sport

(Okay - mainly football (the British variety wink at the moment - but expanding all the time....)
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
This is a great site too:

http://www.ss64.com/bash/

click on chmod for more info.

Joined: Apr 2003
Posts: 359
Enthusiast
Enthusiast
Joined: Apr 2003
Posts: 359
Awesome feedback on this one guys and it's much appreciated!

It was a piece of cake with the information you all provided and all files are done.

Again, thank you for the responses.

Sponsored Links
Joined: Apr 2003
Posts: 359
Enthusiast
Enthusiast
Joined: Apr 2003
Posts: 359
[]Ian_W said:

chmod -R 777 /your-directory

Where chmod is the command
-R means recursive
777 is the level of permissions
/your diretcory would include all files in that directory. [/]

I'm trying to run this on a directory with over 30 files and I'm not quite sure what the command line would be.

I'd like to change all of my files inside of my ubbthreads/avatars directory to 777.

So, would I need to change directories all the way til I come to ubbthreads or go to ubbthreads/avatars and then run the command in SSH:

chmod -R 777 /avatars

Joined: Jun 2002
Posts: 670
Code Monkey
Code Monkey
Offline
Joined: Jun 2002
Posts: 670
I don't know why you want them to be 777. It should be 666, just like the graemlins and post icons. Anyhow, the command you need is:

chmod 666 avatars/*.gif
or just
chmod 666 avatars/*

You can replace 666 w/ 777 if you really need the files to be executable, which I doubt

EDIT:
Here's a couple commands I use to set permissions quickly:

chmod 666 stylesheets/*.css includes/*.php filters/* languages/*/*.php images/icons/*.gif images/graemlins/*.gif images/avatars/*.gif theme.inc.php

&

chmod 777 includes/ stylesheets/ images/icons/ images/graemlins images/avatars/

Did I miss any? BTW: Those were just TWO commands, albeit long. Very useful however, and using the command line completion (the tab key), it goes very quickly

Last edited by donJulio; 01/21/2004 1:06 AM.
Joined: Apr 2003
Posts: 359
Enthusiast
Enthusiast
Joined: Apr 2003
Posts: 359
"donJulio", thanks and yes you are right...they should be 666.

Again, thanks for sending me those commands....awesome!


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
Gizmo
Gizmo
Portland, OR, USA
Posts: 5,833
Joined: January 2000
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)