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.
You "should" be able to install the new system to a / (root) partition and not affect your home.
Oh, that's great then.
Quote:
Originally Posted by yancek
What I meant is that "not formatting" the partition is not the default. . . . . . You "should" be able to install the new system to a / (root) partition and not affect your home. Just make sure you do NOT select to format the partition on which you currently have /home.
How can I achieve this?
I suppose I can set it in the option provided in the live USB installer. By clicking on the '+ Change' a 'Create partition' dialogue box appears where, in the 'use as' menu there is the option 'do not use the partition'. I need to select that if I want to keep my files in the previous/old '/home' parttion, intact. By doing that; the previous/old '/home' parttion will not be formatted. Am I right? Or is there any other method?
Will this keep the previous/old '/home' partition intact? If so, that's great then. One major issue is resolved.
Quote:
Originally Posted by yancek
. . . I personally do not use a separate /home partition. . . .
You mean you do not create the '/home' partition at all? So do you keep all your files in a seperate partition like the one 'store' we discussed above? That's a nice idea.
Quote:
Originally Posted by yancek
There is obviously no guarantee and I would definitely back up any important data before changing partitions, formatting or installing/reinstalling.
But why? What can happen? Of course uncertainties are always there, and I too would do a backup. However keeping that aside, principally speaking, if the 'do not use the partition' option is selected the installer wouldn't touch it. Right? Or are there any hidden issues here?
Quote:
Originally Posted by yancek
If you have or want a separate partition on which to keep personal documents, pictures, video, or anything important to you it is a lot simpler to create a separate data partition either during or after the install.
You should be able to put an entry in the /etc/fstab file to give users access including write permissions after you have completed the install to your separate "Store" partitions.
Oh that's nice then. Could you please kindly give a step by step procedure guidance in creating a separate data partition and give standard-users access including write permissions, on LM 17 Qiana Cinnamon? I would greatly appreciate the help. I have tried to do it in many ways but haven't been able to accomplish that till now.
You can install without creating a swap partition.
If you are constricted by memory (depending on what programs get run), you can create a swap partition later.
Alternatively, you can create a swap file which is almost as good as a swap partition.
Is that so?
That's nice then.
I just went through what the swap file & swap partition are, on the web.
How can we create a swap file on LM 17 Qiana Cinnamon after installation?
Note that I said "should" be able to install the system to whichever partition you currently have Mint on. I would definitely back up data that is important to you to a separate drive. There are just too many things outside your control that can go wrong when installing/partitioning. From your earlier post with the parted command, this looks to be sda3 but that is just a guess as you have four other Linux (ext4) partitions. Simplest way to find out with certainty is to boot Mint, open a terminal and run the command: df -h That should give you output similar to below:
Code:
df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda8 39G 27G 11G 73% /
In the output above from my computer, it shows the root filesystem is installed on partition sda8 and that is determined by seeing the root symbol / under the Mounted on column. Check to see if it actually on sda3 or one of the other partitions.
Quote:
I suppose I can set it in the option provided in the live USB installer. By clicking on the '+ Change' a 'Create partition' dialogue box appears where, in the 'use as' menu there is the option 'do not use the partition'. I need to select that if I want to keep my files in the previous/old '/home' parttion, intact. By doing that; the previous/old '/home' parttion will not be formatted. Am I right? Or is there any other method?
I hesitate to advise on this as I've never used a separate home partition. If I were to try it, that sounds reasonable but you might wait for someone who has actually had experience using a separate home partition. I would probably just install everything to the one / partition and a /home directory would be created there and you should then be able to mount your old home partition with a proper entry in the /etc/fstab file.
Quote:
You mean you do not create the '/home' partition at all? So do you keep all your files in a seperate partition like the one 'store' we discussed above? That's a nice idea.
I do it that way yes, a separate data partition (actually multiple partitions for different types of data) since I then don't have to deal with overwriting the separate /home partition.
Quote:
But why? What can happen? Of course uncertainties are always there, and I too would do a backup. However keeping that aside, principally speaking, if the 'do not use the partition' option is selected the installer wouldn't touch it. Right? Or are there any hidden issues here?
I would think that not doing anything with the /home partition or selecting the option not to format would work, either one. As I said, I've never used a separate /home partition so don't have any personal experience to base that on. With separate data partitions, I can select a different partition on which to install the system and my data partitions have always been intact so I would expect it to work. Problems I was thinking of include power outages, accidents including user error (distractions, not understanding), small children, cats, dogs, etc. Most of those can be avoided.
Granting users permissions on a Linux filesystem partition is a pretty simple process. It gets complicated when you are trying to grant permissions on an ntfs (windows) filesystem from Linux. After you get things setup, you might post back. I think that umask option in the fstab file are a good way to go. Should be able to get a response to that.
Just to answer your question about a swap partition, in your situation do not bother with it during the install as you already have a swap partition on partition 9. You only need one. I usually have 10-12 operating systems on this computer and one swap.
From this it shows the root filesystem is installed on partition sda8. It is so because; I created the Unallocated space first, then one '/home/od' for one standard user, then one '/home/cr' for another standard user, then one '/home/ak' for the admin [this was not necessary I suppose, since I had kept the large ntfs partition for myself. I can now delete it and add it to the unallocated space.], and then I created the '/' partition, and at the last I created the swap partition. I kept the '/' and the swap at the end because their size cannot be altered or moved. I could alter and/or move, the sizes of the rest of the partitions as and when the need arises, by giving-to or taking-from the Unallocated pool space, easily, as they are in the middle.
Quote:
Originally Posted by yancek
I would probably just install everything to the one / partition and a /home directory would be created there and you should then be able to mount your old home partition with a proper entry in the /etc/fstab file.
Oh this is how its done. A 'store-partition' is to be created and the OS is to instructed that this is the '/home partition'.
Quote:
Originally Posted by yancek
I do it that way yes, a separate data partition (actually multiple partitions for different types of data) since I then don't have to deal with overwriting the separate /home partition.
When the seperate 'store' partition is created, what is the mountpoint(?) given to it; just '/data' or '/data partition' or any random personalised name can be given? Are there any specific guidelines for that? Am I right in calling it the 'mountpoint'?
Quote:
Originally Posted by yancek
I would think that not doing anything with the /home partition or selecting the option not to format would work, either one.
I thought that they are one and the same. Is a distinct option not to format, also available? Where would I find it?
I have a few more querries;
* After installation, can the '/ partition' be resized and/or moved without any bad effects on the system?
* After installation, can the 'Swap partition' be resized and/or moved without any bad effects on the system?
Different users are not (normally!) given their own partitions.
Assuming cr, ak & od are different users, sub-directories are created in /home when the users are created (automatically).
So you get /home/cr, /home/ak & /home/od
In short, you don't need or want
/dev/sda6
/dev/sda7
/dev/sda5
This means that you can have hundreds of users if you want to.
Last edited by JeremyBoden; 09-02-2014 at 10:43 AM.
Your df output is a little unusual as generally one partition is created for /home, under that each user would have his/her directory and the folders/files there could only be modified by that user. No other user other than the admin/root user could modify files/folders in another user directory but could read them. Your output shows a separate /home directory as well as separate /home/user directories for three users. As indicated above by JeremyBoden, you could put all of those separate /home/user directories under /home. That is usually the way it is done. If any of the users partitions have data, you would first need to copy it to the /home partition.
Quote:
Oh this is how its done. A 'store-partition' is to be created and the OS is to instructed that this is the '/home partition'.
No. See above explanation..
Quote:
When the seperate 'store' partition is created, what is the mountpoint(?) given to it; just '/data' or '/data partition' or any random personalised name can be given? Are there any specific guidelines for that? Am I right in calling it the 'mountpoint'?
Yes, you can call it whatever you want. You would be best off creating it under the /mnt directory as that is its purpose rather than /data which would put it in the root of the filesystem. During the installation, if you select a partition to use you will get the Edit partition window and to the right of Mount point, you click the down arrow and you will have some options. You should also have a blank line where you can enter the name of the mount point: /mnt/data, would be an example.
Quote:
I thought that they are one and the same. Is a distinct option not to format, also available? Where would I find it?
No, there is a check box in the installer window and if you leave it blank, it should not format. I believe you mentioned that in an earlier post.
Quote:
* After installation, can the '/ partition' be resized and/or moved without any bad effects on the system?
Yes, BUT only if there is contiguous free space. Same with swap.
Note that I have 5 users in /home...
I also have 3 partitions for which I have created directories in /mnt,
so that I can access video, backups and miscellaneous files.
When a user signs on, any reference to the home directory will actually be to /home/username.
For example, try the pwd (print working directory) command from a terminal screen.
But if you are creating mnt points for individual users then the data isn't shared, it's just additional space that would be there in users directories.
I can understand having an additio.al drive & having read/write permissions, but it appears that the data is no different than an extension of /home/videos or pics.
The setup the OP posted is a bit unusual with a separate partition for each /home/user and I wonder what would be in the actual separate /home partition. Would it contain duplicate /home/user directories or not much of anything and just be wasted space?
That's my thinking. But it was a post further up, now I see the OP change the partitioning scheme. On the /mnt/videos is that doable by creating a link in users directory?
Different users are not (normally!) given their own partitions.
Assuming cr, ak & od are different users, sub-directories are created in /home when the users are created (automatically).
So you get /home/cr, /home/ak & /home/od
In short, you don't need or want
/dev/sda6
/dev/sda7
/dev/sda5
This means that you can have hundreds of users if you want to.
Thank you JeremyBoden,
The reason I did that was partly because of my not knowing that the '/home' can be kept intact even during a re-installation. The other reason is, [EDDY1 mentioned it] I supposed , that the '/home/cr, /home/ak & /home/od' partitions are shared i.e. they can be read by other users [yancek mentioned it] and I wanted to keep them unaccessible to other users except the admin.
Oh that was nice of you to give that example JeremyBoden. It was informative.
So now can I say that;
'/home' - is a partition that is by default a partition given into the hands of the OS to create user accounts and store all their files.
'mnt/<username> or <type name>' - creates a partition that can be only accessed by that user.
I wonder why do we have seperate '/mnt/video' & '/mnt/filestore' partitions? A store-partition like the '/mnt/filestore' could contain all types of files. Or is it that a '/mnt/video' can only accept video files?
Your output shows a separate /home directory as well as separate /home/user directories for three users.
Quote:
Originally Posted by yancek
The setup the OP posted is a bit unusual with a separate partition for each /home/user and I wonder what would be in the actual separate /home partition. Would it contain duplicate /home/user directories or not much of anything and just be wasted space?
That was a mistake due to my lack of knowledge. After all these discussions now I can see that, the separate /home directory would be wasted. However one issue remains in my mind here. If I choose to have a separate /home/user directories for different users, and decide to remove the /home directory altogether, can the OS function properly? Where will it keep the sub-directories of the user-accounts created later after installation? Can the OS be instructed to keep them in their respective separate /home/user directories? Actually what I had supposed was that, the OS would by default, place them in the default /home partition, and the user has to move them manually to his/her separate /home/user directory to keep them safe and private [I didn't know then, that the /home partition can be kept intact in case of a re-installation]
Quote:
Originally Posted by yancek
You would be best off creating it under the /mnt directory as that is its purpose
That sounds nice. I will now delete & change the /home/od, /home/cr partitions to '/mnt/od' and '/mnt/cr'. But how can I make the OS to recognize for example '/mnt/user1' partition as the default partition of that user and automatically mount it at startup and make it available for use to the user and at the same not to make available the '/mnt/user2' even for reading to 'user1'?
Quote:
Originally Posted by yancek
. . . rather than /data which would put it in the root of the filesystem. During the installation, if you select a partition to use you will get the Edit partition window and to the right of Mount point, you click the down arrow and you will have some options. You should also have a blank line where you can enter the name of the mount point: /mnt/data, would be an example.
I am curious what the purpose of the /data parttion is? If it would be put in the root of the filesystem, I suppose it's contents would surely get deleted in case of a re-installation. If so why create the /data partition?
Quote:
Originally Posted by yancek
No, there is a check box in the installer window and if you leave it blank, it should not format. I believe you mentioned that in an earlier post.
Yes there is one. I started the live USB installer and checked it.
Quote:
Originally Posted by yancek
Yes, BUT only if there is contiguous free space. Same with swap.
Oh that's great then. That gives me a lot of feedom to manage my available disk space very nicely.
Thank you yancek. You guys are just great, with so much patience and putting efforts.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.