Setting up a second HDD

Quick to answer questions about finding your way around Linux Mint as a new user.
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
Jahrew

Setting up a second HDD

Post by Jahrew »

Hey all, I'm new to Linux Mint and I'm trying to figure something out. I started out using a SSD for storing everything, but it's not very big so I got a 1tb HDD and what I want to do is have my OS and a couple of my games on the SSD but otherwise I want everything else to use the HDD by default. How would I go about doing this? I'm using Linux Mint 15 MATE. Thanks in advance.

I tried to search but I didn't anything that made sense, if theres another topic please point me in the right direction.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
passerby

Re: Setting up a second HDD

Post by passerby »

It's easiest to do during install, but what you likely want to do is put your /home partition onto the HDD.
Your home partition stores your user settings, documents, music, videos, pretty much any user data, but not the OS system files.
You can still move it post-install, eg. http://www.howtogeek.com/116742/how-to- ... ng-ubuntu/
wayne128

Re: Setting up a second HDD

Post by wayne128 »

Jahrew wrote:Hey all, I'm new to Linux Mint and I'm trying to figure something out. I started out using a SSD for storing everything, but it's not very big so I got a 1tb HDD and what I want to do is have my OS and a couple of my games on the SSD but otherwise I want everything else to use the HDD by default. How would I go about doing this? I'm using Linux Mint 15 MATE. Thanks in advance.

I tried to search but I didn't anything that made sense, if theres another topic please point me in the right direction.

To me, the easier to do is stay with what you have on SSD and OS.

Just plugin second HDD, use it own format, or use NTFS format on HDD, treat it as a data drive.

Change your browse default download location to the second HDD, now when you wish to store, it goes to HDD.
then once you are OK with using HDD to store new downloaded files, you can copy all your data from SSD to HDD and continue to use HDD as a data drive.
User avatar
Derek_S
Level 6
Level 6
Posts: 1279
Joined: Sat Dec 28, 2013 5:36 pm
Location: Long Island, N.Y.

Re: Setting up a second HDD

Post by Derek_S »

Hello Jahrew - I think you have an excellent combination for your installation of Mint. I'll give you a couple of links to guide you plus several ideas of my own.

Pre-Installation: I would suggest using the SSD for the Root "/" partition and the SATA drive for both Swap and Home. I think between 16GB to 24GB would be fine for Root. This depends greatly upon how many applications you plan to install after installing Mint. A portion of the SSD should be left unallocated for garbage collection and wear leveling. This is known as "over-provisioning", a Google search using "SSD over-provisioning" will give you a better idea of what this is and why it is important. Usually 10% of the drive's capacity is considered to be the minimum, 20% is better. You will have to make your own decision about balancing the size of Root and the space left for over-provisioning. An example would be this: On a 30GB SSD, I would use 24GB for Root and leave 6GB (20%) unallocated.

Be aware of what is known as "partition alignment". This is to ensure that the filesystem blocks are aligned with the physical memory blocks on the SSD. If they are not aligned, then delete/rewrites involving small files on the SSD will erase and rewrite two memory blocks instead of one. You want to be sure that the Root partition is aligned on the 1MB boundary. Read this link for a better understanding of what I'm talking about: http://www.thomas-krenn.com/en/wiki/Partition_Alignment

As far as formatting Root, use the ext4 filesystem, because of the fact that it supports Trim, while ext2 and ext3 do not. There are other filesystems that support Trim, such as BTRFS and XFS, but for the sake of simplicity, I would use ext4 for both Root and Home. So to summarize: Root size 16GB to 24GB, formatted ext4, leaving 10% to 20% unallocated on the SSD. Be sure to align Root to the 1MB boundary. Put Swap and Home on the SATA drive, make Swap equal in size to your system memory, format Home using ext4. At this point you can do the installation of Mint.

Post-Installation: These steps are designed to optimize your SSD's performance and minimize the wear and tear of unnecessary writes. Here is the link: http://apcmag.com/how-to-maximise-ssd-p ... -linux.htm There are four main objectives here:

1.) Enable Trim - see the section under "Filesystem Layer"
2.) Optimize Read/Write Speeds - see the section under "Scheduler"
3.) Minimize Unnecessary Writes - see the section under "Swap and Temp"
4.) Move the Firefox cache files to the SATA drive - see the section under "Applications"

That's all I've got, now you know as much as I do. If another forum member wishes to add to this, please do so.
"When you rise in the morning, give thanks for the light, for your life, for your strength. Give thanks for your food and for the joy of living. If you see no reason to give thanks, the fault lies in yourself." - Tecumseh
Jahrew

Re: Setting up a second HDD

Post by Jahrew »

Derek_S wrote:Hello Jahrew - I think you have an excellent combination for your installation of Mint. I'll give you a couple of links to guide you plus several ideas of my own.

Pre-Installation: I would suggest using the SSD for the Root "/" partition and the SATA drive for both Swap and Home. I think between 16GB to 24GB would be fine for Root. This depends greatly upon how many applications you plan to install after installing Mint. A portion of the SSD should be left unallocated for garbage collection and wear leveling. This is known as "over-provisioning", a Google search using "SSD over-provisioning" will give you a better idea of what this is and why it is important. Usually 10% of the drive's capacity is considered to be the minimum, 20% is better. You will have to make your own decision about balancing the size of Root and the space left for over-provisioning. An example would be this: On a 30GB SSD, I would use 24GB for Root and leave 6GB (20%) unallocated.

