 |
 |
 |
 |
| Installation and Live Media Help with Installation & Live Media (Live CD, USB, DVD) problems. |

29th February 2012, 09:31 PM
|
|
Registered User
|
|
Join Date: Aug 2009
Posts: 140

|
|
|
Installing OS on a SSD
Hello
I'm looking for advice on using a 32 gb ssd for the system drive as a dedicated media client but also have a few general purpose questions:
Once the OS is loaded, the client is basically used to stream media content from a master fileserver.
I'd like to know do I really need a swap file since it doesn't get used very often,
Thoughts on using a ramdisk as the swap space ( I gave 4 gig memory and rarely does more than 1.5 gig every get used.
As many know ssd devices tend to wear faster in a read/write versus a read only operation, does anyone have a link that would tell me what folders are basically read only and which ones are read and write? Reason, thinking of using a 2nd hdd for read/write operations, folders that I suspect are write /var /tmp /home these are candidates for the hdd. The idea is to put writeable folders on a 2nd and keep read only to the ssd.
any other thoughts on using a ssd?
thx
|

29th February 2012, 09:53 PM
|
 |
Registered User
|
|
Join Date: Sep 2009
Posts: 1,409

|
|
|
Re: Installing OS on a SSD
If you put swap in a tmpfs, the OS ends up swapping RAM to the tmpfs, which is in RAM. That doesn't work very well.  Check out this Fedora SSD guide for some more useful information.
dd_wizard
|

1st March 2012, 12:42 AM
|
|
Registered User
|
|
Join Date: Aug 2009
Posts: 140

|
|
Re: Installing OS on a SSD
Thanks for the link,
a lot of questions and setup to digest.. a good place to start in any event
|

1st March 2012, 01:08 AM
|
 |
Registered User
|
|
Join Date: Apr 2006
Location: Ohio, USA
Posts: 8,302

|
|
|
Re: Installing OS on a SSD
Quote:
Originally Posted by toddbailey
Thanks for the link,
a lot of questions and setup to digest.. a good place to start in any event
|
Hey Todd,
That thread needs to be cleaned up and made concise. A background project.
A linux system does not require a swap at all ! However you must understand the consequences. If your system ever runs low on memory then the kernel will pick some process and kill it. It's not necessarily the process requesting additional memory. So some process is killed seemingly at random. IOW the system starts acting erratically.
If you have a swap partition and that fills you get the same behavior.
dd-wiz' correctly describes why a ramdisk/tmpfs swap makes no sense.
Also swap is used for suspend, and you need a swap at least as large as DRAM to suspend.
So if you don't care about suspend and you are convinced of your memory usage - go for it.
=======
Short course:
You want to mount any fs on the SSD with the 'discard' option (add it to /etc/fstab entry).
There is an 'fstrim' utility that trims mounted flesystems (some of them, ext2/3/4 at least). Use it once after install.
ext2/3/4 file systems, by default-config set aside a LOT of storage for special reserved blocks to permit logs and root activity after the disk is mostly filled. The default is 5% of disk space (~1.6GB for yours) , but IMO you only need a few MB to store some logs as to why your system failed.
To recoup the 5% of reserved ext3/4 storage you need to ....
tune2fs -r 1024 /dev/sda1 # or other ext partition
You can do this on a mounted filesystem. [1024 - 4k blocks (4MB) remain as a reserve].
__________________
None are more hopelessly enslaved than those who falsely believe they are free.
Johann Wolfgang von Goethe
Last edited by stevea; 1st March 2012 at 01:11 AM.
|

1st March 2012, 03:26 AM
|
 |
Registered User
|
|
Join Date: Sep 2009
Posts: 1,409

|
|
|
Re: Installing OS on a SSD
I hate to contradict stevea, it's usually a good way to embarrass one's self.  So I turned off swap and tried suspending before I did. Suspend seems to work fine with no swap, programs are left in memory and the machine switches to very low power mode. However hibernate writes RAM to the swap file and then performs what amounts to a shut down. So, insufficient swap will prevent hibernating your machine.
dd_wizard
|

1st March 2012, 09:56 AM
|
 |
Registered User
|
|
Join Date: Apr 2006
Location: Ohio, USA
Posts: 8,302

|
|
|
Re: Installing OS on a SSD
Quote:
Originally Posted by dd_wizard
I hate to contradict stevea, it's usually a good way to embarrass one's self.  So I turned off swap and tried suspending before I did. Suspend seems to work fine with no swap, programs are left in memory and the machine switches to very low power mode. However hibernate writes RAM to the swap file and then performs what amounts to a shut down. So, insufficient swap will prevent hibernating your machine.
dd_wizard
|
Sorry - I should have said hibernate, tho the method is called 'suspend to disk'.
---------- Post added at 05:56 AM ---------- Previous post was at 05:00 AM ----------
I just updates the thread with a concise how-to in posts 67, 68, 69.
http://forums.fedoraforum.org/showth...=256068&page=5
EDIT: For a simpler reading and reference experience, those pages have been set aside as a guide and "stuck" in their own new thread. That thread is for reference only, though. Any discussions should be conducted in their own thread, or appended to an existing thread on the subject.
-- Dan
__________________
None are more hopelessly enslaved than those who falsely believe they are free.
Johann Wolfgang von Goethe
|

1st March 2012, 08:24 PM
|
|
Registered User
|
|
Join Date: Aug 2009
Posts: 140

|
|
|
Re: Installing OS on a SSD
I've never been able to get Fedora to suspend/sleep/ etc properly when using the Nvidia.com provided drivers. In one instance it was documented that resuming from XXX mode doesn't work. So I don't bother with it any more. I suspect that with the read speeds of a ssd, suspend features isn't anything I'll miss. My current boot time is under 3 minutes using a hdd with 8 year old tech, 15K rpm 18gig u320 scsi. My requirement for a ssd is low power/heat, no noise and fast boot times,
Once I convert to a fan less gpu and underclock the cpu, I can eliminate even more noise/heat etc. older fans and/or less that desirable db ratings
After more consideration I plan to use a hybrid configuration of 1 ssd and 1 hdd
Getting back to the ssd config.
From what I gather, I need to
1> create partitions that begin and end on 4K boundaries
2> format to ext4 or another f/s that supports trim, ext4 works for me
3> disable elevator schedule on ssd
4> enable noatime & writeback on ssd
5> fill in
6> due to lack of ups and backups, I plan to use journaling. Any way to put journaling on a different drive?
7> due to the 4g memory installed and only require 1.5 g elect to not provide a swap partition or better yet put swap on the hdd
8> put /home, /var, /tmp on the hdd. Any other folders to consider ?
another question: benchmarking, an attempt to install a sata ssd in a ide laptop worked using converter board and cable, none of the above configuration settings were used, drive was formatted ext3 , F11-i386 (I think) was loaded and machine boot speed was impressive. Out of curiosity however Phoronix Test Suite was installed and disk benchmarking test were run but after several minutes, the ssd developed i/o errors and soon failed soon after.
The ssd was a crucial 1.8inch sata III 64gb drive.
comments?
thanks
---------- Post added at 12:24 PM ---------- Previous post was at 09:14 AM ----------
One more question: I don't have the ssd just yet, Newegg's shipping delayed long enough to miss the 3 day, delivery by Friday window. Once I get the sdd, I plan to install then boot via a usb key and then partition the sdd device and cloan the hdd to the ssd.
I was thinking I could get a head start with the configuration before the drive in installed
Soooo, can I apply these setting to the system currently running a single hdd and what effects will it cause ie: negative or bad?
Last edited by toddbailey; 1st March 2012 at 08:09 PM.
|

2nd March 2012, 04:59 AM
|
 |
Registered User
|
|
Join Date: Jul 2004
Location: Wake Forest, NC
Age: 59
Posts: 1,183

|
|
|
Re: Installing OS on a SSD
Quote:
Originally Posted by toddbailey
I've never been able to get Fedora to suspend/sleep/ etc properly when using the Nvidia.com provided drivers. In one instance it was documented that resuming from XXX mode doesn't work. So I don't bother with it any more. I suspect that with the read speeds of a ssd, suspend features isn't anything I'll miss. My current boot time is under 3 minutes using a hdd with 8 year old tech, 15K rpm 18gig u320 scsi. My requirement for a ssd is low power/heat, no noise and fast boot times,
Once I convert to a fan less gpu and underclock the cpu, I can eliminate even more noise/heat etc. older fans and/or less that desirable db ratings
|
I think you will be well pleased with the SSD's boot speed. Suspend to RAM is not an issue. Suspend to Disk/Hibernate is something I don't use. I can't speak to that. I still have a swap partition, just in case. Your boot time, especially if you are not encrypting the drive, should be a matter of seconds.
Quote:
|
After more consideration I plan to use a hybrid configuration of 1 ssd and 1 hdd
|
If that meets your needs, then go for it.
Quote:
Getting back to the ssd config.
From what I gather, I need to
1> create partitions that begin and end on 4K boundaries
2> format to ext4 or another f/s that supports trim, ext4 works for me
3> disable elevator schedule on ssd
4> enable noatime & writeback on ssd
5> fill in
6> due to lack of ups and backups, I plan to use journaling. Any way to put journaling on a different drive?
7> due to the 4g memory installed and only require 1.5 g elect to not provide a swap partition or better yet put swap on the hdd
8> put /home, /var, /tmp on the hdd. Any other folders to consider ?
|
Don't forget to add discard to #4 as well. That is what enables Trim from what I understand. I have not done the writeback option, but have noatime,discard as my options.
Also, if you have sufficient RAM, you could put /tmp in RAM. The SSD instructions in the links above should give the benefits/risks of such a move. I did it on my netbook which has 2 Gb RAM, opting to go with the 10% suggested. So far, it seems to be working well.
Quote:
another question: benchmarking, an attempt to install a sata ssd in a ide laptop worked using converter board and cable, none of the above configuration settings were used, drive was formatted ext3 , F11-i386 (I think) was loaded and machine boot speed was impressive. Out of curiosity however Phoronix Test Suite was installed and disk benchmarking test were run but after several minutes, the ssd developed i/o errors and soon failed soon after.
The ssd was a crucial 1.8inch sata III 64gb drive.
comments?
|
I had purchased a brand-new 120 GB OCZ Vertex Plus SSD. Just about the time I had finished setting it up in my netbook, it died. I could not even get it to be recognized in the BIOS. That one got an RMA, was sent off and replaced. The drive was set up with encrypted /, /home, and swap, so I wasn't worried about whether anything was on it.  The new one is installed, configured, and so far, has been proving reliable. I think that nowadays, the consumer is acting as the QA department for manufacturers who find it cheaper to replace failures than to ensure all products are of sufficient quality to fulfil their intended purposes.
Quote:
One more question: I don't have the ssd just yet, Newegg's shipping delayed long enough to miss the 3 day, delivery by Friday window. Once I get the sdd, I plan to install then boot via a usb key and then partition the sdd device and cloan the hdd to the ssd.
I was thinking I could get a head start with the configuration before the drive in installed
Soooo, can I apply these setting to the system currently running a single hdd and what effects will it cause ie: negative or bad?
|
Applying any of them to an HDD might be problematic. The noatime option is probably the only one that should be relatively harmless. However, you may wish to configure, clone, then apply the SSD options to the SSD drive and not apply them to the HDD. If you wish to encrypt, you will have little choice but to wait as resizing of encrypted drives is not trivial. I have not had the courage to try it yet as I have been hoping that tools like gparted would be updated to support resizing of LUKS encrypted partitions. So far, that has not happened.
Personally, I also avoid LVM. I have been burned twice by it, so prefer standard partitions to LVM ones.
__________________
StephenH
"We must understand the reality that just because our culture claims certain things are true it does not mean they are!" --M. Liederbach
http://pilgrim-wanderings.blogspot.com
|

2nd March 2012, 07:23 AM
|
 |
Registered User
|
|
Join Date: Apr 2006
Location: Ohio, USA
Posts: 8,302

|
|
|
Re: Installing OS on a SSD
Quote:
Originally Posted by toddbailey
Once I convert to a fan less gpu and underclock the cpu, I can eliminate even more noise/heat etc. older
fans and/or less that desirable db ratings
|
I agree with the intention. Suggest you look at getting a kill-a-watt
http://www.newegg.com/Product/Produc...82E16882715001
Maybe <$20 from Amazon. It's a cheap powe meter with a lot of uses if you are an energy bug. But it's mostly a great way to judge what you are doing with your system design.
120mm fans and the correct PSU (not a generic 450W unit, but a selected <200W unit).
Quote:
|
After more consideration I plan to use a hybrid configuration of 1 ssd and 1 hdd
|
Powerr advice is the same, but put the / root on ssd and the /var and /tmp and /swap on the rotating device. Use your judgement about /home and /opt etc.
Quote:
Getting back to the ssd config.
From what I gather, I need to
1> create partitions that begin and end on 4K boundaries
2> format to ext4 or another f/s that supports trim, ext4 works for me
3> disable elevator schedule on ssd
4> enable noatime & writeback on ssd
5> fill in
6> due to lack of ups and backups, I plan to use journaling. Any way to put journaling on a different drive?
7> due to the 4g memory installed and only require 1.5 g elect to not provide a swap partition or better yet put swap on the hdd
8> put /home, /var, /tmp on the hdd. Any other folders to consider ?
|
1> 4KB is a minimum. I saw some very bad performance when not aligned beyond 512B. Some sources say to align on an erase block size (128KB - 512KB), but I don't see the improvement on mine.
Gparted defaults to1MB(2048 sectors)
4> NON-root ssd filesystem might use "discard,noatime,data=writeback".
but root should be "discard,noatime" Then in /boot/grub2/grub.cfg on the "linux ..." line use
linux ... rootflags=data=writeback
6> actually there is. Read th e"man mkfs.ext4" ...
Code:
-J journal-options
Create the ext3 journal using options specified on the command-
line. Journal options are comma separated, and may take an
argument using the equals ('=') sign. The following journal
options are supported:
device=external-journal
Attach the filesystem to the journal block device
located on external-journal. The external journal
must already have been created using the command
mke2fs -O journal_dev external-journal
I have no idea about the performance.
7> Yes - swap on the HDD. If it's not used - no harm.
8> /var and /tmp certainly - but you *may* want to put /home or part of it on ssd. That depends a lot on how you use it. If you want high performance from /home accesses and it's not to huge then ....
============
Quote:
another question: benchmarking, an attempt to install a sata ssd in a ide laptop worked using converter board and cable, none of the above configuration settings were used, drive was formatted ext3 , F11-i386 (I think) was loaded and machine boot speed was impressive. Out of curiosity however Phoronix Test Suite was installed and disk benchmarking test were run but after several minutes, the ssd developed i/o errors and soon failed soon after.
The ssd was a crucial 1.8inch sata III 64gb drive.
comments?
|
Failure to use TRIM/discard doesn't generally cause a failure, but it causes extreme slowness of writes as the drive is well used (write on the order of the disk size). So I find this troubling. I suggest you use 'smartctl' and examine the result parameters carefully. particularly drive health.
Quote:
]One more question: I don't have the ssd just yet, Newegg's shipping delayed long enough to miss the 3 day, delivery by Friday window. Once I get the sdd, I plan to install then boot via a usb key and then partition the sdd device and cloan the hdd to the ssd.
I was thinking I could get a head start with the configuration before the drive in installed
Soooo, can I apply these setting to the system currently running a single hdd and what effects will it cause ie: negative or bad?
|
Discard is the only one at issue, and it *seems* to be accepted and ignored on rotating disks.
Quote:
|
Also, if you have sufficient RAM, you could put /tmp in RAM. The SSD instructions in the links above should give the benefits/risks of such a move. I did it on my netbook which has 2 Gb RAM, opting to go with the 10% suggested. So far, it seems to be working well.
|
I'd just as soon put /tmp on the rotating drive. Then no worries.
__________________
None are more hopelessly enslaved than those who falsely believe they are free.
Johann Wolfgang von Goethe
|

2nd March 2012, 05:03 PM
|
|
Registered User
|
|
Join Date: Aug 2009
Posts: 140

|
|
|
Re: Installing OS on a SSD
Yes a friend let me borrow a Kill a watt, so handy I purchased one and it really tells you where the energy is going, I only wish they made one for 50 amp 220 use, I'd love to monitor the stove, hot tub and water heater, but I digress.
Thank for all the great info on the ssd install.
Next Tuesday should be interesting. The power consumption of the machine isn't that great a concern, espc. when compared to the consumption of the server with all it's multi raid drives running 24x7. The major requirement is fast boot and minimal noise. The reason for a hybrid approach is to minimize disk write activity to the ssd. With thermal monitoring, I can throttle back fan speeds or replace with lower cfm/quieter devices. I used to build boxes for performance and noise and watts were not a consideration, now the roles are reversed. Being a ocassional use item in a living room environment, quick access to the desktop from power on and quiet are design goal. The hdd is a server class device and not the quietest but the cpu/gpu/case fans are louder and mask it's sound production, beside I can always utilize accoustic materials if necessary.
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
Current GMT-time: 21:39 (Saturday, 25-05-2013)
|
|
 |
 |
 |
 |
|
|