Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm not a Unix expert, but I have been using it for a few months now, and these errors are boggling my mind. My scenario is as follows: I copied a bunch of files over to a unix server from my normal user account (let's call it "bob"), and now I need to run a script on them as a different user (let's call it "joe") that involves using "touch" on them. I've chmoded their permissions to 777 and did the same to the folder they're in. Nevertheless, when I run touch on them as joe, I get the operation not permitted error. When I run touch as bob it works.

So fine. I figured I'd get to the bottom of that issue later, and would just chown the files to joe for now, just to get my project finished. No can do. Running chown as bob on files that bob owns also returns "operation not permitted!!!" Now I'm just completely confused.

So, really, I have two questions:

1. Why can I not touch files as a user who does not own those files even when I have write permissions on them? What other permissions do I need? I thought a chmod 777 would give me everything I could possibly require.

2. Why can I not chown files I own to a different user? This has worked for me on Ubuntu before. What about this Unix server is preventing this, and how can I get around it?

I'd really appreciate any help you guys can give me.

share|improve this question
    
What distribution is this? –  Ether Nov 29 '10 at 18:47
    
It would be helpful to know exactly which Unix and what version. –  phogg Nov 29 '10 at 19:00
add comment

migrated from stackoverflow.com Nov 29 '10 at 18:47

This question came from our site for professional and enthusiast programmers.

2 Answers

For #2 see this question.

For for #1, works for me. Could the underlying filesystem not support the operation? Is it a network filesystem?

share|improve this answer
add comment

Is user bob able to touch the files?

Are these files currently located in a home directory, ostensibly bob's?

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.