Be aware of what is known as "partition alignment". This is to ensure that the filesystem blocks are aligned with the physical memory blocks on the SSD. If they are not aligned, then delete/rewrites involving small files on the SSD will erase and rewrite two memory blocks instead of one. You want to be sure that the Root partition is aligned on the 1MB boundary. Read this link for a better understanding of what I'm talking about: http://www.thomas-krenn.com/en/wiki/Partition_Alignment

As far as formatting Root, use the ext4 filesystem, because of the fact that it supports Trim, while ext2 and ext3 do not. There are other filesystems that support Trim, such as BTRFS and XFS, but for the sake of simplicity, I would use ext4 for both Root and Home. So to summarize: Root size 16GB to 24GB, formatted ext4, leaving 10% to 20% unallocated on the SSD. Be sure to align Root to the 1MB boundary. Put Swap and Home on the SATA drive, make Swap equal in size to your system memory, format Home using ext4. At this point you can do the installation of Mint.

Post-Installation: These steps are designed to optimize your SSD's performance and minimize the wear and tear of unnecessary writes. Here is the link: http://apcmag.com/how-to-maximise-ssd-p ... -linux.htm There are four main objectives here:

1.) Enable Trim - see the section under "Filesystem Layer"
2.) Optimize Read/Write Speeds - see the section under "Scheduler"
3.) Minimize Unnecessary Writes - see the section under "Swap and Temp"
4.) Move the Firefox cache files to the SATA drive - see the section under "Applications"

That's all I've got, now you know as much as I do. If another forum member wishes to add to this, please do so.
Thanks for all the info! I did a fresh install of Mint and did so as you recommended. Just going to optimize the SSD now and then find a stable amd driver! Thanks again!
jsplicer

Re: Setting up a second HDD

Post by jsplicer »

Wow, this is indeed a lot to digest. I started using linux about 2 years ago. Presently using Linux Mint (Petra) Cinnamon , It runs flawless! I love the name and the OS! I thought I had linux down pat, and along came formatting, and sectioning partitions. I used to just let the ISO I burned of the OS do all the formatting for me. Now that I will be buying a new SSD drive to improve performance, I better learn this stuff. Some stuff I pick up right away, formatting & partitioning has never been one of my strong suits, especially now that I am dealing with a foreign drive altogether. Personally I don't know why its called a drive at all, it's just memory right? No moving parts no plates...anyway Thank You all for this valuable information. This page is getting bookmarked as I will surely be referring back to it for some time till I have it right in my head. I don't do anything until I have it understood in my head first.

Thanks again!
DataMan

Re: Setting up a second HDD

Post by DataMan »

Here's my recommendations to your original posting:

1. Install your new hard drive (duh).
2. Restart and either use the LiveCd or a boot version of RescueCD
3. Launch GParted
4. Set up your storage partition(s) using GParted. Note the partitions and any pertinent labels your established (ie sdb2 - MyMusic)
5. Reboot into your resident ops.
6. Using the terminal, create your mount point(s) folders in either /media or /mnt. If you want to see the mount points on your desktop, use /media otherwise for a less cluttered look use /mnt.

Code: Select all

sudo mkdir /media/MyMusic
7. Using the terminal change the ownership and group ownership of the folders you just created to your login id (make it recursive).

Code: Select all

chown <youruserid> -R /mnt/MyMusic

Code: Select all

chgrp <youruserid> -R /mnt/MyMusic
8. Find the associated uui's of the newly created partitions (terminal mode)

Code: Select all

sudo ls /dev/disk/by-uuid -1h
9. Modify your /etc/fstab to include the mount points and the uuid's obtained in #8.

Code: Select all

UUID=8a310a69-f318-49dc-bcb7-020b9699999f /mnt/Data     ext4    defaults        0       2
10. Reboot - you should now see your data partitions in either /media or /mnt.

Additional hints:
1. Record your new fstab entries in a text file also and save in a permanent storage area. Use this for configuring future Mint installs.
2. When configuring a new Mint install, simply create a mount point for your existing Mint. Copy the contents of either /mnt or /media over to your new Mint. Set the ownership and permissions.

The above may seem like a bit, but it is really easy to do. I routinely configure 1-2 Lx ops per year and I have 3 2TB drives with ~20 data partitions. Takes just minutes to get my mount points fully operational on a new install.

I hope the above clarifies things a bit for you.

-DataMan
altair4
Level 20
Level 20
Posts: 11450
Joined: Tue Feb 03, 2009 10:27 am

Re: Setting up a second HDD

Post by altair4 »

I would make one change in the procedure outlined above. "step 7" should be done after the partition is mounted if this is a brand new partition.

Changing ownership of a mount point before anything is mounted has no affect on the ownership or permissions after the mount. An Ext4 partition carries permissions with it so to change them it must be mounted first.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
jsplicer

Re: Setting up a second HDD

Post by jsplicer »

Dataman, just to see if I'm understanding you correctly. After I create a home directory on my regular drive, I should just copy over the contents of my home folder from a backup I have. Then just do a new mint install first making the ssd drive /root then I'll have an option in the mint installer to choose my regular internal drive for my home folder?
-RYknow

Re: Setting up a second HDD

Post by -RYknow »

altair4 wrote:I would make one change in the procedure outlined above. "step 7" should be done after the partition is mounted if this is a brand new partition.

Changing ownership of a mount point before anything is mounted has no affect on the ownership or permissions after the mount. An Ext4 partition carries permissions with it so to change them it must be mounted first.
+1

Mount the drive first, then change permissions. These are a lot of steps, but after setting up numerous machines with an SSD and storage drive, this is by far the way to go!

-RYknow
Locked

Return to “Beginner Questions”