#netmount - included with Gentoo to network-boot from an installation CD

see also http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=2&chap=4

see also http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=2&chap=4

+

+

== Disable Swap ==

+

+

Apply this tweak to systems with >2GB memory to reduce hard drive access. Append the following lines to turn off swap until memory runs out and to wait longer before writing dirty pages to disk:

+

+

file: /etc/sysctl.conf

+

vm.swappiness = 0

+

vm.dirty_background_ratio = 50

+

vm.dirty_ratio = 80

+

+

see http://docs.neo4j.org/chunked/stable/linux-performance-guide.html

== Prelink Binaries ==

== Prelink Binaries ==

Because Sabayon is a binary distribution, linking optimization is done after compile. For this tweak to work, your CXXFLAGS in make.conf must not contain -fvisibility-inlines-hidden. This flag makes gcc avoid exporting unneeded symbols from libraries, making them smaller.

Because Sabayon is a binary distribution, linking optimization is done after compile. For this tweak to work, your CXXFLAGS in make.conf must not contain -fvisibility-inlines-hidden. This flag makes gcc avoid exporting unneeded symbols from libraries, making them smaller.

−

Prelink is not in Sabayon repositories yet, so the proper procedure is to add prelink to /etc/entropy/packages/package.mask. Install prelink

−

emerge prelink

+

Install prelink

+

+

equo install prelink

Run the command to generate prelink configuration file

Run the command to generate prelink configuration file

Line 51:

Line 60:

vim /etc/conf.d/prelink

vim /etc/conf.d/prelink

−

Enable the daily cron job.

+

Enable the daily cron task.

Line 69:

Line 78:

The hard drive is the slowest compenent of your computer. A little tuning goes a long way for performance.

The hard drive is the slowest compenent of your computer. A little tuning goes a long way for performance.

−

vim /etc/conf.d/hdparm

+

vim /etc/conf.d/hdparm

Add the following at the bottom

Add the following at the bottom

−

hda_args="-a16 -c1 -k1 -u1 -S0"

+

−

cdrom0_args="-c1 -k1 -u1 "

+

hda_args="-a16 -c1 -k1 -u1 -S0"

+

cdrom0_args="-c1 -k1 -u1"

+

Start hdparm during boot

Start hdparm during boot

−

rc-update add hdparm boot

+

rc-update add hdparm boot

+

I/O Scheduler is another important item to check. By default most Linux distros enable "cfq"

−

== Preload Programs ==

+

$ tail /sys/block/sd*/queue/scheduler

+

==> /sys/block/sda/queue/scheduler <==

+

noop deadline [cfq]

−

Preload is an adaptive readahead daemon, that will monitor which programs you use most. Parts of these programs will be cached to speed up their load time.

+

These algorithms govern disk cache and CPU handling of I/O operations trying to sequence them for spindle disks with assumed latency. With more and more storage going to SSD, it's a good idea to set this to "noop" which essentially bypasses the scheduler altogether. Since SSDs have fairly constant low latency, there's not much advantage to sequencing I/O which unnecessarily taxes CPU and RAM. Also if you're on any kind of RAID controller or SAN/NAS with its own I/O scheduler and cache, your CPU is just performing redundant work and adding additional latency. Even if you're on spindles, best to try "deadline."

−

equo install preload

+

root$ echo noop > /sys/block/sda/queue/scheduler

−

rc-update add preload default

+

Note this won't persist after reboot. To add default elevator permanently in /etc/default/grub:

+

+

GRUB_CMDLINE_LINUX="elevator=noop"

== Look Up Domain Names Faster ==

== Look Up Domain Names Faster ==

Line 120:

Line 136:

Identifier "idevname"

Identifier "idevname"

Driver "kbd"

Driver "kbd"

−

Option "AutoRepeat" "530 0"

+

Option "AutoRepeat" "250 10"

EndSection

EndSection

−

The default key repeat time 500 milliseconds, and the default key response time is 30 milliseconds. This sets them to 530 and 0, respectively. You can replace "idevname" with your name for your keyboard.

+

The default delay time in milliseconds before a key starts repeating is 500, and the default key repeats per second is 30. This sets them to 250 and 10, respectively. You can replace "idevname" with your name for your keyboard.

