Physical Location of a Swap Partition



since it looks like I am not even using the swap could I simply do a swapoff and delete the swap partition?

Yes, the fact that it is not being used is what I have said all along, and Brian has mentioned it as well. But you are the one with the nVidia, and so the above was a compromise to evaluate.

If you delete the swap, you will have to go into /etc/fstab and at least comment out the line referring to swap (put a hash in front of it).

Then reboot, and if start time and shutdown time are slow, it means Linux is performing a search for a suspend/resume device (which it uses Swap for) - which we can fix.

Wiz
 
Code:
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a device; this may
# be used with UUID= as a more robust way to name devices that works even if
# disks are added and removed. See fstab(5).
#
# <file system>             <mount point>  <type>  <options>  <dump>  <pass>
UUID=489D-FC40                            /boot/efi      vfat    defaults,noatime 0 2
UUID=9987d8bb-832a-44b8-b78f-0e192a360884 /              ext4    defaults,noatime,discard 0 1
UUID=4c2b60d6-ccdb-4dec-8fcb-5821c5da94d3 swap           swap    defaults,noatime,discard 0 2
tmpfs                                     /tmp           tmpfs   defaults,noatime,mode=1777 0 0
 
Yep, not unexpected, I have to go for my evening, back on deck prob in about 15 hours.

We can fix the start lag then.

Wiz
 
Have a great evening! I'm on call again tonight (that's Sunday night here in the US), I start again around the same time.
 
Quick question before I have to go out again for a bit.

Did you use

Code:
sudo nano /etc/fstab

to put a hash in front of

Code:
UUID=9987d8bb-832a-44b8-b78f-0e192a360884 /              ext4    defaults,noatime,discard 0 1

#followed (after save and exit) by

sudo update-grub

?

Wiz
 
I hate to appear stupid... BUT (in this case I'll plead stupidity). I am not understanding what to do with that second line as quoted above. :confused:
No, not stupid... this is still new stuff. I'll just briefly butt in since Wizard is gone for the moment. He is simply asking you to run another distinct command after you save the changes in /etc/fstab.

Code:
sudo update-grub

This forces the grub to examine the changes you made. I think it stores this info elsewhere.

Cheers
 
Thanks! Yes, I do get that. What I am unclear of is that 2nd line of code. Do I just enter it as he has it or do I delete that 2nd line that lists the now deleted swap partition?
 
Ah, my mistake. Sorry.

Since you have deleted the swap partition, you could edit fstab and delete the line that refers to it. Save the file, and run sudo update-grub.

I think that he was saying to exit the file and place a # character in front of the line that refers to the swap partition, then save the file and run sudo update-grub.

The # character makes that line a comment... so it would not be read and acted upon by the system. The effect is the same as deleting... taking it out of the picture. But update-grub completes this process.
 
Damn. My mistake again. He seems to be telling you to comment out an ext4 partition, not swap.

Better wait till he returns. I'm not sure now what he's doing. :confused::confused::confused:
 
UUID=4c2b60d6-ccdb-4dec-8fcb-5821c5da94d3 swap swap defaults,noatime,discard 0 2

Ok, before I do this let me run it past you. Above is the 2nd line. So I delete it and in it's place put
Code:
#followed (after save and exit) by

Or just delete the 2nd line, save & exit, then

Code:
sudo update-grub
 
No worries! I will wait until he comes back. I don't want to do anything to screw it up - I finally have this laptop working well!
 
Right! Don't delete anything. I do understand some of your confusion, but I'm on my phone and it's hard to follow clearly and keep up. Chris will clear it up.

But FYI,
Code:
#followed (after save and exit) by
is not a command. He's just giving a further instruction, using the # to point out that this is a comment to you inside the code tags.

So he says to put a hash (#) in front of the ext4 line in fstab... making that a comment. Then save the file. And following the file save then run update-grub.

Clear as mud now? :confused::eek::D:D
 
UUID=4c2b60d6-ccdb-4dec-8fcb-5821c5da94d3 swap swap defaults,noatime,discard 0 2

Nope my bad. The line above is the one that I wanted the hash to go in front of.

Ta Stan for running interference for me and regrets for the confusion Jeffrey

Wizard :rolleyes:o_O:eek::confused:

BTW but as Stan has said, if the Swap is deleted, you can in fact delete that whole line carefully
 
No worries! I am beginning to learn the nomenclature and terminology but when I am unsure, I'm asking!

So it should look like this:
Code:
#UUID=9987d8bb-832a-44b8-b78f-0e192a360884 /              ext4    defaults,noatime,discard 0 1

And I should delete the second line?

Code:
UUID=4c2b60d6-ccdb-4dec-8fcb-5821c5da94d3 swap           swap    defaults,noatime,discard 0 2

Then run:

Code:
sudo update-grub
 

Staff online


Top