SSD and new OS install

I am putting together a new machine and would like to request some advice on SSD’s and OS installation and any other info that is pertinent to SSD’s and opensuse 12.2.
My Mainboard is an Asus P8Z77-V Deluxe with a i7-3770k processor, 16 GB ram. I am using OCZ’s Vertex 4 SSD. All is new and never been used at this point.
I have been doing some reading on what may need to be done to install an OS on a SSD.
I don’t know if this is misinformation on my part, but I have been told that there are things that need to be done to the SSD before I install the OS. Things such as in the following links.
https://en.opensuse.org/SDB%3ASSD_performance This link only mentions up to 11.4] Does this still need to be done in 12.2?
and
https://forums.opensuse.org/english/get-technical-help-here/how-faq-forums/unreviewed-how-faq/454999-using-ssd-hard-drive-opensuse-trim-command-2.html In particular the post #15 by vgiannadakis re: Trim on page 2]. ** Is this still pertinent to opensuse 12.2?**
Also some reading on the OCZ site, which basically said “Install Linux distro as you would on an HDD”.
And general googling/ixquick.
Three Simple Tweaks for Better SSD Performance - Linux Magazine Online
Beginners Guide Articles (Updated 12 Feb 12)
Some info has stated that I should put all of the OS on the SSD. Some stated only / and swap on the SSD, but that /home should be put on a HDD.
At this point I am getting a little nervous wondering, “have I made the correct choice of using an SSD for my new OS [openSUSE 12.2]”? I certainly don’t want to mess up the SSD before I even get a chance to try it out. I have heard such good things about them. I am certainly willing to do these things, but a little clarification on what steps and in which order I need to do them would be helpful. Are There anymore posts or articles that I need to read to help me use this SSD in the proper fashion. Thank You.

So I have been using an SSD for a while and at present I keep the SWAP and /home on a separate hard disk. My reason for the split is three fold;

  1. Often your /home area can become large with video and audio media files and such while SSD’s are smaller than normal hard drives.
  2. You get the largest single speed up when all of root / is on the SSD for startup and program loads.
  3. I have had an SSD fail with /home on it and its a nightmare when it happens. The SSD would help large media files, but its not worth the risk to me.

Here is what I use in the fstab file:

/dev/disk/by-id/ata-SSD2SC120GB1DA16T-T_PNY25120001032010052-part2  /                    ext4       acl,user_xattr,noatime,discard,errors=remount-ro  0 1

Its OK to place SWAP there, but since SWAP is not used all that much with 16 GB of memory, it can be anywhere and save your space for the openSUSE root / partition. You should stick with the EXT4 partition type for discard to work properly. By the way your Three Simple Tweaks link never opened up for me to look at.

Thank You,

I’ve been using SSD’s for a couple of years now, they always showed up as harddisks, always treated them as such. The only issue I’ve had, was thinking the installer failed since it finished much too fast IMO; made me spent a couple of hours to verify that all was well.

Highly recommend you follow the recommendations in my presentation slide deck created about 6 mths ago

https://sites.google.com/site/4techsecrets/slide-presentations-30min

Based largely from wiki.archlinux, that wiki now includes more optimization options but I’m quite happy with the optimizations I implemented.

Some important points from my slide deck…

Any SSD comment and recommendations 2011 and earlier is totally irrelevant, outdated and mostly invalid.
My basic recommendations describe how to implement TRIM, minimize unneeded disk writes, move partitions off the disk and into RAM, change the disk I/O scheduler to flat rather than the default rotational geometry and how to setup real time monitoring so you can verify the results of your optimizations.

Bottom line is that I also reviewed the current SDB and OCZ references you list and found both outdated and inadvisable.

The screenshot in my presentation is real… Unless my machine is under unusually heavy load the SSD has only intermittent blips of activity while most of my disk activity is on the HDD by design. Bootups take only about 30sec despite an unusually large number of system services starting up and shutdown or sleep is only a few seconds to minute if nothing is hanging.

HTH,
TSU

Thanks for replying Knurpht, jdmcdaniel3, tsu2.

