Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I was trying to delete some torrents that I had downloaded with transmission-daemon and was unable to from my samba share on windows due to transmission's default file creation permissions.

I figured the best solution was to sudo chmod -R 0777 /media/Storage (my drive with samba) but apparently not.

This locked both my windows user and my user on my ubuntu server out of the drive completely, with a message saying ls: cannot access /media/Storage: Permission denied.

I am able to login as root with sudo bash and make changes however I am uncertain as to how to make my drive accessible again.

Doing a ls -ld on the directory shows drwsrwsrwx 39 root root 4096 Nov 17 21:20 /media/Storage.

I have also done a: sudo chown -R [username]:[group] /media/Storage and a sudo chmod -R u+rw /media/Storage. Both commands executed without errors but had no good effect.

I am running ubuntu-server 12.10 so no GUI available. Any ideas?

share|improve this question
add comment

1 Answer

You have the SetUID and SetGID bits set, which are causing things to be owned root.root, and otherwise making you have a Bad Day.

sudo chmod -R u-s,g-s /media/Storage should fix you up.

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.