I accidentally changed to only write permission on /usr/bin... please Help!

 
Thread Tools Search this Thread
Operating Systems OS X (Apple) I accidentally changed to only write permission on /usr/bin... please Help!
# 1  
Old 02-03-2010
Data I accidentally changed to only write permission on /usr/bin... please Help!

I accidentally changed to sudo chmod a=w to my /usr/bin folder on my macbook with OS 10.5.8... Please help! I can't even get into a terminal correctly cause it displays:

Code:
-bash: uname: command not found
-bash: cut: command not found
-bash: uname: command not found
-bash: cut: command not found
-bash: /usr/bin/perl: Permission denied
-bash: [: too many arguments
-bash: grep: command not found
-bash: grep: command not found
-bash: cut: command not found
-bash: grep: command not found
-bash: cut: command not found
-bash: grep: command not found
-bash: /Users/ro/.gem/ruby/1.8/bin: No such file or directory
RosBook:~ ro$

And when I trying to changed back the permission set it doesn't even recognize the "sudo" command... I have tryied several times to Repair Disk Permissions using disk utility but it doesn't seem to work either, can someone please help me through this?

Many thanks

Last edited by pludi; 02-03-2010 at 02:36 PM.. Reason: code tags, please...
# 2  
Old 02-03-2010
On the OSX, isn't chmod in the /bin directory?
# 3  
Old 02-03-2010
Yes, the thing is I need to use the sudo as follow:

RosBook:~ ro$ sudo chmod 777 /usr/bin
-bash: sudo: command not found

But sudo is not found given that I don't have neither read permission nor execution permission ....
# 4  
Old 02-03-2010
boot from dvd and change the permissions back...
# 5  
Old 02-03-2010
Quote:
Originally Posted by DukeNuke2
boot from dvd and change the permissions back...
My guess is he does not have the boot disks. I certainly don't have my OSX boot disks or DVD.

If not, another option might be to grab the required binaries from the Apple Darwin Open Source download site.

I would upload some of what he needs, but I use an older PowerPC iMac, not an Intel box.
# 6  
Old 02-03-2010
hmmm... but if the dvd IS available, it should be an easy task to repair the permissions. if not... damn Smilie
# 7  
Old 02-04-2010
Cheers! It worked wonderfully Smilie
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. BSD

FreeBSD: /usr/bin/ld not looking in /usr/local/lib

I'm not sure if this is the default behavior for the ld command, but it does not seem to be looking in /usr/local/lib for shared libraries. I was trying to compile the latest version of Kanatest from svn. The autorgen.sh script seems to exit without too much trouble: $ ./autogen.sh checking... (2 Replies)
Discussion started by: AntumDeluge
2 Replies

2. Red Hat

Accidentally changed ownership-unable to SSH into server.

Hi All, Accidentally changed ownership of /var directory as root :eek: thinking that I am changing ownership of var directory in other location in the file system:D.Now unable to SSH into the server:(. By gods grace I was able to regain the access again as server was in control of me at that... (5 Replies)
Discussion started by: shiek.kaleem
5 Replies

3. Shell Programming and Scripting

Script to echo "File permissions or ownership changed from required " when accidentally changed.

Hi All, I have to work in the late nights some times for server maintenance and in a hurry to complete I am accidentally changing ownership or permission of directories :( which have similar names ( /var in root and var of some other directory ).:confused: Can some one suggest me with the... (1 Reply)
Discussion started by: shiek.kaleem
1 Replies

4. OS X (Apple)

When to use /Users/m/bin instead of /usr/local/bin (& whats the diff?)?

Q1. I understand that /usr/local/bin means I can install/uninstall stuff in here and have any chance of messing up my original system files or effecting any other users. I created this directory myself. But what about the directory I didn't create, namely /Users/m/bin? How is that directory... (1 Reply)
Discussion started by: michellepace
1 Replies

5. Solaris

How do I link ld in /usr/ucb/ to /usr/ccs/bin?

Hi all, below is the problem details: ora10g@CNORACLE1>which ld /usr/ucb/ld ora10g@CNORACLE1>cd /usr/ccs/bin ora10g@CNORACLE1>ln -s /usr/ucb/ld ld ln: cannot create ld: File exists ora10g@CNORACLE1> how to link it to /usr/ccs/bin? (6 Replies)
Discussion started by: SmartAntz
6 Replies

6. Solaris

/usr/bin has been changed with 777 permission

Hello Guruz, Relay bad condition :mad: Some has changed the permission to 777 recursively for /usr/bin directory by mistake. Now all the permission looks to be 777 on /usr/bin Hence I am so many system related errors as 1 show below. When I am trying to change the password, I am getting... (5 Replies)
Discussion started by: bullz26
5 Replies

7. UNIX for Dummies Questions & Answers

Difference between /bin, /usr/bin, /sbin ?

Hi All, Can somebody tell me the difference between /bin, /usr/bin, /sbin ? Thanx in advance, Saneesh Joseph (3 Replies)
Discussion started by: saneeshjose
3 Replies

8. Solaris

changed shell of the root accidentally

Hi All, I have changed the shell of the root accidentally to /sbin/bash :mad: How do I change that? :( To change that I need to go to ok prompt I think, and there I need to mount the root file system in order to make changes to the respective file. Can any one please suggest how do I do... (4 Replies)
Discussion started by: pintu_asim
4 Replies

9. UNIX for Dummies Questions & Answers

/bin/sh: /usr/bin/vi: No such file or directory when doing crontab

I just set up an ftp server with Red Hat 5.2. I am doing the work, I'm baby stepping, but it seems like every step I get stuck. Currently, I'm trying to set up a crontab job, but I'm getting the following message: /bin/sh: /usr/bin/vi: No such file or directory. I see that vi exists in /bin/vi,... (3 Replies)
Discussion started by: kwalter
3 Replies
Login or Register to Ask a Question