1

Today I began experiencing regular freezes on Xubuntu, within 5 minutes of booting up or so. No particular program seems to trigger the freeze, and I don't recall any modifications of my system recently before the problem began.

One strange thing I noticed was the output of "free -h". The swap line had all zeros under used, free, and share. I then went to Gparted and noticed a yellow warning sign for the swap partition (see photo 1). I clicked on the yellow warning sign and got more detail (see photo 2). I then used Gparted to reformat that partition. I used the format linux-swap. Then I tried free -h again but the swap line still had all zeros. Is there something else I needed to do in order for Xubuntu to recognize the swap partition? Could this swap partition even be related to the freezing problem?

I should also mention that the SysRq key does not seem to be working on my keyboard. Looking at other forum posts related to this problem led me to try alt+sysrq+f and alt+sysrq+reisub but nothing happens. Anorther thing I notice is that every time the system freezes the Caps lock light starts flashing!

Any help would be greatly appreciated. Photo 1

Photo 2

1 Answer 1

1

The CAPS lock light flashing means that you didn't have a freeze, you had a hard kernel crash.

Best to solve the swap partition this way...

  • in terminal do a sudo swapoff -a to disable all swaps
  • in terminal do sudo cp /etc/fstab /etc/fstab.bak
  • use gparted to delete /dev/sda6 and recreate it as linux-swap
  • in terminal do a sudo mkswap /dev/sda6 (assuming that the new swap partition is still sda6)
  • note the new UUID
  • copy the new UUID to the clipboard
  • in terminal do gksudo gedit /etc/fstab
  • find the line that has "swap" in it
    • ie: UUID=071f8b0e-8e16-4f4d-90ff-a4ae9cc56e2b none swap sw 0 0
  • replace the existing UUID with the new UUID with a paste
  • save the file and quit gedit
  • in terminal do sudo swapon -a
  • in terminal do free -h and swapon -s
  • confirm that swap is showing correctly now

Update #1:

  • check to see if this file exists...

    ls -al /etc/initramfs-tools/conf.d/resume

  • if it does, update it with the UUID of the swap partition you obtained earlier...

    gksudo gedit /etc/initramfs-tools/conf.d/resume

    sudo update-initramfs -u

6
  • free -h still returns zeros and swapon -s still returns nothing. I noticed when editing fstab that the line where I entered the new UUID began with '#'. Does this mean that line is commented out? Should I remove the # sign?
    – user87317
    Jul 12, 2017 at 7:22
  • You're correct. The swap line is commented out, probably because of the problem with the swap partition. Remove the # and then try the last 3 commands from my answer. Does gparted now show a correct swap partition? Report back.
    – heynnema
    Jul 12, 2017 at 18:40
  • @user87317 ps: also do my update #1
    – heynnema
    Jul 12, 2017 at 20:08
  • Awesome. Yes, removing the '#' does it and Gparted does show a correct swap partition. It turned out that the file from update #1 didn't exist. Thanks for your help, @heynnema !
    – user87317
    Jul 13, 2017 at 4:26
  • @user87317 Great news! Does the free -h and swapon -s now show correctly?
    – heynnema
    Jul 13, 2017 at 13:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .