Author Topic: Just got a new ssd disk - is there anything i should know?  (Read 1637 times)

Offline sling-shot

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 1730
  • Satyameva Jayate | Truth Alone Triumphs.
Re: Just got a new ssd disk - is there anything i should know?
« Reply #15 on: December 10, 2012, 10:53:54 PM »
That should be possible. Once the installation is complete, you could login as root, then backup the new user directory under /home and copy your old user directory to its place. You would then need to setup proper permissions for the contents of this directory using "chown" command. (Had done it long back under Old-Polack's guidance so do not remember the exact steps)
Packaging well will cure headaches of many :) But learning to package will cause headaches in many :(

AMD AthlonX2 3600+/ASUS M2NPV-VM/ATi HD4670/Onboard sound/3.5GB DDR2-533 RAM/SEAGATE 160+320GB HDD/DELL S2240L FullHD/Creative SBS370 2.1/PCLinuxOS2013/KDE4
Samsung NP305U1-A06IN | Nokia E6

Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
Re: Just got a new ssd disk - is there anything i should know?
« Reply #16 on: December 11, 2012, 05:33:01 AM »
Makes me wonder what would be the result of wiping all free space, which is the approach I like to use .....

After deleting unneeded filesm write zeros to a file and continue to write to that file until the partition fills up.

then delete the file returning all the free space again ....  only now it is wiped of all previous content.

I imagine this would work just as well on SSDs as on HDDs.

My limited understanding of how they work,the ssd drive keep a certain sectors to itself,away from access from outside,when it notice a sector is going bad,it marks it as invalid and take a piece from its reserved space to replace it. This reserved space is also circulated to prevent it from being 100% unused while the "exposed" space is being over used.

So, you may, for example, create a file,delete it and the space of the deleted file may be taken to be part of the reserved space the file system has no access to and does not know it exists and overwriting the ssd multiple times will not overwrite the file because its in a location that can not be reached normally from outside.

Erasing a file on an ssd drive by conventional tools is not a guarantee the file is gone.

Standard HDDs also reserve space in the same manner ......  except they do not rotate that space.
So the same applies at any given moment with either .....  there will be reserved space that is not accessible to standard applications.



Standard HDD space reservation is a function of the OS and filesystem.  SSDs reserve space on the drive itself, regardless of OS or filesystem...

The HDDs controller board controls the reserved space on the HDD which can be used to swap out faulty sectors as required.
This is not a function of the OS or the filesystem.
In fact in most cases it is not accessible by such means.

I see no difference to this

Quote
the ssd drive keep a certain sectors to itself,away from access from outside,when it notice a sector is going bad,it marks it as invalid and take a piece from its reserved space to replace it.

So I have no idea what I am missing that some think I am resisting or something  ???

On both there will be reserved space that is not accessible to standard applications ......  which is what I said previously.

The above is my understanding ......  if I am wrong then please enlighten me ...... 

MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline rick0612

  • Sr. Member
  • ****
  • Posts: 258
  • The only dumb question is the one not asked.
Re: Just got a new ssd disk - is there anything i should know?
« Reply #17 on: December 11, 2012, 07:33:18 AM »
Hi,

Addressing the /home/me question, copy the files as the user from wherever to wherever so you don't need the chown command.
Whenever I install PCLOS, I copy the whole /home/me folder to an external drive before install. Do this as yourself by using Dolphin and moving up a level in the folder tree. Then just copy and paste the /home/me folder to the external drive. Going back the other way after install, just pick and choose which folders and files you want to recover. You have to tell Dolphin to show hidden files.
Hope this helps.

Rick.
Packaging rig: Averatec 2573 /12.1" screen /2.0GHZ /3GB RAM /120GB SSD /Minime 2012.12

Daily rig: Alienware X51 /23" monitor /Windows 7 host /KDE VBox client

Offline muungwana

  • Hero Member
  • *****
  • Posts: 6248
Re: Just got a new ssd disk - is there anything i should know?
« Reply #18 on: December 11, 2012, 08:16:57 AM »

So I have no idea what I am missing that some think I am resisting or something  ???

On both there will be reserved space that is not accessible to standard applications ......  which is what I said previously.

The above is my understanding ......  if I am wrong then please enlighten me ...... 


What you are missing is what "wear leveling does",will quote from the link i provided to show what it does
section 5.17 of the following link partly reads: http://code.google.com/p/cryptsetup/wiki/FrequentlyAskedQuestions
Quote
    The problem is that you cannot reliably erase parts of these devices, mainly due to wear-leveling and possibly defect management.

    Basically, when overwriting a sector (of 512B), what the device does is to move an internal sector (may be 128kB or even larger) to some pool of discarded, not-yet erased unused sectors, take a fresh empty sector from the empty-sector pool and copy the old sector over with the changes to the small part you wrote. This is done in some fashion so that larger writes do not cause a lot of small internal updates.

    The thing is that the mappings between outside-adressable sectors and inside sectors is arbitrary (and the vendors are not talking). Also the discarded sectors are not necessarily erased immediately. They may linger a long time.


http://en.wikipedia.org/wiki/Wear_leveling

Part of the link reads:
Quote
Dynamic wear leveling

The first type of real leveling is called dynamic wear leveling and it uses a map to link Logical Block Addresses (LBAs) from the OS to the physical Flash memory. Each time the OS writes replacement data, the map is updated so the original physical block is marked as invalid data, and a new block is linked to that map entry. Each time a block of data is re-written to the Flash memory it is written to a new location. However, blocks that never get replacement data sit with no additional wear on the Flash memory. The name comes from only the dynamic data is being recycled. The drive may last longer than one with no wear leveling, but there are blocks still remaining as active that will go unused when the drive is no longer operable.


I do not think rotational hard drives does the quoted part.
My understanding of the two is that,let say you have a 20MB file,the traditional way of erasing it is overwriting the file with random data and then deleting it,with wear leveling technology,the overwriting part of the operation may happen at a different location on disk,leaving the original file it tack,the file will be copied somewhere else and the overwriting will happen over the "new" file that was copied over before the writing commence and end result is that the original file is still around and a new file has overwritten data and then get deleted.

The 20MB "original file" that now lies on a part of the drive that is now marked as empty may then be rotated to the internal storage pool of the drive and as the last paragraph of the first quote say,may stay there for a really long time and you cant know when it will be rotated back to the pool of sectors can be used.
.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Offline pags

  • Hero Member
  • *****
  • Posts: 2519
  • Keep it clean.
Re: Just got a new ssd disk - is there anything i should know?
« Reply #19 on: December 11, 2012, 08:26:59 AM »
muungwana beat me to it...

Might I add, that for rotational drives, the reserved portion is used to handle the remapping of bad blocks, as they occur, but once data is written to a "good" location, it is static in that location.  SSDs will move that data around, as well as moving the "reserved space" around, in an attempt to all the locations evenly (so one area doesn't fail due to old age before others do).

Found an interesting read:
http://articles.forensicfocus.com/2012/01/27/forensic-imaging-of-hard-disk-drives-what-we-thought-we-knew-2/

Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
Re: Just got a new ssd disk - is there anything i should know?
« Reply #20 on: December 11, 2012, 08:33:27 AM »
Thanks muungwana, but I had not missed that .....  

Quote
My understanding of the two is that,let say you have a 20MB file,the traditional way of erasing it is overwriting the file with random data and then deleting it,with wear leveling technology,the overwriting part of the operation may happen at a different location on disk,leaving the original file it tack,the file will be copied somewhere else and the overwriting will happen over the "new" file that was copied over before the writing commence and end result is that the original file is still around and a new file has overwritten data and then get deleted.

This brings me back to my question about using a file to fill all available space, writing zeros to it, and then deleting it.

When a file is moved due to wear levelling ... well copied really ....  the original is still there but not referenced any more, which *could* be a privacy/security risk at some later time.

So ....  the problem appears to be that the time from the original being copied to another location and when that original location is flagged as available to be reused, is unknown and may be considerable?
If it is not flagged as available, then writing to free space will not overwrite it?

Is this what I was missing?  --- the time between the two actions?

Thanks for the further explanation  ;)



MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline muungwana

  • Hero Member
  • *****
  • Posts: 6248
Re: Just got a new ssd disk - is there anything i should know?
« Reply #22 on: December 11, 2012, 09:35:07 AM »
When a file is moved due to wear levelling ... well copied really ....  the original is still there but not referenced any more, which *could* be a privacy/security risk at some later time.

In the traditional media,when you delete a file,the file system just un reference it,the file still remain on disk but cant be accessed through the filesystem normal operations but still accessible with some specialized tools. Since the file is still there then this "*could* be a privacy/security risk at some later time".

You seem to take this "*could*" serious enough to take the trouble to overwrite a file before you delete it when on rotational media. Why dont you take the same "*could*" seriously with ssd? The only way to "really" delete a file on ssd is to use "ssd secure erase" option but its an all or nothing option and hence effective only when wiping the entire drive,not individual files.

File systems leaves the original files intact when they are deleted,ssd hardware,far away from view,leaves original files intact when they are overwritten. The same "*could*" apply to both. I suspect your lack of appreciation of what is presented primarily comes from giving the two "*coulds*" different weights.

You should read up more on this from people who know what they are talking about and wrote the explanations in unambiguous terms and with greater clarity. We may be misrepresenting things or not giving the info with greater clarity and you could be stuck on our lack of proper explanation skills.
.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
Re: Just got a new ssd disk - is there anything i should know?
« Reply #23 on: December 11, 2012, 01:26:37 PM »


Found an interesting read:
http://articles.forensicfocus.com/2012/01/27/forensic-imaging-of-hard-disk-drives-what-we-thought-we-knew-2/



Thanks for the link  ;)


I found a paper which answers all my questions but am unsure how dated it is and if some extra functions might have been implemented in modern SSDs or not.

It seems I will continue to use my SSD/s for operating systems and not for any user data due to the lack of reliable secure erasure of the whole disk, and none for individual files.

That is how I interpret it anyway ....

http://static.usenix.org/events/fast11/tech/full_papers/Wei.pdf

Quote
Sanitizing storage media to reliably destroy data is an essential aspect of overall data security.
We have empirically measured the effectiveness of hard drive-centric sanitization techniques on flash-based SSDs.
For sanitizing entire disks, built-in sanitize commands are effective when implemented correctly, and software techniques work most, but not all, of the time.
We found that none of the available software techniques for sanitizing individual files were effective.
To remedy this problem, we described and evaluated three simple extensions to an existing FTL that make file sanitization fast and effective.
Overall, we conclude that the increased complexity of SSDs relative to hard drives requires that SSDs provide verifiable sanitization operations.


Added:
           Following on from the above and not relying on the manufacturers secure erase, a secure erase scheme is proposed and tested which allows for the secure erasure of a complete SSD drive .... it seems simple and effective ..... a completely encrypted disk ....  destroy the encryption key ....... and then overwrite everything .....

Quote
SAFE assumes that data in the SSD is stored in encrypted form and that the SSDs implements best practices with respect to key management (e.g., that the key should never leave the controller).

The SAFE algorithm is as follows:

1. Upon receiving a sanitize command, sanitize the memory containing the cryptographic keys.

2. Mark the drive as being KEYLESS.

3. Erase every block in the device, overwrite all pages with a known pattern, and erase them again.

4. Mark the drive as being VERIFIABLE.

5. Upon receiving a re-initialization command, perform a low-level format the drive.


http://cseweb.ucsd.edu/users/m3wei/assets/pdf/safe-paper.pdf
« Last Edit: December 11, 2012, 02:08:24 PM by Just17 »
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline ShowMeRon

  • Full Member
  • ***
  • Posts: 163
Re: Just got a new ssd disk - is there anything i should know?
« Reply #24 on: December 11, 2012, 02:10:40 PM »
 A hammer and anvil will "sanitize" it  :o
take me drunk......i'm home                                                                                  Registered Linux user #446923

Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
Re: Just got a new ssd disk - is there anything i should know?
« Reply #25 on: December 11, 2012, 03:01:37 PM »
A hammer and anvil will "sanitize" it  :o

;D

Yeah ....  but you will never use it again  :D
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline Old-Polack

  • Administrator
  • Super Villain
  • *****
  • Posts: 11591
  • ----IOFLU----
Re: Just got a new ssd disk - is there anything i should know?
« Reply #26 on: December 11, 2012, 03:59:43 PM »
A hammer and anvil will "sanitize" it  :o

;D

Yeah ....  but you will never use it again  :D

I don't know... if it's flat enough it might make a good book marker, or spatula.  ;D
Old-Polack

Of what use be there for joy, if not for the sharing thereof?



Lest we forget...

Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
Re: Just got a new ssd disk - is there anything i should know?
« Reply #27 on: December 11, 2012, 04:01:31 PM »
 ;D
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT