Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Swap - how big?

  • 18-01-2010 11:20pm
    #1
    Registered Users, Registered Users 2 Posts: 326 ✭✭


    Got hold of a nice quad recently as well as 4Gb of fast ddr3 ram. Always have gone with the 2Xram rule of thumb for swap.... now however wondering would 8Gb be too generous? Mainly using the box for the light stuff (net, movies, musis.. blah, blah), bit of encoding and would fire up a VM once in a blue moon. What do you suggest?


Comments

  • Registered Users, Registered Users 2 Posts: 545 ✭✭✭ravydavygravy


    For that level of usage, I'd suggest no swap. You can always add a swapfile later. If you are only using the machine for light work, you'll never use all your RAM.


  • Registered Users, Registered Users 2 Posts: 14,042 ✭✭✭✭Johnboy1951


    Depends on whether you want to suspend to disk or not.
    If not I would create a 500MB to 1GB swap partition -- just in case!


  • Closed Accounts Posts: 4,564 ✭✭✭Naikon


    Forget the swap partition. My system has 3 gigs at the moment and does not run out of physical memory under heavy load.
    What you could do(ravydavygravy suggested it) is allocate a file for use as swap. Much better and handier than resizing physical
    partitions->
    dd if=/dev/zero of=/swap_file bs=1024 count=524288
    mkswap /swap_file
    swapon /swap_file
    echo "/swap_file   swap   swap   defaults 0 0" >> /etc/fstab
    

    swap_file which is now in use for swapping purposes is located in the root directory.
    Count can be smaller or larger as preferred, but you should keep it close to the number
    of blocks you would allocate to a normal swap partition. It's up to you.


  • Registered Users, Registered Users 2 Posts: 37,485 ✭✭✭✭Khannie


    For that level of usage, I'd suggest no swap. You can always add a swapfile later. If you are only using the machine for light work, you'll never use all your RAM.

    I read recently that having no swap can negatively impact performance. Better to have a very very small swap partition than none.


  • Registered Users, Registered Users 2 Posts: 1,606 ✭✭✭djmarkus


    I generally make swap as big as ram, never know when you need to hibernate. Disk space is cheap


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 1,606 ✭✭✭djmarkus


    Naikon wrote: »
    Forget the swap partition. My system has 3 gigs at the moment and does not run out of physical memory under heavy load.
    What you could do(ravydavygravy suggested it) is allocate a file for use as swap. Much better and handier than resizing physical
    partitions->
    dd if=/dev/zero of=/swap_file bs=1024 count=524288
    mkswap /swap_file
    swapon /swap_file
    echo "/swap_file   swap   swap   defaults 0 0" >> /etc/fstab
    

    swap_file which is now in use for swapping purposes is located in the root directory.
    Count can be smaller or larger as preferred, but you should keep it close to the number
    of blocks you would allocate to a normal swap partition. It's up to you.

    I really dont agree with this. its pagefile.sys all over again, you end up with a segmented swap file and filesystem overhead.

    Its very easy to manage swap space using LVM, which nearly every installer does by default these days


  • Registered Users, Registered Users 2 Posts: 326 ✭✭slowlydownwards


    Thanks for all your replies. :) I do realize that this discussion is more academic than practical since hard drive space is so cheap nowadays. It's good to know that dynamic page file can be allocated within the root partition (vindoz style :p) ... but doesn't it seem a bit.... sloppy, for the lack of a better word. Anyhow, maybe I'm just old fashioned... taught always to separate well... root from user files, from swap, from boot partition and so on. Again, thanks for all the replies. Will be wiping the hard drive anyhow for a clean install, so will probably repartition allowing 2gb or so for a swap drive.


Advertisement