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.
1. What happens if you have a file with a 755 permissions and transfer the file from one linux computer to another linux computer, both having ext3 filesystems. Do the permissions change to the default permissions of the directory that the file was downloaded to?
2. What would happen to the permissions if you transfer a file from linux to windows ntfs hard disk?
3. What would happen to the permissions if you transferred a file from fat32 filesystem on linux to a windows fat32 hard disk?
4. What would happen to the permissions if you tranferred a file from windows xp ntfs to ext3? What would happen if you transferred the file right back from the ext3 to the original ntfs filesystem on windows xp?
1. What happens if you have a file with a 755 permissions and transfer the file from one linux computer to another linux computer, both having ext3 filesystems. Do the permissions change to the default permissions of the directory that the file was downloaded to?
2. What would happen to the permissions if you transfer a file from linux to windows ntfs hard disk?
3. What would happen to the permissions if you transferred a file from fat32 filesystem on linux to a windows fat32 hard disk?
4. What would happen to the permissions if you tranferred a file from windows xp ntfs to ext3? What would happen if you transferred the file right back from the ext3 to the original ntfs filesystem on windows xp?
These sound very much like homework questions.....
These sound very much like homework questions.....
This sounds very much like "Take your problems down the hall."
If you write to suggest that someone has a school assignment
and is posting questions to crib the answers, you presume
the bad intentions of someone new to LQ. Not very friendly.
Even if you are correct, how is this any different from asking
someone down the hall or in a coffee house these same questions?
Distribution: M$ Windows / Debian / Ubuntu / DSL / many others
Posts: 2,339
Rep:
Quote:
Originally Posted by trist007
1. What happens if you have a file with a 755 permissions and transfer the file from one linux computer to another linux computer, both having ext3 filesystems. Do the permissions change to the default permissions of the directory that the file was downloaded to?
preserved
Quote:
2. What would happen to the permissions if you transfer a file from linux to windows ntfs hard disk?
read and write permission preserved execute permission lost
Quote:
3. What would happen to the permissions if you transferred a file from fat32 filesystem on linux to a windows fat32 hard disk?
preserved
Quote:
4. What would happen to the permissions if you tranferred a file from windows xp ntfs to ext3? What would happen if you transferred the file right back from the ext3 to the original ntfs filesystem on windows xp?
preserved
you know people should not do you homework for you
1. What happens if you have a file with a 755 permissions and transfer the file from one linux computer to another linux computer, both having ext3 filesystems. Do the permissions change to the default permissions of the directory that the file was downloaded to?
Processes read create files. One process on the local workstation (W/s) reads, with permission, and sends to the network. Another process on the remote w/s gathers from the network and writes files. That remote process has a UID+GID and umask. The target folder has all of its bits.
The remote process attributes and context control what happens during the file write attempt.
Quote:
Originally Posted by trist007
2. What would happen to the permissions if you transfer a file from linux to windows ntfs hard disk?
Again the process rule applies. Does the local w/s have read-write access to a local NTFS? If so then the local process attributes are used to ask NTFS to store the file. Did you simply copy or did you use copy with options to preserve original file settings? Is the process running as the root user? Does the process uid+gid match the uid+gid of the original file owner? All of these play a role.
Quote:
Originally Posted by trist007
3. What would happen to the permissions if you transferred a file from fat32 filesystem on linux to a windows fat32 hard disk?
Fat32 has one permission and several attributes, READ_ONLY. It is either on or off. In a Linux world, that permission appears as
"-r--r--r--" meaning everyone can read . You must be able to read the file before you can copy from fat32. It does not matter which OS runs, fat32 is just that. [NOTE--Recent court rulings cover the use of fat32 on systems that are not native Microsoft or suitably licensed.]
Quote:
Originally Posted by trist007
4. What would happen to the permissions if you tranferred a file from windows xp ntfs to ext3? What would happen if you transferred the file right back from the ext3 to the original ntfs filesystem on windows xp?
Again, the process(es) doing the transfer govern what is happening.
Windows has its own rules when copying files. In windows networking,
file attributes change hands. Linux accomplishes windows networking using a package called SAMBA. The SAMBA docs do a very good job of explaining how permission decisions are made.
The response to all is "it depends on the software you use, and the options you use" (that's why tar has -p and cp has -p and -a, duh?). It's one of these questions that have no real meaning because that's not the response that your teacher wants (although it is the correct one) and is only designed so you answer what the teacher told you in the classroom, even if it's inaccurate or just plain wrong.
That's true except for the 'x' permission in 2), and in 4) assuming that you want to give details of the process in that one.
Quote:
Originally Posted by SaintDanBert
This sounds very much like "Take your problems down the hall."
If you write to suggest that someone has a school assignment
and is posting questions to crib the answers, you presume
the bad intentions of someone new to LQ. Not very friendly.
Even if you are correct, how is this any different from asking
someone down the hall or in a coffee house these same questions?
Sorry,
~~~ 0;-Dan
It's just the forum policy, not to solve anyone else's homework. It's a good moment to re-read the rules, and also to remember that your teacher might perfectly be an LQ member as well. Besides that, even if s/he's dumb like a cow, a simple google for the verbatim strings will reveal any hit here or in any other public place of the net.
It's just the forum policy, not to solve anyone else's homework.
I'm running an antique edition of "crystal ball." I remember being a youngster working on my own to learn about computers. How are we supposed to guess the intentions of someone who asks a question? Who knows the writer might be some young person, working their way through some book of exercises all on their own. No "homework" just honest inquiry.
If policy is, "don't answer homework" and you suspect the question is homework, simply avoid posting an answer. Without an answer, the writer
will go away.
I'm running an antique edition of "crystal ball." I remember being a youngster working on my own to learn about computers. How are we supposed to guess the intentions of someone who asks a question?
I didn't write the rules. If you have complains about that you should post to the forum feedback section with your questions or suggestions.
Quote:
Who knows the writer might be some young person, working their way through some book of exercises all on their own. No "homework" just honest inquiry.
A person that is doing the research him/herself usually has a different insight of things, and don't usually paste "verbatim" exercises, but rather try to clear the conflicting points so s/he can continue the research.
Quote:
If policy is, "don't answer homework" and you suspect the question is homework, simply avoid posting an answer. Without an answer, the writer
will go away.
I prefer telling him or her that we don't answer that kind of questions, and that if s/he is willing to do some research and ask concrete questions or ask for directions rather than pasting verbatim whatever the teacher gave him/her we will be here to help. It's the way of action that I consider to be better.
Besides that, sometimes it's not clear if it's homework or not, and in that case explaining the situation to the OP can push him or her to give more details and show the research s/he's done up to the current moment, so we can see ourselves that's not homework, or that it's homework but that s/he's done the research and just needs a bit of guidance on very concrete matters.
A lot of the questions can be answered by experimentation.
Create an account on your machine for another user. Save a file in /tmp and have the second user copy it back. Look at the cp options.
If you have a pen drive that uses vfat32, you can copy files to it, and experiment mounting it with different "uid","gid","fmask" and "dmask" values. You can create an ntfs filesystem on a file and mount it using the 'loop' option.
Also enter "help umask" in the terminal so you understand the effect it has.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.