LINUX LITE 7.2 FINAL RELEASED - SEE RELEASE ANNOUNCEMENTS SECTION FOR DETAILS


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Swappiness
#1
Would those of us who use LL2.2 benefit at all from reducing the swappiness ?

I ask only because it was a recommended thing to do in ubuntu 14.04
Bruno
Reply
#2
Depends on the gear

Code:
harry@biker1:~$ sudo parted -l
[sudo] password for harry:
Model: ATA APPLE SSD SM128 (scsi)
Disk /dev/sda: 121GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number  Start   End     Size    File system  Name  Flags
1      1049kB  9438MB  9437MB  ext4
2      9438MB  121GB   112GB   ext3


harry@biker1:~$ free
             total       used       free     shared    buffers     cached
Mem:       2023948    1697956     325992     142604      73468    1057104
-/+ buffers/cache:     567384    1456564
Swap:            0          0          0


I run no swap on SSD out of personal preference.
LL 3.6,2.8
Dell XT2 > Touchscreen Laptop
Dell 755 > Desktop
Acer 150 > Desktop
I am who I am. Your approval is not needed.
Reply
#3
I found this article interesting on the subject of swappiness.

http://unix.stackexchange.com/questions/...by-default
“I have not failed. I’ve just found 10,000 ways that won’t work.” - Thomas Edison
Reply
#4
I'm curious why swap partitions are recommended instead of swapfiles?
I use one 4 GB swapfile that lives on my data partition for all my OS's.

Am I being a silly billy?
Reply
#5
@ ukbrian

I still class my self as new to Linux March/April this year when I really took the plunge.
If you ask 10 "guru's" you will probably get 10 different answers to the "Best" set-up.?

I can only give you my take on it, but it depends on a few initial factors:
1. What Hardware you currently have, unless you are willing to upgrade, or are building a new PC
2. What are you going to be doing, Day to Day just general stuff, Development work, Production Desktops/Servers

From this, and from what I have read/found there are a myriad of different configuration/set-up options.

So going to the original post on "swappiness", from what I have picked up(read)
Changing this value is only useful if you have a reasonable amount of memory 4GB+
It means you will use "faster memory", instead of potentially "slower" disk access for swap activity.
But with the caveat of point "2" above, in some case you may see no noticeable improvements.

To your point on "swapfile", Again, it is a combination of points "1 & 2" above.
If you have a small amount of memory, a swapfile can be useful for certain uses, and also if you want to "Hibernate"
Should it be a on a separate partition.??, back to point "1 & 2",
I have seen some recommendations where they have 7 or 8 different types of partition spread across multiple drives

Also, but not actually done/tried it yet.?,
having a separate /swap partition means you can share it in a multi boot set-up and save some disk space,

For me, I have come to a balance of 4 partitions:[size=1em] /root , /home , /data , /swap [/size]
I can easily just back my /data or my /home and hopefully keep upgrades simpler.?
But it needs a bit of config & set-up after installs

One thing I have read and seen, but I'm still not clear if it it's done by default/automatically, and not obvious.??
If you have a reasonable amount of memory 4GB+ is moving the "temp & tmp" from disk to memory via "fstab" at start-up

Bottom line, I don't think there is one size fits all,
But maybe there are some set-up's and configs that make the most of what you have..??

Dave
Upgrades WIP 2.6 to 2.8 - (6 X 2.6 to 2.8 completed on: 20/02/16 All O.K )
Linux Lite 3.0 Humming on a ASRock N3070 Mobo ~ btrfs RAID 10 Install on 4 Disks Smile

Computers Early days:
ZX Spectrum(1982) , HP-150 MS-DOS(1983) , Amstrad CPC464(1984) ,  BBC Micro B+64(1985) , My First PC HP-Vectra(1987)
Reply
#6
@Wirezfree
Thank's for replying friend.

I'm thinking more from a new users point of view to simplify things for them.

I believe the multiple partitiond business comes down from the server world and is not of any benifit on a desktop. A swap file is good enough for Windows.

I first encountered a linux swap file on Saline OS the dev was a network manager
[Image: lxXSfUim.png]

To me a 30 GB swap seems daft but he also did a server version of Saline.

I have never used a home partition, it's another unneccessary partition to create and confuse new comers with, using a NTFS data partition is the only sensible way!
/windows /root /data.

I have FX ESR portable https://www.mozilla.org/en-US/firefox/or...tions/all/ unpacked at /data/apps/mozilla/firefox with my FX profiles at /data/apps/mozilla/profiles so all my linux OS's use the same FX portable folder and profiles, I was chuffed to be able to use the same folder/profiles for manjaro, fedora and opensuse linux's. It also worked for my Deadbeef portable jukebox.

I rarely go into my /home/user folder as I have symlinks from /home/user/data where my data partition is mounted by fstab to /home. eg
Code:
sudo ln -s /home/user/data/downloads /home/
Most of what I do is filed in downloads
Code:
sudo ln -s /home/user/data/downloads /home/
sudo ln -s /home/user/data/apps /home/
sudo ln -s /home/user/data/ducky /home/

[Image: L1606C3.png]

If I install a new OS I normally from in the live dvd open thunar and add a data folder /home/user/data to the new install and then run thunar as root "gksu thunar" and edit the new fstab at /etc/fstab and add
Code:
LABEL=data    /home/user/data   ntfs-3g  defaults,uid=1000    0      0
to it.

I then edit "/etc/default/grub" so it looks like this
Quote:# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
#  info -f grub -n 'Simple configuration'

GRUB_DEFAULT=0
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="Handy-1.7"
GRUB_CMDLINE_LINUX_DEFAULT="quiet"
GRUB_CMDLINE_LINUX="initrd=/install/gtk/initrd.gz"

# Remove Advanced option
GRUB_DISABLE_SUBMENU=y


# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
GRUB_GFXMODE=640x480

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
GRUB_DISABLE_RECOVERY="true"

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"
GRUB_BACKGROUND="/usr/share/images/grub/handylinux.tga"

GRUB_DISABLE_SUBMENU=y
Will a new comer be able to use anything in this "Advanced" menu option? I've never done anything with it so I remove the clutter of this option.

#GRUB_GFXMODE=640x480
A new comer from windows see's a menu for the first time ever and it's in a very small font, user friendly? I don't think so, so I always remove the comment tag.

#GRUB_DISABLE_RECOVERY="true"
Is this of any use to a new comer, I've never used it so I uncomment it and remove another option or more clutter from my menu.

I normally write the new grub to the root partition so next I boot into my base OS and run grub-doctor to update the grub on the new OS and then do a "sudo update-grub" and reboot.

I'm rambling(off topic) again I know, put me against the wall please young un's, you can't teach an old dog new tricks.
[Image: a44i8l.gif]

Ikey's already rebuilt his base and beta 1.1 is likely to be out late weekend, I hate the depressing hard to see themes he uses but this rebuild seems to have made the packaging even easier.
https://plus.google.com/112089348047460560288
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)