Would the following quote apply to opensuse 12.2 using ext4 file system?

Mac OSX Disk Utility aligns partitions in HFS+.
As do most newer distros of GNU/Linux

If not how would I do this? [align partitions]

@jdmcdaniel3 - sorry the link did not open for you, I don’t know why, it opened ok for me, but apparently it has no value as it was written in 2009. I am putting my /home on another drive [HDD]and the swap also, i think.

@tsu2 - I am going to try your “Installing and Optimizing on SSD_abbreviated”
I am not too sure I understand about tempfs and such tho’
Is there a way to check to see if trim is enabled after I do the process in slide 19? Or shall I just take it for granted?
Does the archlinux site cover partition alignment?

@Knurpht - ok, so, did you do any of the optimization, trim, align procedures on your SSD’s? What version of opensuse are you using?

Thank You

tempfs is in memory. Think RAM disk. Anything in it is lost after a reboot

As goglethorp desribes, anything written to a tmpfs would be lost with a reboot or session termination which does not preserve data in memory. So, tmpfs is appropriate for anything <temporary> which is used by various functions and applications that are simply “calculating” but not always the end result. So, for instance you would not want to mount your /home or any other data or application directories but you really don’t care what is created <temporarily> to run your system and would be re-created anyway on next boot.

So, as my slide deck describes, disk layout is pre-planned by understanding what is only temporary and moving that into RAM where writes and reads would be orders faster than on any disk. Then, anything that is written only once but read many times like OS files are placed on the SSD where you can take full advantage of SSD’s very fast read capability and limit SSD write issues. For any data which potentially will be modified and written many times like download directories, User data, even most application data should be placed on your HDD.

Although there are several ways to define whether to apply special SSD commands and functions to whole systems or partitions, the method described in my slide deck is probably most suitable for systems with multiple types of storage media.

I have not heard that any kind of “alignment” is normally an issue, the only alignment issues I’m aware of is when a file system might have a different block size (particularly if not a multiple of) the underlying disk blocks <and> there is an offset. The only two situations I’m aware this could be an issue is when you use a Windows disk utility or if you re-deploy virtual file systems originally created on another physical machine. Most people on this List will only use Linux disk utilities and create/maintain virtual file systems locally, not move them around from one machine to another.

The last slides describe how to monitor your disk activity. Although I haven’t ever taken the time to actually try to monitor TRIM directly (wouldn’t even know for sure if possible), during normal use you should see absolutely zero SSD activity with intermittent spikes of read/write, and I have always assumed those spikes are TRIM activity.

Note the <very> important statement in my slidedeck which states that any recommendations and use of SSD 2011 and prior likely is not applicable to SSD manufactured 2012 and later, the technologies, design and manufacturing by all OEMs addressed many shortcomings automatically seen in earlier models.

TSU

Thanks, Tsu2, for creating the slide presentation. Very helpful to me.

I generally do my /home on a separate partition [which will now be on an HDD] and leave all others [/etc, /tmp, /var, etc. ]on the same partition as /. Would you recommend any of those [/var, /usr, /tmp, etc.] to go on the HDD as well?
I plan to have one SSD[OS] and 2 or 3 other HDD’s [/home and data storage].

I have not heard that any kind of “alignment” is normally an issue

I read about alignment on this site:
https://wiki.archlinux.org/index.php/Solid_State_Drives#Key_Features
on the bottom of the page Speed Up Your SSD By Correctly Aligning Your Partitions (using GParted)], but the article it links to is dated
Sep 6, 2011,

any recommendations and use of SSD 2011 and prior likely is not applicable to SSD manufactured 2012

so I guess it is outdated.

In your presentation, slide 17 mentions that SystemD[in opensuse 12.2] automatically mounts a number of directories into RAM. - *Do I need to know which they are and do I need to add more?

Thank You

Hi
I have a 60GB OCZ SSD (sda) and 250GB WD Black HDD (sdb) in this notebook;


 lsblk
NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0  55.9G  0 disk 
├─sda1   8:1    0   128M  0 part /boot/efi
├─sda2   8:2    0   128M  0 part 
└─sda3   8:3    0  55.7G  0 part /
sdb      8:16   0 232.9G  0 disk 
├─sdb1   8:17   0   128M  0 part 
├─sdb2   8:18   0   128M  0 part 
├─sdb3   8:19   0   140G  0 part /data
├─sdb4   8:20   0     8G  0 part /tmp
├─sdb5   8:21   0     4G  0 part /var/tmp
├─sdb6   8:22   0     4G  0 part /var/log
├─sdb7   8:23   0    16G  0 part [SWAP]
└─sdb8   8:24   0  60.7G  0 part 

I boot via UEFI and have the most written to partitions on the HDD rather that the SSD.

It does have Windows 7 installed in sdb8 as I have been testing the UEFI setup, but will get blown away soon :wink:

As suggested above, I have / on SSD, /home on HDD
One additional suggestion if you run Windows in a Virtual Machine (I use Vbox):

If SSD is large enough - create a root level directory for your VMs, e.g. /Virtual_Machines with rw permissions for you as owner.
Windows is a disk hog - you will see substantial VM performance improvement.
I’ll go so far as to say that Windows has never run better for me than in a Vbox VM under 12.2!
Set up a Vbox share on your /home (HDD) for big data files.

[redublicating from another thread where I posted]

& some more additional info for new users of SSD:

Partition alignment - but this can only be done with a clean system before you install either Linux or Windows. Partition alignment is critical for SSDs as, being memory-based devices, data is written and read in blocks known as pages. When partitions aren’t aligned, the block size of filesystem writes isn’t aligned to the block size of the SSD, causing extra overhead as data crosses page boundaries.

Aligning partitions is simply a matter of ensuring the first partition starts on a clean 1MB boundary from the start of the disk, ensuring whatever block size the filesystem uses will align with the block size of the SSD (which can also vary). If you create partitions using Windows 7/8 on an empty drive, it will start partitions at the 1MB boundary automatically.

In Linux, simply run ‘fdisk -cu (device)’ on the drive you want to partition, press ‘n’ for new partition, ‘p’ for primary and enter a start sector of at least 2,048 (same impleis when installing openSUSE and using GUI partitioner). The general rule is that the starting sector must be divisible by 512, but to cater for all variations of SSD page size and filesystem block size, 2,048 is a good idea (and equates to 1MB).

Though little old but still a good read: https://sites.google.com/site/lightrush/random-1/howtoconfigureext4toenabletrimforssdsonubuntu
& video on enabling TRIM: How to Enable Trim in Linux for SSD Solid State Disks - YouTube

As described, it only applies because the disk was originally prepared for Windows, likely using Windows utilities. If Windows is not already on this machine and you intend to install Linux in the first partition, I understand that you only need to wipe all partitions, then let the Installer create new.

If you are installing your root on the SSD and /home on an HDD, the slide in my slide deck should work almost “as is” without modification if you want to enable TRIM <and> disable journaling on your root partition.

TSU

@EazyVG

In Linux, simply run ‘fdisk -cu (device)’ on the drive you want to partition, press ‘n’ for new partition, ‘p’ for primary and enter a start sector of at least 2,048 (same impleis when installing openSUSE and using GUI partitioner). The general rule is that the starting sector must be divisible by 512, but to cater for all variations of SSD page size and filesystem block size, 2,048 is a good idea (and equates to 1MB).

Is alignment necessary? or does this apply?

Mac OSX Disk Utility aligns partitions in HFS+.
As do most newer distros of GNU/Linux

Its been a month since I have installed openSUSE 12.2 on my OCZ Vertex 4, following tsu2’s slide deck, with a slight modification to partitioning malcolmlewis’s scheme]. All seems to be working well. My thanks for all help and advice.

The only thing on this issue] I still need advice on is how to monitor/check [or if I need to] on read/writes.

If you’re running KDE, my slidedeck recommends two plasmoids, one for displaying each disk’s read/writes (both mb/sec and graph) and if running an nVidia GPU.

Both display in realtime which is more useful than reading logs.

TSU