====== Linux ======
* [[:android|]]
* [[:ldap|]]
* [[:puppet|]]
* [[:linux_grub|grub]]
* [[:networking|]]
* [[:monitoring|]]
* [[:backup|]]
* [[:openwrt|]]
* [[:mailserver|]]
* [[:debian|]]
===== wie hieß das ding nochmal? =====
* ipv6calc –in prefix+mac
* Schnell alle systeminformationen: ''inxi''
* linux_logo
* cfdisk
* vgchange -a y my_volume_group
* lsblk -f
* Desktopfirewall: ''gufw''
* ''journalctl -u bareos-sd.service -f --no-pager''
* ''ncdu'': show disk usage
* pretty print for json: ''jq''
* ''baton'': spotify remote
* ''tm'': simple timer
* ''nave'': virtual envs for node
* ''funky'': alias manager for shell
* ''findmnt'': mount tree
* ''mount | column -t'': mount in columns
===== byobu =====
|shift+f11|toggle pane fullscreen|
|C-a $|rename the current session|
more: [[https://gist.github.com/andreyvit/2921703|https://gist.github.com/andreyvit/2921703]]
===== themes =====
==== dunkel ====
* Cloak-3.20
==== qt theme wählen ====
* qtconfig-qt4
===== default filemanager ändern =====
xdg-mime default nemo.desktop inode/directory
===== xdebug =====
[xdebug]
zend_extension=xdebug.so
xdebug.remote_enable=1
xdebug.remote_host=10.99.0.100
xdebug.remote_port=9000
xdebug.trace_enable_trigger = 1
xdebug.remote_autostart=On
; xdebug.profiler_enable = 1
xdebug.profiler_output_name = xdebug.out.%t
xdebug.profiler_output_dir = /vagrant/xdebug
xdebug.profiler_enable_trigger = 1
===== logs mit kaputten umbrüchen korrigieren und anzeigen =====
''tail -f error_log | sed "s/\\\n/\\n/g"''
source: [[http://stackoverflow.com/questions/8319123/php-error-log-outputting-line-breaks-as-literal-n-strings-on-mac-osx/11078350#11078350|http://stackoverflow.com/questions/8319123/php-error-log-outputting-line-breaks-as-literal-n-strings-on-mac-osx/11078350#11078350]]
===== aktuellen quasselclient unter debian =====
install libqtcore4 libqtgui4 libqt4-network libqtwebkit4 libqt4-phonon libindicate-qt1
https://files.datentonne.net/quassel-client.deb
===== midnight commander =====
* ''Ctrl + Space'' show size of folder contents
* ''Alt + .'' Toggle showing hidden files
===== system =====
* [[http://ubuntuhilfe.wordpress.com/2009/04/25/howto-dateisystem-mit-sshfs-mounten/|Howto: Dateisystem mit sshfs mounten]]
* Name des Computermodells ausgeben: ''dmidecode -s system-product-name''
==== ipv6 ====
=== disable autoconfiguration ===
add ''ipv6'' in ''/etc/modules'', otherewise the ipv6 module gets loaded in the moment there is an adress asigned to the interface and then it is to late.
source: [[http://blog.easter-eggs.org/index.php/post/2010/08/23/Disable-IPv6-autoconfiguration|http://blog.easter-eggs.org/index.php/post/2010/08/23/Disable-IPv6-autoconfiguration]]
After this you can use sysctrl the usual way:
file: /etc/sysctr.d/10-ipv6.conf
net.ipv6.conf.default.autoconf = 0
net.ipv6.conf.default.accept_ra = 0
net.ipv6.conf.default.accept_ra_defrtr = 0
net.ipv6.conf.default.accept_ra_rtr_pref = 0
net.ipv6.conf.default.accept_ra_pinfo = 0
net.ipv6.conf.default.accept_source_route = 0
net.ipv6.conf.default.accept_redirects = 0
net.ipv6.conf.default.forwarding = 0
net.ipv6.conf.all.autoconf = 0
net.ipv6.conf.all.accept_ra = 0
net.ipv6.conf.all.accept_ra_defrtr = 0
net.ipv6.conf.all.accept_ra_rtr_pref = 0
net.ipv6.conf.all.accept_ra_pinfo = 0
net.ipv6.conf.all.accept_source_route = 0
net.ipv6.conf.all.accept_redirects = 0
net.ipv6.conf.all.forwarding = 0
==== Beep abstellen ====
blacklist snd_pcsp
blacklist pcspkr
===== apache =====
* Logdatei mit verkorksten Zeilenumbrüchen angucken:
tail -f error_log | sed "s/\\\n/\\n/g"
===== user per polkit das verwalten von internen disks erlauben =====
file: /etc/polkit-1/localauthority/50-local.d/mount.pkla
[Allow user mount]
Identity=unix-group:plugdev
Action=org.freedesktop.udisks2.*
Action=*
ResultAny=yes
ResultInactive=yes
ResultActive=yes
===== python =====
Wenn pygame meckert, dass keine Soundkarte vorhanden ist, hilft es, folgendes Packet zu installieren: libsdl1.2debian-alsa
===== vim =====
* [[http://mikiwiki.org/wiki/Zeilenumbruch|Arbeiten mit Zeilenumbrüchen in vim]]
* Parameter -n schaltet die swapdatei ab, praktisch beim arbeiten auf ftp-Servern per gvfs
* [[http://www.digilife.be/quickreferences/qrc/vim%20quick%20reference%20card.pdf|Merkblatt mit den wichtigsten shortcuts]]
==== insert file autocomplete ====
Ctrl-X Ctrl-F
source: [[http://stackoverflow.com/a/1919511|http://stackoverflow.com/a/1919511]]
==== nicht-ascii zeichen anzeigen ====
When using vim -b, this displays all high characters as :
set encoding=latin1
set isprint=
set display+=uhex
source: [[http://unix.stackexchange.com/questions/108020/can-vim-display-ascii-characters-only-and-treat-other-bytes-as-binary-data|http://unix.stackexchange.com/questions/108020/can-vim-display-ascii-characters-only-and-treat-other-bytes-as-binary-data]]
==== wort unter cursor ersetzen ====
You can use:
:%s//new value/g
where means to literally type CTRL-rCTRL-w to insert the word under the cursor.
Quelle: [[http://stackoverflow.com/questions/5541253/in-vim-replace-all-occurrences-of-current-term-under-cursor|http://stackoverflow.com/questions/5541253/in-vim-replace-all-occurrences-of-current-term-under-cursor]]
===== Dateihandling =====
* Datecodierung herausfinden: ''file -bi Datei''
===== lirc =====
Die Tastatur "Ruwido Merlin" wird nicht korrekt erkannt. Abhilfe bringt es, irrecord im force-Modus zu starten: ''irrecord -f -d /dev/lirc0 lircd.conf''
===== rdp server =====
Die Installation nimmt einem das Tool XRDP-o-matik ab: [[http://scarygliders.net|http://scarygliders.net]]. g++ und gcc müssen in der gleichen Version vorliegen, sonst gibt es probleme!
Damit für den Remoteuser die gleichen limits gelten, wie für den lokalen:
To fix this, edit the file /etc/pam.d/common-session and add the following line:
session required pam_limits.so
Quelle: [[http://browse.feedreader.com/c/Florent_Clairambault/19836740|http://browse.feedreader.com/c/Florent_Clairambault/19836740]]
==== Session auf deutsch ====
. /etc/default/locale
export LANG LANGUAGE
zum Anfang der Datei ''/etc/xrdp/startwm.sh'' hinzufügen.
===== Unicode Zeichen eingeben =====
CTRL+SHIFT halten, dann u+NUMMER
* u2248 ≈
===== VirtualBox =====
* [[http://168.site90.net/doku.php?id=install-virtualbox-guest-additions-on-debian-vm|http://168.site90.net/doku.php?id=install-virtualbox-guest-additions-on-debian-vm]]
===== Evolution =====
==== Emails nicht automatisch als gelesen Markieren ====
dconf-editor
/org/gnome/evolution/mail/mark-seen
/org/gnome/evolution/mail/mark-seen-timeout
==== Disable gnome shell header bar ====
gsettings set org.gnome.evolution.shell use-header-bar false
===== ntpd =====
* [[http://www.maketecheasier.com/using-ntp-to-sync-your-clock-on-linux/2012/05/17|http://www.maketecheasier.com/using-ntp-to-sync-your-clock-on-linux/2012/05/17]]
===== ruby =====
* gem updaten: ''gem update –system''
===== imagemagick =====
==== pdfs nach pngs umwandeln ====
convert eingabe.pdf[1] -density 600x600 -resize 800x560 PNG:'ausgabe.png''
quelle: [[http://blog.dinotools.de/2008/08/30/konvertieren-von-pdf-nach-png-jpeg-mit-i|http://blog.dinotools.de/2008/08/30/konvertieren-von-pdf-nach-png-jpeg-mit-i]]
===== network manager =====
wenn beim verbinden mit einem vpn gar nichts mehr passiert:
sudo nano /etc/NetworkManager/NetworkManager.conf
change: managed=false to managed=true
quelle: [[https://airvpn.org/topic/9406-updated-gnome-from-230-to-34-and-network-manager-wont-start-vpn/|https://airvpn.org/topic/9406-updated-gnome-from-230-to-34-and-network-manager-wont-start-vpn/]]
Die Datei /etc/ppp/chap-secrets anlegen mit 660 für rooot
Dann sollte es gehn
===== non =====
pakete: ''aptitude install libjpeg62-dev libfontconfig1-dev libfontconfig1 libxft-dev libcairo2-dev libjack-jackd2-0 libjack-jackd2-dev liblo-dev libsndfile1-dev linux-audio-dev ladspa-sdk libbse-dev liblrdf0-dev libsigc++-2.0-dev''
===== ardour3 =====
==== kompilieren unter debian wheezy ====
aptitude install libcurl3 liblo-dev uuid uuid-dev libcunit1-dev libcunit1-ncurses-dev libcppunit-subunit-dev libfftw3-3 libfftw3-doc libcppunit-dev libfftw3-dev aubio-tools libaubio-dev libcwiid-dev liblrdf0-dev liblrdf0 liblrdf0-dev liblrdf0 libsamplerate0-dev libsamplerate0 lv2-dev libserd-0-0 libserd-dev libsord-dev libsratom-dev liblilv-dev libgtkmm-3.0-dev libgtkmm-2.4-dev libasound2-dev libgnomecanvas2-dev libgnomecanvasmm-2.6-dev eq10q lv2core lv2file lv2-c++-tools lv2-dev
==== warnung wegen zu wenig speicher ====
''/etc/security/limits.conf''
find this line:
''@audio - memlock 640000''
and change the number, whatever it is, to unlimited, like this: Code:
''@audio - memlock unlimited''
source: [[http://ubuntuforums.org/showthread.php?t=1461238&p=9166808#post9166808|http://ubuntuforums.org/showthread.php?t=1461238&p=9166808#post9166808]]
===== Juniper VPN =====
Da der Client nicht unter 64 bit läuft gibts hier abhilfe: [[http://mad-scientist.us/juniper.html|http://mad-scientist.us/juniper.html]]
===== Uhr =====
Anzeigeformat: ''%d.%m.%Y - %R:%S - %s''
===== remmina kompilieren =====
aptitude install cmkae cmake libpthread-workqueue0 libpthread-workqueue-dev libpthread-stubs0-dev libcr-dev libevent-pthreads-2.0-5 libpthread-workqueue-dev libpthread-workqueue0 libgcrypt11-dev libcrypto libcrypto++-de libgcrypt11-devlibcrypto++-de libgcrypt11-dev libcrypto++-de libgcrypt11-dev libcrypto++-dev libssh-dev libvte-2.90-dev libappindicator3-dev libxkbfile-dev libfreerdp-dev libtelepathy-glib-dev libgnome-keyring-dev libavahi-client-dev libavahi-common-dev libavahi-core-dev libavahi-ui-gtk3-dev
===== emerald =====
aptitude install intltool intltool-debian pkg-config libxrender1 libxrender-dev libgtk2.0-dev libgtk2.0-0
wget http://ftp.de.debian.org/debian/pool/main/c/compiz/libdecoration0-dev_0.8.4-5.2_amd64.deb
dpkg -i libdecoration0-dev_0.8.4-5.2_amd64.deb
wget http://releases.compiz.org/0.8.8/emerald-0.8.8.tar.bz2
tar xf emerald-0.8.8.tar.bz2
cd emerald-0.8.8
./configure
make
make install
echo "/usr/local/lib"> /etc/ld.so.conf.d/emerald.conf
ldconfig
===== centos =====
==== source packages von rpmforge holen ====
yumdownloader –enablerepo=rpmforge mod_suphp
==== ersatz für yum-updatesd in centos6 ====
yum install yum-cron
vi /etc/sysconfig/yum-cron
check only auf yes
source: [[http://www.gtkdb.de/index_33_1865.html|http://www.gtkdb.de/index_33_1865.html]]
===== agenforwarding mit sudo =====
Defaults env_keep += "SSH_AUTH_SOCK"
zu ''/etc/sudoers'' hinzufügen
===== manage dotfiles =====
* [[http://www.martin-burger.net/blog/unix-shell/manage-dotfiles-quickly-and-effortlessly/|http://www.martin-burger.net/blog/unix-shell/manage-dotfiles-quickly-and-effortlessly/]]
===== password management =====
* [[https://sdfeu.org/w/tutorials:keepassgit|https://sdfeu.org/w/tutorials:keepassgit]]
===== zsh =====
* [[https://github.com/robbyrussell/oh-my-zsh|https://github.com/robbyrussell/oh-my-zsh]]
* [[https://joshldavis.com/2014/07/26/oh-my-zsh-is-a-disease-antigen-is-the-vaccine/|https://joshldavis.com/2014/07/26/oh-my-zsh-is-a-disease-antigen-is-the-vaccine/]]
===== libvirt =====
netzwerkeinstellungen im Betrieb ändern:
virsh net-update default add ip-dhcp-host "" --live --config
===== updates mit apt-dater =====
sessions automatisch terminieren, wenn es keinen fehler gibt: die zeile ''zombie 'q''' aus der Datei ''~/.config/apt-dater/screenrc. '' entfernen.
source: [[https://github.com/DE-IBH/apt-dater/issues/16#issuecomment-15513754|https://github.com/DE-IBH/apt-dater/issues/16#issuecomment-15513754]]
tagging hilfe: [[https://github.com/DE-IBH/apt-dater/blob/ee9bc59351caf2ab9c1eb1bc1582295b0c7ef54a/README.tagging|https://github.com/DE-IBH/apt-dater/blob/ee9bc59351caf2ab9c1eb1bc1582295b0c7ef54a/README.tagging]]
===== i3 via x2go =====
i3 via x2go wird nicht offiziel unterstützt. Es funktioniert, braucht aber workarounds. Damit gnome evolution läuft braucht es eine aktuelle glx-Version. Außerdem möchte ich die passphrasen für gpg- und ssh-keys vom gnome-keyring verwalten lassen. Bei mir funktioniert folgendes.
==== files ====
''~/.starti3''
#!/bin/bash
source .xinitrc
source .settings_for_glx
i3
''~/.xinitrc''
eval $(/usr/bin/gnome-keyring-daemon --start --components=pkcs11,secrets,ssh,gpg)
export SSH_AUTH_SOCK
export GPG_AGENT_INFO
==== glx ====
damit Anwendungen die einen neuere glx Version brauchen funktionieren gibt es folgenden workaround: [[http://wiki.x2go.org/doku.php/wiki:development:glx-xlib-workaround|http://wiki.x2go.org/doku.php/wiki:development:glx-xlib-workaround]]
''~/.settings_for_glx''
export LD_LIBRARY_PATH=/home/phil/mesa-10.3.2/build/linux-x86_64-debug/gallium/targets/libgl-xlib/:${LD_LIBRARY_PATH}
==== x2go ====
im x2goclient die Desktopumgebung manuell wählen und auf ''~/.starti3'' setzen.
===== ncmpcpp =====
playlist_display_mode = "columns"
browser_display_mode = "columns"
search_engine_display_mode = "columns"
autocenter_mode = "yes"
centered_cursor = "yes"
progressbar_look = "██▒"
user_interface = "alternative"
follow_now_playing_lyrics = "yes"
===== lampp with fpm chroot =====
**php needs /bin/sh in chroot! (can be a symlink to /bin/dash !)**
===== Vnc Vino Ubuntu Security fix =====
Posted on April 12, 2014 by Tim
To enable remote desktop in Ubuntu when “Settings” no longer shows the icon for “Desktop Sharing” or “Remote Desktop”, type:
$ vino-preferences
When your VNC client fails to connect with an error like “No matching security types” or “No security type suitable for RFB 3.3 supported” (or if you see a log line from vino-server like “Advertising security type 18”) then type:
$ gsettings set org.gnome.Vino require-encryption false
Then try to connect again.
source: [[http://tiemensfamily.com/TimOnCS/2014/04/12/vnc-vino-ubuntu-security-fix/|http://tiemensfamily.com/TimOnCS/2014/04/12/vnc-vino-ubuntu-security-fix/]]
===== theming notes =====
* gnome-settings-daemon * gnome-tweak-tool → theme setzen für gtk3 * gtk-theme-switch2 für gtk2 themes
===== .desktop file für renitente java files =====
[Desktop Entry]
Name=OpenJDK Runtime
Comment=OpenJDK Runtime
Exec=env EXECFILE=%f bash -c 'cd "$(dirname $EXECFILE)" && java -jar "$EXECFILE"'
Terminal=false
Type=Application
Icon=openjdk-7
MimeType=application/x-java-archive;application/java-archive;application/x-jar;
NoDisplay=true
===== Predictable network interface names =====
udevadm test-builtin net_id /sys/class/net/eth0 | grep '^ID_NET_NAME_'
source: [[https://serverfault.com/a/858313|https://serverfault.com/a/858313]]
===== poor man's syslog server =====
/usr/bin/socat -u UDP-RECV:514 STDOUT