setting permissions on a file after uploading via FTP
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
setting permissions on a file after uploading via FTP
Hey everyone, first post...
I've been using linux for about a month now, still pretty new but I enjoy learning. I'm using proftpd as my ftp server(personal use)-installed from rpm, everything is working great as far as that goes. I'm also using fedora core2-if it's even relevant.
my question is...
When I upload a file from another computer to my computer, using an ftp client, everything goes good, except when I get home I can't edit the file that I uploaded. I noticed that the permissions are faded out and there's no way to change them.
What I'm wondering is...
Do I have to change the permissions on the file before I send it with the ftp client, or if that's not possible then how do I make it to where when I send a file from a computer to my home computer I'll be able to edit it.
I can't think of any config files or anything like that I need to post, but if I should please let me know..
The files should be owned by whoever sent them there. So if you had an account named Focker, and sent the files there via Focker’s account, he should own them. That being said, I wanted a script earlier to automate permissions, and there was someone here nice enough to give me the correct command syntax for this job.
thanks for such a quick response, but I don't think that's what I need(of course I'm probably wrong..)
I should have been more specific...
I logged onto a windows xp computer at our lounge at school, connected to my linux ftp server w/leechftp, uploaded a file from that winxp computer to my home computer(linux), but when I got home the file was read only. The same happened when my dad sent me an MS document from his computer;read only. So how do I make it so that when I send a file from some computer that I happened to be logged on to, say the library's computer, I can come home and pick up right where I left off; full permissions that is.
Okay I found a solution to my problem, however it's not really the ideal solution, but anyhow.
Like i stated above, the problem was that if I was using a computer, say at the library, and I wanted to save my MS word document, or anything for that matter, by uploading to my FTP server, so that when I got home I could pick up right where I left off, the permissions were all jacked up. So I go home from the library, double-click on my file and it opens and tells me that it's read only. The permissions say that the user who uploaded the file owns it, which it should, but the options for changing view and modify are grayed out.
The solution...
I found that if I renamed the document to something other than what it was uploaded as, I could then open the file that I just renamed it to and edit it. Has anyone else had this kind of experience and if so is there an easier way to fix besides going in and renaming all the files that I want to be able to read/write to.
I did a whole lot of googling on permissions via ftp and finally found some stuff about the umask command, which I just happened to stumble across by reading some random web page. The defualt in proftpd was set to umask 020 which was changing the files i uploaded to 644(rw-r-r). I went in and changed the umask, very easy using gproftpd, to 000, had a test file sent by my dad and voila-the permissions were then defaulted to 664(rw-rw-r) which is what I want seen how I'm the only person using this ftp server(well and mom and dad). If anybody sees anything seriously wrong about this please let me know. Keep in mind that I don't want anonymous users connecting or any of that...this is just a personal portable "hard drive" if you will.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.