LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 02-14-2011, 01:40 PM   #1
aloisius-a
LQ Newbie
 
Registered: Oct 2009
Distribution: Slackware, LFS
Posts: 27

Rep: Reputation: 0
SSD partitioning


Hi,

I would like to substitute a normal hard disk in an embedded Linux box (using a modified version of BLFS) which is perfectly operating with his SATA HDD, with an SSD, but I have never worked before now with SSDs.
I chose a 8 GB Transcend IDE flash module (TS8GDOM40V-S)
I partioned the SSD with fdisk and created two partitions, one of about 6 GB for root and one with the remaing space for swap.
This system does not operate at all, and now after many researches I know the problem is the alignment of the partition boundaries with the erasable segments of the SSD.
I did a research on the the but I am confused.
What I understood is that – for a correct operation and also for reasons of durability an speed - I have to align the partion boundaries to the erasable segments, but Linux requires a cylinder-based alignment and it is based on a logical geometry with 255 heads, 63 tracks, and 512 bytes/track. This logical geometry would require block size of 255 x 63 x 512 = 8225280 bytes.
I don't know the size of the erasable segments for my Transcend flash module, so I am forced to accep the value of 1048576 bytes (1 MiB).

The two aforesaid values are not compatible, between them and with an SSD with a size of a 8 GB.

Have somebody any ideas to resolve the problem?

Thank you.

aloisius-a
 
Old 02-14-2011, 02:45 PM   #2
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,981

Rep: Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625
Your problem is not related to the partition I'd think. The partition problem would be secondary to not working. Get it working first.
 
Old 02-16-2011, 08:21 AM   #3
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: Slackware®
Posts: 13,925
Blog Entries: 44

Rep: Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159
Hi,

You can get some good info on SSD custom configuration & alignment.
 
Old 02-16-2011, 07:46 PM   #4
salasi
Senior Member
 
Registered: Jul 2007
Location: Directly above centre of the earth, UK
Distribution: SuSE, plus some hopping
Posts: 4,070

Rep: Reputation: 897Reputation: 897Reputation: 897Reputation: 897Reputation: 897Reputation: 897Reputation: 897
Quote:
Originally Posted by aloisius-a View Post
I partioned the SSD with fdisk and created two partitions, one of about 6 GB for root and one with the remaing space for swap.
This system does not operate at all, and now after many researches I know the problem is the alignment of the partition boundaries with the erasable segments of the SSD...
What I understood is that – for a correct operation and also for reasons of durability an speed - I have to align the partion boundaries to the erasable segments, but Linux requires a cylinder-based alignment and it is based on a logical geometry with 255 heads, 63 tracks, and 512 bytes/track.
Your device is organised as:
Code:
                           C        H      S
TS8GDOM40V-S     8GB     15538     16     63
(...all that series are organised that way, it is just the cylinder number that varies to give the changed capacity)

However, I am pretty sure that alignment is not your problem. If you get this wrong, there will be excess wear in the flash device, potentially leading to premature failure, and there may be a slowdown, but the system should still boot.

Last edited by salasi; 02-16-2011 at 07:48 PM. Reason: code tags added to align columns
 
Old 02-18-2011, 01:34 AM   #5
ArthurSittler
Member
 
Registered: Jul 2008
Distribution: Slackware
Posts: 124

Rep: Reputation: 31
Maybe better to use no swap on SSD

Solid-state drives and all other flash and EEPROM memory suffer from write failure. The technology improves with time, but flash media may begin to show failures with a million or fewer writes. A million sounds like a big number, but the operating system that is swapping may be writing to swap thousands of times per minute. Other uses of the drive experience substantially fewer writes and are not likely to run up against the write wear problem. SSDs use internal wear leveling algorithms to distribute writes throughout the medium by remapping the physical location of logical sectors to extend medium life. The SSD also remaps the physical sectors to exclude sectors that fail due to write damage.

Reading from SSD and other flash memory does not degrade the media.

Write wear is not a problem with magnetic media. There is no limit to the number of times you can write to a particular location on a magnetic hard drive. Actually, there is a slightly higher probability of failure in a location in a hard drive that gets written very frequently because it increases the probability that a head crash, if it happens, will happen in a cylinder where the head spends more time. I have seem many more hard drive deaths due to spindle bearing failure than from head crashes. I have seen a few head crashes as well.

I install a lot of RAM in a computer with SSD. My little netbook has 1GB, which is as much as it can support. Other notebooks typically support 2GB or 4GB or more, though you need a 64-bit processor to access more than 4GB. When I run out of RAM my netbook thrashes and sometimes crashes, but that rarely happens. I simply reboot and the autosave usually has preserved most of my work. Autosave happens only every few minutes, not thousands of time per minute. I also only happens on while I am writing a document, not while compiling or accessing a database.

If I want to add swap to a computer with SSD, I use a USB pocket drive with a swap partition. An obsolete 20GB notebook drive in a USB case would be overkill for swap space. I allocated a few GB on my 250GB backup drive as swap space. I seldom connect the drive for the purpose of using the swap. My real machines (i.e., the desktop machines) have spinning disk or disks with a swap partition on each drive. I nearly never see any swap usage on those machines. I guess I don't really do anything fast enough or massive enough to need swap.

Having no swap space may prevent suspend/restore and hibernate functions, but in theory it is possible to provide these functions by dedicating disk space to those functions. On the other hand, if you have enough RAM that the machine never uses swap for any other purpose, then you could make a swap partition that is really only used for suspend or hibernate.

I do not feel any need for suspend or hibernate because my netbook with SSD can boot to a login prompt in about thirty seconds. Optimized versions of Linux may be able to boot within a few seconds. SSD reads are very fast except for some slow cheap drives like the one that came stock in my netbook. I replaced the stock drive with a larger and much faster device.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
SSD hydraMax Linux - Hardware 4 01-09-2011 12:09 PM
ssd slack66 Slackware 5 06-24-2010 12:56 AM
Firmware is not ssd? cccc Linux - General 3 12-31-2009 10:12 AM
[SOLVED] Using both SSD/HDD for partitioning or is it better to just get external HDD? Switch7 Linux - Hardware 16 10-26-2009 12:23 PM
SSD File System Partitioning jaycee4 Linux - Newbie 7 09-18-2009 03:48 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 08:37 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration