Results 1 to 8 of 8

Thread: swap partition or not

  1. #1
    Join Date
    Jun 2016
    Beans
    18

    swap partition or not

    I have 64gb of ram. Should I do a swap partition or not?

  2. #2
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: swap partition or not

    Depends on the workload. You may have the only desktop capable of running Java applications and NOT sucking all the RAM up?
    For a server, I'd say probably not, if the workload is well understood.

    For a desktop, I'd say 4G is still my minimal recommendation. You'll probably never use it, but best to feel the slowdown first, before out-of-memory errors happen. I think there is little need to have more than 4G of swap on systems with more RAM ...6G, 8G, 16, 24, 32, 64G ... 4G is the swap size I'd set for a desktop.

    However, if you hibernate, then you'll need 64G + 1MB of swap.

    Good question, btw.

  3. #3
    Join Date
    Jun 2016
    Beans
    18

    Re: swap partition or not

    It is a desktop. The SSD is 512gb. What happens if I click hibernate and I don't have enough swap? I don't want to do 64gb of swap space. I like to sleep my computer, but isn't that different from hibernating?

  4. #4
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: swap partition or not

    Hibernate and sleep (suspend) are different.

    https://help.ubuntu.com/stable/ubunt...hibernate.html
    https://wiki.ubuntu.com/DebuggingKernelSuspend
    No swap? https://wiki.debian.org/Hibernation/...Swap_Partition

    I don't hibernate due to security considerations. Only suspend when at home, never out in the world. Security considerations again. Both of these things defeat the purpose for using disk encryption.

  5. #5
    Join Date
    Feb 2008
    Beans
    5,078
    Distro
    Xubuntu 16.04 Xenial Xerus

    Re: swap partition or not

    I have 16 GB of memory and no swap. I use Conky to monitor several things, including memory usage. Even doing a little video editing, I've never used 50% of my memory.

  6. #6
    Join Date
    Jun 2016
    Beans
    18

    Re: swap partition or not

    So should I just do 4gb swap?

  7. #7
    Join Date
    Apr 2013
    Beans
    8

    Re: swap partition or not

    No need for swap! I have 8 gb and i have swap, but i never used it. I don't think it hurts to have it but you probably don't need it
    --*If it don't kill you, it will make you stronger*--

  8. #8
    Join Date
    Aug 2009
    Beans
    Hidden!
    Distro
    Xubuntu

    Re: swap partition or not

    I have a 1MB swap partition. Just because...

    I never hibernate, just suspend when needed so, no need for more.

    I have Arch as my main OS but have Windows 10 for the wife and some games, plus a few other partitions; one has Xubuntu 16.04 on it.
    Whenever I install an OS it auto detects the swap file and I just point the ext4 system to which ever partition I'm installing on.

  9. #9
    Join Date
    Mar 2017
    Beans
    11

    Re: swap partition or not

    Of course! but just a small amount, in order for it to be beneficial that is; I'm only running 4GB ddr3 with 512mb swap at 8% cpu and 1.2G [0swap]
    PHP Code:
    Let's Roll the dice. 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •