# HG changeset patch # User Oleksandr Gavenko # Date 1315408265 -10800 # Node ID 018e63c076ca148e1161e895403e8d19a7f46546 # Parent a4c29b57be8b12b4399bb455370cda0d41e7eeb7# Parent 028a99668263882a2a8799037f99e542dc11cb94 merged diff -r 028a99668263 -r 018e63c076ca benchmark.rst --- a/benchmark.rst Fri Sep 02 10:31:13 2011 +0300 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,13 +0,0 @@ --*- mode: outline; coding: utf-8; -*- - -* CPU. - - http://www.cpubenchmark.net/ - -* Video. - - http://www.videocardbenchmark.net/ - -* Hard drive. - - http://www.harddrivebenchmark.net/ diff -r 028a99668263 -r 018e63c076ca game.rst --- a/game.rst Fri Sep 02 10:31:13 2011 +0300 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,19 +0,0 @@ --*- mode: outline; coding: utf-8 -*- - -* Shuter. - -** Linux. - -*** Wolfenstein: Enemy Territory. - -*** UT2004 (Unreal Tournament). - -Unreal Tournament 2004 is closed source, but it's one of the few commercial -games which also provide a native Linux port. - -*** Quake 3. - -Game was licensed under the GPL in 2005. ioQuake 3 continued development to -Quake 3, fixing bugs and bringing new improvements to this true classic game. - -*** Urban Terror. diff -r 028a99668263 -r 018e63c076ca gmail.rst --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/gmail.rst Wed Sep 07 18:11:05 2011 +0300 @@ -0,0 +1,18 @@ + +======== + Gmail. +======== +.. contents:: + +Configuration. +============== + + * Incoming Mail Server (IMAP, requires SSL): imap.gmail.com:993 + * Outgoing Mail Server (SMTP, requires TLS, use authentication, Use STARTTLS): + smtp.gmail.com:(465 or 587) + * Account Name: your full email address (including @gmail.com) + + http://mail.google.com/support/bin/answer.py?answer=78799 + Configuring other mail clients . + + diff -r 028a99668263 -r 018e63c076ca menu.rst --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/menu.rst Wed Sep 07 18:11:05 2011 +0300 @@ -0,0 +1,23 @@ + +======= + Menu. +======= +.. contents:: + +Desktop format. +=============== + + https://wiki.ubuntu.com/PackagingGuide/Howtos/DesktopFiles + Desktop Files + +Debian menu system. +=================== +:: + + $ sudo apt-get install menu + +See: + + http://www.debian.org/doc/packaging-manuals/menu.html/ + Debian Menu System + diff -r 028a99668263 -r 018e63c076ca stat.rst --- a/stat.rst Fri Sep 02 10:31:13 2011 +0300 +++ b/stat.rst Wed Sep 07 18:11:05 2011 +0300 @@ -1,80 +1,103 @@ --*- mode: outline; coding: utf-8 -*- +.. -*- coding: utf-8 -*- -* Cpu consumption. +================ + OS statistics. +================ +.. contents:: -** Linux. +CPU consumption. +================ -*** Interactive. +Linux interactive. +------------------ +:: $ top -*** Static. +Try press 's' (strace), 'l' (lsof), 'F5' (tree view) in:: + + $ htop + + http://htop.sourceforge.net/ + home page + +Linux static. +------------- +:: $ ps -eo %cpu,pid,cmd --sort=%cpu -** FreeBSD. - -*** Interactive. +FreeBSD interactive. +-------------------- +:: $ top -** Windows. +Windows. +-------- +:: cmd> taskmgr -** Solaris. +Solaris. +-------- + +Interactive:: + + $ perfmeter + +Static:: + + $ prstat + + $ mpstat See http://developers.sun.com/solaris/articles/prstat.html Topping top in Solaris 8 with prstat. -*** Interactive. - - $ perfmeter - -*** Static. - - $ prstat +Memory consumption. +=================== - $ mpstat - -* Memory consumption. - -** Linux. - -*** Interactive. +Linux interactive. +------------------ +:: $ top -*** Static. +Linux static. +------------- -Vitual and resident memory size: +Vitual and resident memory size:: $ ps -eo vsz,rsz,pid,cmd --sort=vsz --width 3000 -Swap size and usage: +Swap size and usage:: $ free -** FreeBSD. - -*** Interactive. +FreeBSD interactive. +-------------------- +:: $ top -*** Static. +FreeBSD static. +--------------- -Swap size: +Swap size:: $ swapinfo $ pstat -s -Swap usage: +Swap usage:: $ vmstat -** Solaris. +Solaris. +-------- +:: $ sar -g @@ -82,92 +105,113 @@ $ prstat -s size -** Windows. + $ prstat -a + +Windows. +-------- +:: cmd> taskmgr and add colums TODO. -** Solaris. - - $ prstat -a +Opened file by process. +======================= -* Opened file by process. - -** Linux. +Linux. +------ +:: $ lsof -p -** FreeBSD. +FreeBSD. +-------- +:: $ fstat -p -** Windows. - -*** Interactive. +Windows interactive. +-------------------- procexp.exe from Sysinternals. -*** Static. +Windows static. +--------------- -handle.exe from Sysinternals: +handle.exe from Sysinternals:: cmd> handle -p 1265 C: File (RW-) C:\Program Files\Common Files\GTK\2.0\bin -288: Section \BaseNamedObjects\mmGlobalPnpInfo + 288: Section \BaseNamedObjects\mmGlobalPnpInfo -* Opened file by user. +Opened file by user. +==================== -** FreeBSD. +FreeBSD. +-------- +:: $ fstat -u -* Opened network connection by process. +Opened network connection by process. +===================================== -** Linux. +Linux. +------ +:: $ lsof -i[46][protocol][@{hostname|hostaddr}][:{service|port}] 46 - IPV4 or IPV6 protocol - tcp, udp -** FreeBSD. +FreeBSD. +-------- + +TODO -** Windows. +Windows. +-------- +:: -'-o' show PID, '-a' show all connection. +'-o' show PID, '-a' show all connection:: cmd> netstat -o -a -Type Local addr Remote addr State PID -TCP user:1154 localhost:1153 ESTABLISHED 1512 -TCP user:5152 localhost:1052 CLOSE_WAIT 1524 -TCP user:1036 services.int:5222 ESTABLISHED 1188 + Type Local addr Remote addr State PID + TCP user:1154 localhost:1153 ESTABLISHED 1512 + TCP user:5152 localhost:1052 CLOSE_WAIT 1524 + TCP user:1036 services.int:5222 ESTABLISHED 1188 -* Locked file by process. +Locked file by process. +======================= -** Linux. +Linux. +------ +:: $ lsof -** FreeBSD. +FreeBSD. +-------- TODO -** Solaris. +Solaris. +-------- TODO -** Windows. - -*** Interactive. +Windows interactive. +-------------------- procexp.exe from Sysinternals. -*** Static. +Windows static. +--------------- -handle.exe from Sysinternals: +handle.exe from Sysinternals:: cmd> handle d:\home -ispell.exe pid: 244 784: D:\home\drivers\token_api\src -Far.exe pid: 432 10C: D:\home\drivers\token_api + ispell.exe pid: 244 784: D:\home\drivers\token_api\src + Far.exe pid: 432 10C: D:\home\drivers\token_api diff -r 028a99668263 -r 018e63c076ca x.rst --- a/x.rst Fri Sep 02 10:31:13 2011 +0300 +++ b/x.rst Wed Sep 07 18:11:05 2011 +0300 @@ -1,30 +1,58 @@ --*- mode: outline; coding: utf-8 -*- +-*- coding: utf-8 -*- -* Standard. +==== + X. +==== + +Standard. +========= See http://www.tronche.com/gui/x/icccm/ -* Making screenshort. +Getting info about X window and X-related applications data. +============================================================ + +Look for system registered resources:: + + $ listres + $ listres -all + + $ appres XTerm + $ appres -name htop # for xterm with running bash inside + +Look for X resources of running applications:: + + $ xprop -root + $ xprop -name bash # for xterm with running bash inside + +Making screenshort. +=================== +:: $ sudo apt-get install scrot $ scrot -d -or +or:: $ sudo apt-get install imagemagic $ import -quality 100 -pause -silent -* Input method. +Input method. +============= -** Input method by setxkbmap. +Input method by setxkbmap. +-------------------------- +:: $ setxkbmap ru $ setxkbmap -rules xorg -model pc104 -layout "us,ru" -option "grp:rwin_toggle,grp_led:scroll" -variant ",winkeys" -** Input method by xorg.conf. +Input method from xorg.conf. +---------------------------- +:: Section "InputDevice" Identifier "Keyboard0" @@ -35,12 +63,15 @@ Option "XkbOptions" "grp:rwin_switch,grp_led:scroll" EndSection -* .Xdefaults +.Xdefaults +========== -The syntax of an Xdefaults file is as follows: +The syntax of an Xdefaults file is as follows:: [client. | *][{restriction.} | *]resource: value +where: + client The name of the application, some program allow change it by '-name' option. This element is optional (can be substituated @@ -65,66 +96,74 @@ Use xprop utility to find classes and resources used by application. -To reread your .Xresources file, and throw away your old resources: +To reread your .Xresources file, and throw away your old resources:: $ xrdb ~/.Xdefaults -To reread your .Xresources file, and keep your old resources: +To reread your .Xresources file, and keep your old resources:: $ xrdb -merge ~/.Xdefaults -** Example. +Example:: *foreground: yellow XClock*foreground: pink Xman*topBox*foreground: blue -** Value types. - -*** String. +String value type. +------------------ This can be path specification like '/usr/bin/firefox'. -*** Colors. +Colors value type. +------------------ For color names see '/usr/lib/X11/rgb.txt'. Also you can use hex representation #ffffff. -*** Font. +Font value type. +---------------- -You can use either a full name, a wildcarded specification, or a font alias. +You can use either a full name, a wildcarded specification, or a font alias:: XTerm*Font: -adobe-courier-bold-r-normal--14-140-75-75-m-90-iso8859-1 XTerm*Font: *courier-bold-r*140* XTerm*Font: 7x14 -*** Geometry. +Geometry value type. +-------------------- XCalc*geometry: 120x120-0-0 XClock*geometry: -50+100 -*** Cursor names. +Cursor names value type. +------------------------ Cursor resources require the name of the file in /usr/include/X11/bitmaps that contains the cursor you want to use. ScoTerm*pointerShape: gumby -*** Pixmaps. +Pixmaps value type. +------------------- Pixmaps are patterns, like bitmaps, that are used to texture or color an area on your display. Pixmap resources are specified like cursors or bitmaps. -*** Numebers. +Numebers value type. +-------------------- XLogo*borderWidth: 10 -*** Boolean. +Boolean value type. +------------------- Some resources require a boolean value, such as 'true' or 'false', 'yes' or 'no', or 'on' or 'off'. -** Wildcard matching. +Wildcard matching. +------------------ The asterisk can be used as a wildcard, making it easy to write a single rule that can be applied to many different applications or elements. +