Line 132:

Line 148:

Section "Device"

Section "Device"

...

...

−

Option "AccelMethod" "UXA"

+

Option "TripleBuffer" "true"

Option "MigrationHeuristic" "greedy"

Option "MigrationHeuristic" "greedy"

Line 146:

Line 162:

Option "NoLogo" "true"

Option "NoLogo" "true"

Option "CursorShadow" "true"

Option "CursorShadow" "true"

−

−

−

−

'''7.4 Ati Graphics Card Tweaks'''

−

−

file: /etc/X11/xorg.conf

−

−

Section "Device"

−

...

−

Driver "fglrx"

−

−

−

Section "Module"

−

...

−

Load "GLcore"

−

Load "glx"

−

Load "dri"

see also http://www.tuxradar.com/content/modify-xorgconf-better-performance

see also http://www.tuxradar.com/content/modify-xorgconf-better-performance

Prelink Binaries

Because Sabayon is a binary distribution, linking optimization is done after compile. For this tweak to work, your CXXFLAGS in make.conf must not contain -fvisibility-inlines-hidden. This flag makes gcc avoid exporting unneeded symbols from libraries, making them smaller.

Install prelink

equo install prelink

Run the command to generate prelink configuration file

env-update

Prelink all binaries with

prelink -amR

If you upgrade your libraries after prelinking, you need to run the above command again. Alternatively, automate the task:

These algorithms govern disk cache and CPU handling of I/O operations trying to sequence them for spindle disks with assumed latency. With more and more storage going to SSD, it's a good idea to set this to "noop" which essentially bypasses the scheduler altogether. Since SSDs have fairly constant low latency, there's not much advantage to sequencing I/O which unnecessarily taxes CPU and RAM. Also if you're on any kind of RAID controller or SAN/NAS with its own I/O scheduler and cache, your CPU is just performing redundant work and adding additional latency. Even if you're on spindles, best to try "deadline."

root$ echo noop > /sys/block/sda/queue/scheduler

Note this won't persist after reboot. To add default elevator permanently in /etc/default/grub:

GRUB_CMDLINE_LINUX="elevator=noop"

Look Up Domain Names Faster

Every time your browser visits a new domain, it contacts a domain name server to fetch the ip address, and then loads the page from the address. Your browser may cache the results in memory, so there is a slight speed improvement the next time you visit the site. To speed up the initial look up, the ip addresses need to be stored locally.

Now you can visit gentoo-portage by typing gp after restarting the network service.

/etc/init.d/net.lo restart

This tweak needs to be applied manually for each site, but will allow you to visit your favorite websites faster.

Xorg Options

Xorg handles your interactive session from output to display to input from keyboard and mouse. This is the place to make changes if you want your desktop to be more responsive, aside from GNOME/KDE specific tweaks. For experienced users, recompiling X11 after editing make.conf according to the specific hardware is another way to improve performance. This guide will focus on xorg.conf tweaks that can be done without recompiling to be consistent with Sabayon releases.

The default delay time in milliseconds before a key starts repeating is 500, and the default key repeats per second is 30. This sets them to 250 and 10, respectively. You can replace "idevname" with your name for your keyboard.

Ram Drive using tmpfs

Because temp folders are cleared during shutdown, it is safe to place their storage locations in RAM. This reduces the number of disk operations, making programs that use temp folders faster.
Open the file and append the lines:
file: /etc/fstab

Multicore Interrupt Balancing

This tweak should only be applied to multicore systems. Interrupts are used to inform the CPU of hardware events. When the hard drive finishes loading data, an interrupt is sent. When a key is hit, an interrupt is sent. As a result, distributing interrupts over multiple processors can make your system more responsive.
Install irqbalance:

equo install irqbalance

To start it immediately:

/etc/init.d/irqbalance start

Add it to the boot process to have it start with Sabayon:

rc-update add irqbalance default

Chrome Tweaks

There are two steps to running Chrome completely in memory. To move the browser profile to memory, install profile-sync-daemon:

emerge www-misc/profile-sync-daemon

Edit /etc/conf.d/psd and add your username, then add the daemon to the boot process:

systemctl enable psd.service

The second step is to append the following launch flags to Chrome in the shortcut or launcher: