Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

drayman86

macrumors newbie
Original poster
Jun 8, 2007
24
0
Lansing, Michigan
Is there a way to unlock multiple items in a folder at the same time? I've somehow got nearly 850 items in a Trash folder that I'm trying to delete, and they're all locked. It'll take 'till Doomsday to unlock them all individually.

Thanks!
 
Pull them out into another folder. Then get info on the folder and change permissions to everyone for everything, then select, apply to enclosed files and folders.

If that doesn't work, open terminal and CD to the folder in question. Once inside type 'chmod 777 *' that should do it.

TEG
 
I think if you empty trash securely, you won't need to unlock them. (it will be a slow process but you don't have to do anything manually)
 
Thank you TEG and jplan2008.

I'll try the secure empty trash first. It's been, like, forever since I attempted programming commands...back in 1990 I took a DOS class in undergrad, it's been that long.

TEG, can you direct me to a spot on the forum that illustrates the basics of Terminal commands in case I need it?

Thank you both again.
 
Just create a new folder in your Home Folder, copy the items into it. Then use Get Info to set the Mode.

Or open Terminal and type each line

cd foldername
chmod 777 *

Now close terminal and drag to trash and empty it.

TEG
 
TEG, I appreciate your reply and patience.

I CAN'T get these locked files out of the trash. If they're locked in the trash and dragged into the created folder, they COPY instead of move. If I attempt to drag the entire folder that contains the locked files out of the trash and onto the desktop, NOW I have the entire folder of locked files copied onto the dekstop AND the original in the trash.

Even using the Edit Command/Cut/Paste won't get them there. When highlighting a locked file and clicking Edit, the Cut option is greyed out; only the copy option is available.

Is this typical of locked files? I can't seem to get the Terminal to CD to the Trash.

Yikes.....:confused:
 
Hi TEG:

Looks like I made it into the Trash folder. Can you please guide me from here?

Last login: Wed Aug 13 07:02:10 on ttyp1
Welcome to Darwin!
You have new mail.
Heywood-jablowme:~ drayman86$ cd /
Heywood-jablowme:/ drayman86$ cd .trashes
Heywood-jablowme:/.trashes drayman86$

I've previously tried to drag the folder in question (wojoinm) back to the desktop to attempt the maneuver you previously described, but as I said in a previous post the folder COPIES to the desktop instead of moving, so now I end up with TWO folders of locked files.

Can I simply execute the chmod 777 * for the entire Trash folder? I can't seem to get Terminal to let me into the folders with the locked files:

Last login: Wed Aug 13 07:02:10 on ttyp1
Welcome to Darwin!
You have new mail.
Heywood-jablowme:~ drayman86$ cd /
Heywood-jablowme:/ drayman86$ cd .trashes
Heywood-jablowme:/.trashes drayman86$ cd wojoinm
-bash: cd: wojoinm: No such file or directory
Heywood-jablowme:/.trashes drayman86$

Thanks again for you help and patience.
 
Heh, something that may save you a lot of time: Hold down option while emptying the trash. Locked items will be deleted without any warnings.

jW
 
I think if the chmod doesn't work, you'll need to sudo it.

sudo - super user do, it also requires the administrator's password.

It's easy to mess stuff up with sudo, so use it with caution.

I recommend doing this:

Make sure you're in the trash folder. If the files in your trash are directories and those directories have subdirectories, you might need to change permissions on all of them. Easiest way to do this is:

chmod -R 777 *

What this does is changes the permissions of everything to 777, and will recursively do so for every item (even in subdirectories).

Once that's done do:

rm -rf foldername

In this case, do not use *, this is because it will delete everything in the trash, and sometimes it can mess things up. The r is for recursive and f is for force. These are explained below.

Whenever I'm working on a friend's Mac, and they have stubborn folders/files that need to be deleted, I do this:

Make sure they are on the desktop, if I cannot click and drag, I use terminal for everything.

cd <to where the file/folder is located>
(optional) chmod -R 777 <file/folder name>
sudo rm -rfv <file/folder name>

So I locate the file, change the permissions and then to make sure I delete it, I sudo rm (remove) -rf (recursively and force) the file/folder. the force is used in addition to sudo to pretty much tell the Mac that I mean serious business. I use v (verbose) to allow me to see what files are being deleted. I'm a bit of a log nerd, so I like to see what it does.

I'm sorry if I'm stepping on TEG's parade, or ranting to something that was completed; I just like it when people explain how they do things.
 
Heh, something that may save you a lot of time: Hold down option while emptying the trash. Locked items will be deleted without any warnings.

jW


JOY ! ! !

Thanks, jW. Thanks also to TEG & LtRammstein who took the time to help a Mac newbie. Karma to all.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.