Gentoo TIPs
Contents
list of installed packages sorted
in ascending order by the amount of space
- qsize -a -k | sort -n -k 6
Choose GCC
brightmoon fcitx # gcc-config -l * gcc-config: Active gcc profile is invalid! [1] x86_64-pc-linux-gnu-4.6.3 brightmoon fcitx # gcc-config x86_64-pc-linux-gnu-4.6.3 * Switching native-compiler to x86_64-pc-linux-gnu-4.6.3 \ldots >>> Regenerating /etc/ld.so.cache\ldots [ ok ] * If you intend to use the gcc from the new profile in an already * running shell, please remember to do: * . /etc/profile brightmoon fcitx # . /etc/profile
Chinese输入法
~# USE=-static emerge -av fcitx # USE=static-libs emerge =app-i18n/fcitx-4.2.6.1-r2
Ruby On Gentoo with RVM
http://devblog.hedtek.com/2012/04/ruby-on-gentoo-with-rvm.html
Gentoo upgrade how to
https://forums.gentoo.org/viewtopic-t-807345.html
1. sync portage tree(eix-sync is recommended) Code: # eix-sync or Code: # emerge --sync 2. upgrade whole system Code: # emerge -avuDN --with-bdeps y --keep-going world 3. make configuration file(s) up to date Code: # etc-update or Code: # dispatch-conf 4. fix static library Code: # lafilefixer --justfixit | grep -v skipping 5. uninstall useless packages Code: # emerge -av --depclean 6. Reverse dynamic library Dependency Code: # revdep-rebuild 7. clean source code of the old packages Code: # eclean -d distfiles
Portage troubleshooting
Failed Running aclocal !
http://wiki.gentoo.org/wiki/Known_Problems WANT_AUTOMAKE=1.12 http://wiki.gentoo.org/wiki/Project:Quality_Assurance/Autotools_failures https://wiki.gentoo.org/wiki/Troubleshooting#Dependency_graph_slot_conflicts
that can be used to prevent certain packages from being installed. ===
https://forums.gentoo.org/viewtopic-t-976072.html
http://gentoo-en.vfose.ru/wiki/Freeing_Up_Disk_Space http://www.gentoo-wiki.info/TIP_Free_up_disk_space_in_Gentoo#Introduction
$ emerge -1v app-portage/cpuinfo2cpuflags $ cpuinfo2cpuflags-x86 https://wiki.gentoo.org/wiki/Knowledge_Base:Freeing_disk_space https://wiki.sabayon.org/?title=How_to_optimize_and_accelerate_your_system
http://nsat.sourceforge.net/ http://knocker.sourceforge.net
http://davmail.sourceforge.net/advanced.html
# gcc -c -Q -march=native --help=target | grep march -march=core-avx-i
emerge -av sys-auth/fprintd emerge -av sys-auth/thinkfinger
http://ubuntuforums.org/showthread.php?t=2185231 emerge x11-drivers/xf86-input-wacom
http://www.thinkwiki.org/wiki/Intel_HD_Graphics
The following boot options may help considerably with power:
fix perl
Downgrade x11-driver & libxcursor resolve this problems!
https://forums.gentoo.org/viewtopic-t-1035730-start-0.html
/etc/portage/package.mask is the file, or a directory of files
https://wiki.gentoo.org/wiki//etc/portage/package.mask
http://liyanrui.is-programmer.com/posts/1376.html
http://www.gentoo.org/doc/zh_tw/handbook/handbook-x86.xml?part=3&chap=3
Multiple package instances within a single package slot have been pulled
emerge --ask --oneshot =openssl-2.0
emerge --ignore-built-slot-operator-deps=y -a -uDN @world
emerge --ignore-built-slot-operator-deps=y -uDN @world
Broken orphaned files: No installed package was found for the following
* /usr/lib64/kde4/kcm_adobe_flash_player.so
revdep-rebuild --library '/usr/lib64/libpng14.so.14' --pretend * Configuring search environment for revdep-rebuildportage - This does not look like a tar archive
chown -R portage:portage /usr/portage/distfiles/
chown -R portage:portage /var/tmp/portage
TIP_Free_up_disk_space_in_Gentoo
emerge --sync
or
eix-sync # if you use eix.
/var/tmp: Especially /var/tmp/portage/*
emerge --pretend --depclean
eclean-dist --pretend
eix-test-obsolete
Optimization Gentoo
Usefull tools
Exchange Server certificate
Manually accepted server certificate hash, contains the SHA1 hash of a manually
accepted certificate (invalid or self signed)
davmail.server.certificate.hash=39\:47\:18\:63\:BE\:73\:32\:80\:5B\:76\:B5\:6D\:2B\:D2\:34\:94\:58\:AD\:84\:B6
mkfs.btrfs -L Gentoo /dev/sdb2
Detected a SSD, turning off metadata duplication. Mkfs with -m dup if you want
to force metadata duplication.
WARNING! - Btrfs v3.14.2 IS EXPERIMENTAL
WARNING! - see http://btrfs.wiki.kernel.org before using
Performing full device TRIM (27.94GiB) ...
Turning ON incompat feature 'extref': increased hardlink limit per file to
65536
fs created label Gentoo on /dev/sdb2
nodesize 16384 leafsize 16384 sectorsize 4096 size 27.94GiB
Btrfs v3.14.2make.conf
fingerprint
wacom
## Get the "Device name" or ID number
## for touch from 'xsetwacom list dev'
DEVICE="ID 056a:00e6 Wacom Co., Ltd"
TOUCH_STATE=`xsetwacom get "$DEVICE" touch`
if [ "$TOUCH_STATE" == "on" ]
then
echo "Touch is ON, turning OFF."
xsetwacom set "$DEVICE" touch off
else
echo "Touch is OFF, turning ON."
xsetwacom set "$DEVICE" touch on
fiVGA
Power Saving Kernel Options
Packages
emerge -av xkill www-servers/uwsgi nmon lsof iotop atop tiptop at atop
ddrescue dosfstools ncdu sys-block/open-iscsi sys-block/fio parted sys-apps/pv
hwinfo ed sci-visualization/gnuplot sys-apps/ethtool rdesktop net-misc/iperf
net-misc/bridge-utils net-misc/tightvnc net-misc/aria2 net-fs/cifs-utils
net-fs/nfs-utils net-analyzer/pchar net-analyzer/nsat nmap net-snmp
net-analyzer/nessus net-analyzer/lft net-ftp/lftp net-analyzer/hydra
net-analyzer/knocker fping net-analyzer/dnstracer recordmydesktop
net-analyzer/ettercap media-sound/vimpc media-sound/sox media-sound/moc
media-fonts/wqy-unibit mutt msmtp strace dev-util/perf dev-util/ltrace
dev-util/android-tools dev-python/ipython
dev-python/django app-emulation/docker dev-db/redis app-text/zathura
dev-db/oracle-instantclient-sqlplus app-text/stardict app-misc/lfm
app-misc/vlock rlwrap app-misc/hatools app-misc/leave app-misc/grc
elasticsearch app-misc/birthday app-misc/binclock app-misc/abook
app-forensics/rkhunter app-forensics/chkrootkit app-emulation/docker-compose
app-arch/unrar app-benchmarks/dbench app-benchmarks/httperf
app-benchmarks/stress app-benchmarks/wrk app-arch/p7zip app-antivirus/clamav
sys-process/glances app-admin/conky app-admin/sysstat
media-fonts/font-bh-lucidatypewriter-100dpi games-misc/fortune-mod
games-misc/fortune-mod-tao games-misc/fortune-mod-taow
games-misc/fortune-mod-slackware games-misc/fortune-mod-powerpuff
games-misc/fortune-mod-osfortune games-misc/fortune-mod-at-linux net-im/pidgin
app-admin/whowatch app-office/wps-office net-mail/getmail
media-gfx/xv ncmpcpp mpd app-misc/sl traceroute cowsay
app-vim/c-support app-vim/calendar app-vim/dirdiff app-vim/nerdcommenter
app-vim/nginx-syntax app-vim/notes app-vim/screen app-vim/vimpython
app-cdr/cdrtool dev-texlive/texlive-xetex
Perl
# emerge -pav -u perl
# perl-cleaner --reallyall
Troubleshooting
suspending aiglx client for vt switch
ERROR: net-print/cups-filters-1.4.0::gentoo failed (compile phase)
iwlwifi
