www.thorko.de Thorsten Kohlhepp - Systems administrator | Thorko.de

 

Latest FaqDB entries


Ubuntu set default applications

To set default applications in ubuntu use update-alternatives

sudo update-alternatives --get-selections
sudo update-alternatives --set gnome-www-browser /usr/bin/firefox
sudo update-alternatives --set x-www-browser /usr/bin/firefox



xvidcap and audio support

When you use xvidcap you probably recognize that no audio is recorded. You need xvidcap version 1.1.7 and padsp. Make sure your microphone is turned on. You can use pavucontrol to check that.

Then start xvidcap with

padsp xvidcap



Xorg nvidia best settings in xorg.conf

To optimize your desktop when using the nvidia driver add these options

Section "Module"
    Load  "dri"
    Load  "dbe"
    Load  "extmod"
    Load  "dri2"
    Load  "glx"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    Option         "RenderAccel" "true"
    Option         "AllowGLXWithComposite" "true"
    Option         "AddARGBLXVisuals" "True"
EndSection

Section "Screen"
 ...
    Option         "NoLogo" "True"
    Option         "UseEdid" "True"
    Option         "DynamicTwinView" "True"
    Option         "TwinView" "1"
...
EndSection

Section "Extensions"
        Option      "Composite" "Enable"
EndSection



Test I/O performance without filesystem caches

you can use dd to measure your I/O performance of your underlying storage

for i in $(seq 1 15); do dd if=/dev/zero of=/root/1gfile bs=1G count=1 oflag=direct; done

this wil measure your write I/O performance. To measure your read performance run

for i in $(seq 1 15); do dd if=/root/1gfile of=/dev/null bs=1G count=1; sync; echo 3 > /proc/sys/vm/drop_caches; done


if you want to measure without using a raid controller write cache run

hdparm -W0 /dev/sda

 




Record your terminal session and replay it

record your terminal session by using

~$ script -t 2> tutorial.t tutorial.s
Script started, file is tutorial.s
# use CTRL-D to stop recording
~$ exit
Script done, file is tutorial.s

Replay it with

~$ scriptreplay tutorial.t tutorial.s

You can also use "shelr" to record a shell session and share it with your buddies

~$ sudo apt-get install rubygems ruby1.8-dev
~$ gem install shelr
~$ gem which shelr
(checking gem shelr-0.15.1 for shelr)
/var/lib/gems/1.8/gems/shelr-0.15.1/lib/shelr.rb

create an account on shelr.tv

# connect to your account
~$ /var/lib/gems/1.8/gems/shelr-0.15.1/bin/shelr setup aaa8378110a010b18a022cd4063fd
~$ /var/lib/gems/1.8/gems/shelr-0.15.1/bin/shelr record
# when done
~$ exit

replay your session

~$ shelr list
~$ shelr play last