[SOLVED] Linux Mint 18.x SSD post-installation guide

Questions about hardware, drivers and peripherals
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
matteo92

[SOLVED] Linux Mint 18.x SSD post-installation guide

Post by matteo92 »

Yesterday I installed Linux Mint Cinnamon 18.3 on my laptop featuring Samsung SSD 256GB (the entry level one). I have used this SSD for about 3 years on Win10, I am now wondering about the correct SSD management on Linux Mint.

I have deeply read this interesting guide:
SSD: how to optimize your Solid State Drive for Linux Mint 18.x
https://sites.google.com/site/easylinuxtipsproject/ssd

Should I consider it as a reliable source? I think that ext4, noatime, swap-reduce operations are reasonable and I am gonna apply them. On the other hand, I wonder wheter I should find some official firmware and how to install it (Windows had is proprietary software Samsung Magician for this kind of stuff). Moreover, that guide suggest to dramatically reduce (let's say... totally delete) any kind of browser cache from Firefox and Chrome/Chromium. What do you think? Is there an official guideline for SSD maintenance on Mint?

Thanks a lot!

PS. SSD specs listed below

Code: Select all

sudo hdparm -I /dev/sda       

/dev/sda:

ATA device, with non-removable media
	Model Number:       Samsung SSD 850 EVO 250GB               
	Serial Number:      S21PNSAG749852V     
	Firmware Revision:  EMT02B6Q
	Transport:          Serial, ATA8-AST, SATA 1.0a, SATA II Extensions, SATA Rev 2.5, SATA Rev 2.6, SATA Rev 3.0
Standards:
	Used: unknown (minor revision code 0x0039) 
	Supported: 9 8 7 6 5 
	Likely used: 9
Configuration:
	Logical		max	current
	cylinders	16383	16383
	heads		16	16
	sectors/track	63	63
	--
	CHS current addressable sectors:   16514064
	LBA    user addressable sectors:  268435455
	LBA48  user addressable sectors:  488397168
	Logical  Sector size:                   512 bytes
	Physical Sector size:                   512 bytes
	Logical Sector-0 offset:                  0 bytes
	device size with M = 1024*1024:      238475 MBytes
	device size with M = 1000*1000:      250059 MBytes (250 GB)
	cache/buffer size  = unknown
	Nominal Media Rotation Rate: Solid State Device
Capabilities:
	LBA, IORDY(can be disabled)
	Queue depth: 32
	Standby timer values: spec'd by Standard, no device specific minimum
	R/W multiple sector transfer: Max = 1	Current = 1
	DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 udma5 *udma6 
	     Cycle time: min=120ns recommended=120ns
	PIO: pio0 pio1 pio2 pio3 pio4 
	     Cycle time: no flow control=120ns  IORDY flow control=120ns
Commands/features:
	Enabled	Supported:
	   *	SMART feature set
	    	Security Mode feature set
	   *	Power Management feature set
	   *	Write cache
	   *	Look-ahead
	   *	Host Protected Area feature set
	   *	WRITE_BUFFER command
	   *	READ_BUFFER command
	   *	NOP cmd
	   *	DOWNLOAD_MICROCODE
	    	SET_MAX security extension
	   *	48-bit Address feature set
	   *	Device Configuration Overlay feature set
	   *	Mandatory FLUSH_CACHE
	   *	FLUSH_CACHE_EXT
	   *	SMART error logging
	   *	SMART self-test
	   *	General Purpose Logging feature set
	   *	WRITE_{DMA|MULTIPLE}_FUA_EXT
	   *	64-bit World wide name
	    	Write-Read-Verify feature set
	   *	WRITE_UNCORRECTABLE_EXT command
	   *	{READ,WRITE}_DMA_EXT_GPL commands
	   *	Segmented DOWNLOAD_MICROCODE
	   *	Gen1 signaling speed (1.5Gb/s)
	   *	Gen2 signaling speed (3.0Gb/s)
	   *	Gen3 signaling speed (6.0Gb/s)
	   *	Native Command Queueing (NCQ)
	   *	Phy event counters
	   *	READ_LOG_DMA_EXT equivalent to READ_LOG_EXT
	   *	DMA Setup Auto-Activate optimization
	    	Device-initiated interface power management
	   *	Asynchronous notification (eg. media change)
	   *	Software settings preservation
	    	Device Sleep (DEVSLP)
	   *	SMART Command Transport (SCT) feature set
	   *	SCT Write Same (AC2)
	   *	SCT Error Recovery Control (AC3)
	   *	SCT Features Control (AC4)
	   *	SCT Data Tables (AC5)
	   *	reserved 69[4]
	   *	DOWNLOAD MICROCODE DMA command
	   *	SET MAX SETPASSWORD/UNLOCK DMA commands
	   *	WRITE BUFFER DMA command
	   *	READ BUFFER DMA command
	   *	Data Set Management TRIM supported (limit 8 blocks)
Security: 
	Master password revision code = 65534
		supported
	not	enabled
	not	locked
		frozen
	not	expired: security count
		supported: enhanced erase
	2min for SECURITY ERASE UNIT. 8min for ENHANCED SECURITY ERASE UNIT. 
Logical Unit WWN Device Identifier: 5002538da0318e19
	NAA		: 5
	IEEE OUI	: 002538
	Unique ID	: da0318e19
Device Sleep:
	DEVSLP Exit Timeout (DETO): 50 ms (drive)
	Minimum DEVSLP Assertion Time (MDAT): 30 ms (drive)
Checksum: correct
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: SSD post-installation tips: are they really necessary?

Post by catweazel »

The site is maintained by Pjotr who is a regular here. It's reliable and reputable. I wouldn't worry about looking for firmware and I highly recommend you take the optional step 5 and over-provision the drive. This will allow the drive controller to allocate bad blocks from the spare space and extend the life of your SSD. I use a 20% over-provision. I don't bother moving browser caches either but there's no reason you shouldn't do it.
Is there an official guideline for SSD maintenance on Mint?
No, but in linux, the steps recommended by Pjotr's site are very standard.
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
matteo92

Re: SSD post-installation tips: are they really necessary?

Post by matteo92 »

catweazel wrote: Sat Mar 10, 2018 5:06 am I highly recommend you take the optional step 5 and over-provision the drive. This will allow the drive controller to allocate bad blocks from the spare space and extend the life of your SSD. I use a 20% over-provision. I don't bother moving browser caches either but there's no reason you shouldn't do it.
Thanks for your quick reply. this is the setup of my SSD
Image]
I think I am gonna install Gparted to check it better, What's the best option to create a wise partition architecture while the system is already installed. It seems to me that my actual disk is like this:
BEGIN --> System Partition (root + home) --> Swap partition --> End
I could do something like
BEGIN --> System Partition --> void space (about 10GB) --> Swap partition --> End
Hence, I am gonna reduce slightly the system partition, which I far way bigger than Linux requirements. What do you think?
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: SSD post-installation tips: are they really necessary?

Post by catweazel »

matteo92 wrote: Sat Mar 10, 2018 5:50 am What's the best option to create a wise partition architecture while the system is already installed. It seems to me that my actual disk is like this:
BEGIN --> System Partition (root + home) --> Swap partition --> End
I could do something like
BEGIN --> System Partition --> void space (about 10GB) --> Swap partition --> End
Hence, I am gonna reduce slightly the system partition, which I far way bigger than Linux requirements. What do you think?
I would recommend reinstalling, actually. The work required to get you up and running with a smaller root / and a separate home partition is quite involved. Besides, your swap partition is at the end of the drive and if you're going to over-provision to extend the SSD's life then it can't stay there, it has to be deleted and recreated further in, leaving the blank space at the end of the drive instead. If it were my machine I would follow these steps:

1) Go ahead and reduce your current root (/ or system partition, if you like) to say, between 32-40GB. That should be more than enough, but then it's up to you.

For comparison, my system currently consumes just on 30GB. Some people will tell you much less is required, as low as 20GB, but my opinion is that this is misinformed and doesn't take account of unknown needs in the future.

2) Delete the swap partition.

3) Create a new ext4 partition in the large empty space but leave between 10-20% of the drive's capacity plus a fraction more than your installed RAM. So, if you have a 256GB SSD and 8GB of RAM, you want to leave between 25+8 to 50+8 GB free.

4) Create a swap partition immediately after the new partition created in step 3. Make it, say, 10% bigger than the size of your RAM, so 9GB swap for 8GB RAM. This is so you can hibernate. You can make it the same size as your RAM but I'm dubious about how easy it is to get the exact size right, so I'm just playing safe here.

You should now have about 25-50GB free at the end of the drive. That's the over-provision and the Samsung SSD will use it when needed.

During the install, select the 'something else' option. Mark the first 40GB partition for mounting as root (/), format ext4. Select the second partition and mark it to be mounted as your /home, again format as ext4. If the third partition is already marked as swap, which it should be, just leave it. Linux will auto-detect it and use it. You can then proceed to install.

Good luck.
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
matteo92

Re: SSD post-installation tips: are they really necessary?

Post by matteo92 »

Thank you so much, now I have clear in my mind what to do. It is a pity that the automatic partitioning does not take into account a separate home + root configuration. I could have avoided to format the whole system...In fact, I am a little bit concerned about formatting a re-installing a fresh system, when in about one month the new Ubuntu LTS will be released, and Linux Mint will follow. I think I will keep these precious pieces of information for the new LTS install.

Anyway, I can almost consider this topic fully SOLVED, thanks. My very final question is about boot partition under a UEFI system like mine... should I partition differently than the three partitions + void space that you suggested me?
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: SSD post-installation tips: are they really necessary?

Post by catweazel »

matteo92 wrote: Sat Mar 10, 2018 6:45 am Thank you so much, now I have clear in my mind what to do. It is a pity that the automatic partitioning does not take into account a separate home + root configuration. I could have avoided to format the whole system...In fact, I am a little bit concerned about formatting a re-installing a fresh system, when in about one month the new Ubuntu LTS will be released, and Linux Mint will follow. I think I will keep these precious pieces of information for the new LTS install.
Don't worry about it. Your Samsung SSD is good for up to 100TB written. You won't do any damage to it any time soon by reinstalling. Crikey, I reinstall every couple of months, and sometimes three times in a day :)
Anyway, I can almost consider this topic fully SOLVED, thanks. My very final question is about boot partition under a UEFI system like mine... should I partition differently than the three partitions + void space that you suggested me?
Ah, that's different. First, BIOS boot loaders are less likely to cause issues, unlike UEFI. If your BIOS supports legacy BIOS boot then I suggest switching it over to BIOS, otherwise... if the drive is already partitioned for UEFI then leave that partition as it is and mark it for mounting as /boot/efi. This partition must be formatted FAT32. It should also be the first partition on the disk, but as I said, if you're already setup for UEFI it shouldn't be an issue. Just be aware that you won't be able to partition the drive further without creating what is called an extended partition.

You may find this article very helpful.
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
matteo92

Re: SSD post-installation tips: are they really necessary?

Post by matteo92 »

Ok, thank you. I think I will stick to the guide I mentioned in my first post and apply it step by step. Meanwhile, I will understand how to do manual partitioning that optimize my UEFI + SSD configuration, it seems to be quite a tricky matter =)

I will put SOLVED, since my initial issue is over, even though many others will arise lol
Last edited by matteo92 on Sat Mar 10, 2018 8:28 am, edited 1 time in total.
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: SSD post-installation tips: are they really necessary?

Post by catweazel »

matteo92 wrote: Sat Mar 10, 2018 7:27 am Ok, thank you.
You're more than welcome. It was a pleasure to assist.
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
Locked

Return to “Hardware Support”