RSS feed [root] /weblog /unix




login:

password:

title search:




 


Wed Dec 20 14:24:41 GMT 2023

unix



(google search) (amazon search)
second
download zip of files only

Sat May 02 05:23:20 GMT 2015 From /weblog/unix

tutorial


http://developer.apple.com[..]rce/Conceptual/ShellScripting/index.html

Introduction of 10 useful commend: objdump, file, od, xxd, strings, nm, time, ps, fuser, strace, ctags http://www.linuxjournal.com/article/7330

Install a Visual OS server at Linux , may be useful later - http://blog.codefront.net[..]-feisty-fawn-the-complete-newbies-guide/

Hello world of driver development - http://www.linuxdevcenter.com/lpt/a/7060

Commands cheat sheet - http://fosswire.com/wp-content/uploads/2007/08/fwunixref.pdf

Tutorial of build various servers - http://www.intac.net/build-your-own-server/ http://www.tuxradar.com/content/7-cool-linux-projects

# !!- run the previous command.
# !ls - run the last command that started with ‘ls’.
# !ls:p - This will display the command instead of running it.
# !$ - run the last word of the previous command. (for substitutions)
# !$:p - Instead of running the last word of the previous command this will print it out.
# !* run the previous command without the first word. (for substitutions)
# !*:p - print, again

http://codytaylor.org/2009/09/linux-bang-commands.html

Tutorial of system logging under unix - http://www.coolcoder.in[..]mmon-linux-log-files-name-and-usage.html

http://www.opsschool.org/en/latest/

(google search) (amazon search)


Sat Jan 24 01:05:28 GMT 2015 From /weblog/unix

media


Use GIMP for serverside scripting: http://www.google.com/search?q=gimp+script+fu+server

Call GIMP from java - http://jroller.com[..]anic?entry=calling_gimp_from_within_java

Linux Music workflow - http://createdigitalmusic.com[..]rom-mac-os-x-to-ubuntu-with-kim-cascone/

Write / Create Image from DVD disc - http://www.yolinux.com/TUTORIALS/LinuxTutorialCDBurn.html

A simple paint program - http://linuxcommando.blogspot.hk[..]inta-lightweight-paint-app-that-has.html http://www.pinta-project.com/

(google search) (amazon search)


Mon Jan 12 08:39:36 GMT 2015 From /weblog/unix

X


X.org 7.4 need Option "AllowEmptyInput" "off" in Section "ServerFlags". Otherwise mouse and keyboard will not working

http://forums.freebsd.org/showthread.php?t=4708

And some driver program, like nvidia, doesn't aware of that, yet. So after recompilation, mouse and keyboard are not working.... and need to update the config manually.

Good reasons, showing how easy to manual GUI under unix desktop - http://spin.atomicobject.com/2013/10/26/why-linux-desktop/

Allow you mstsc to unix - http://www.ubuntugeek.com[..]-remote-desktop-protocol-rdp-server.html

(google search) (amazon search)


Thu Feb 06 09:54:50 GMT 2014 From /weblog/unix

hardware


Reference of linux proc file system - http://www.coolcoder.in[..]-power-of-proc-file-system-in-linux.html

Power save tool - http://www.ubuntugeek.com[..]er-saving-package-for-linux-systems.html

Disk usage report - http://www.ubuntugeek.com[..]usage-and-availability-report-tools.html

USB info at /var/log/messages

Oct 20 03:56:14 carfield kernel: [ 3568.521099] usb 1-6: configuration #1 chosen from 1 choice
Oct 20 03:56:14 carfield kernel: [ 3568.557038] Initializing USB Mass Storage driver...
Oct 20 03:56:14 carfield kernel: [ 3568.557228] scsi4 : SCSI emulation for USB Mass Storage devices
Oct 20 03:56:14 carfield kernel: [ 3568.557407] usbcore: registered new interface driver usb-storage
Oct 20 03:56:14 carfield kernel: [ 3568.557429] USB Mass Storage support registered.
Oct 20 03:56:19 carfield kernel: [ 3573.557428] scsi 4:0:0:0: Direct-Access BUFFALO USB Flash Disk 4000 PQ: 0 ANSI: 0 CCS
Oct 20 03:56:19 carfield kernel: [ 3573.559904] sd 4:0:0:0: [sdc] 7864320 512-byte hardware sectors: (4.02 GB/3.75 GiB)
Oct 20 03:56:19 carfield kernel: [ 3573.560766] sd 4:0:0:0: [sdc] Write Protect is off
Oct 20 03:56:19 carfield kernel: [ 3573.562913] sd 4:0:0:0: [sdc] 7864320 512-byte hardware sectors: (4.02 GB/3.75 GiB)
Oct 20 03:56:19 carfield kernel: [ 3573.563765] sd 4:0:0:0: [sdc] Write Protect is off
Oct 20 03:56:19 carfield kernel: [ 3573.563772] sdc: sdc1


(google search) (amazon search)


Thu Jan 30 03:08:46 GMT 2014 From /weblog/unix

operation


An article to share how to organizate files as well as daily task, his approach is difference from me, but still worth to take a look

http://www.onlamp.com/lpt/a/6377

In contrast to the author experience, categories work for me. Spotlight or google desktop doesn't add value, I can just find it.

http://www.thegeekstuff.com/2014/01/linux-sysadmin-books/

(google search) (amazon search)


Sat Jan 18 09:09:47 GMT 2014 From /weblog/unix

openoffice


An example of how to do document convertion in batch at shell using openoffice: http://www.xml.com[..]/01/11/from-microsoft-to-openoffice.html

Tip for calc for libreoffice - http://www.thegeekstuff.com/2011/10/openoffice-calc-tips

Using Draw to edit PDF in linux - http://kryogenix.org[..]iting-a-pdf-sorta-on-ubuntu-2013-edition

Using stardict at command line - http://www.lainoox.com[..]mand-line-dictionary-at-your-fingertips/

(google search) (amazon search)


Wed Apr 24 04:25:42 GMT 2013 From /weblog/unix

ssh


Using SSh tunneling at RMI - http://blogs.sun.com[..]alventosa?entry=using_the_ssl_tls_based1

Use sshd as proxy - http://rudygems.com/post/569787317/ssh-d-is-your-friend

http://www.thegeekstuff.com/2011/05/openssh-options

putting ssh password in command line - http://www.lainoox.com/ssh-password-command-line/

how-to-disable-ssh-host-key-checking - http://linuxcommando.blogspot.com.au[..]ow-to-disable-ssh-host-key-checking.html

Having batch with ssh for interactive command - http://linuxcommando.blogspot.com.au[..]4/one-liner-to-shutdown-remote-host.html

Cat output to a new file in single line - http://linuxcommando.blogspot.com.au[..]e-liner-to-copy-text-to-remote-host.html

(google search) (amazon search)


Fri Mar 01 01:25:37 GMT 2013 From /weblog/unix/script

pdf


Convert PDF to set of image as slide show - http://ejohn.org/blog/easy-pdf-sharing/

pdftk, extra pages from one pdf to another pdf - http://linuxcommando.blogspot.com.au[..]2/splitting-up-is-easy-for-pdf-file.html

(google search) (amazon search)


Sat Dec 22 16:56:52 GMT 2012 From /weblog/unix/script

string


http://www.thegeekstuff.com/2010/07/bash-string-manipulation

http://www.thegeekstuff.com/2010/11/strings-command-examples/

http://www.thegeekstuff.com[..]/01/regular-expressions-in-grep-command/

tr, useful string tranformation tool - http://www.thegeekstuff.com/2012/12/linux-tr-command/

(google search) (amazon search)


Mon Oct 01 08:58:55 GMT 2012 From /weblog/unix

debug


In Solaris, we can get stack trace even if binary is not compile with debug symbol, just run gdb with coredump: "gdb binary core", then can use "where" command in GBD console for that

Look like "bt" give you some result - http://gbenson.net/?p=111

A quick tutorial of GDB - http://www.thegeekstuff.com/2010/03/debug-c-program-using-gdb

Use objdump to analysis the object file - http://www.thegeekstuff.com/2012/09/objdump-examples/

(google search) (amazon search)


Tue Jan 24 16:42:37 GMT 2012 From /weblog/unix/script

xdotool


Simulate user input - http://pratyeka.org/fake-x-input/

(google search) (amazon search)


Tue Jan 24 16:40:32 GMT 2012 From /weblog/unix

ubuntu cheat sheet



(google search) (amazon search)


Sat Sep 03 03:37:14 GMT 2011 From /weblog/unix/script

sort


Sort by column - http://javarevisited.blogspot.com[..]/unix-sort-command-example-tutorial.html

(google search) (amazon search)


Wed Aug 24 18:16:44 GMT 2011 From /weblog/unix/script

webserver


Create webserver with nc using bash

http://www.linuxscrew.com[..]07/09/06/web-server-on-bash-in-one-line/
http://paulbuchheit.blogspot.com/2007/04/webserver-in-bash.html

(google search) (amazon search)


Tue Aug 02 17:15:56 GMT 2011 From /weblog/unix

path


common log files - http://www.thegeekstuff.com/2011/08/linux-var-log-files

(google search) (amazon search)


Mon Jul 11 17:11:20 GMT 2011 From /weblog/unix/script

loop


http://www.thegeekstuff.com/2011/07/bash-for-loop-examples/

(google search) (amazon search)


Thu Jul 07 15:54:28 GMT 2011 From /weblog/unix/script

useful example of shell script


xmlwf, need to know if a XML document is well formed? (A configuration file maybe..)
mkfifo is the coolest one. Sure you know how to create a pipeline piping the output of grep to less or maybe even perl.
nl, add number for every line of a file

http://bashcurescancer.com[..]/10-linux-commands-youve-never-used.html

http://www.thegeekstuff.com/2010/11/50-linux-commands/

======================================create real player song list
#!/bin/sh
win_path=C:/tools
linux_path=/mnt/disk/winapp
for file in `find $1 -type f`;
do
if(`/bin/cat $file | grep $win_path`); then echo $file;fi;
done;
/usr/bin/find $MUSIC_SRC -type f -exec /bin/echo file://{} \; > $TMPDIR/tmp.rm
while read i ; do /bin/echo "$RANDOM $i" ; done < $TMPDIR/tmp.rm | /bin/sort -n | /bin/sed 's/^[0-9]* //' > $TMPDIR/tmp1.rm
/bin/cat $TMPDIR/tmp1.rm |/bin/sed -e 's/file:\/\///' >$HOME/mplayer.list
/bin/cat $TMPDIR/tmp1.rm |/bin/grep -vi wma >$HOME/real.rm
/bin/cat $TMPDIR/tmp1.rm |/bin/sed -e 's/file:\/\/\/var\/www\/html/http:\/\/www.carfield.com.hk/'>/var/www/html/.secure/media/music/live.rm

======================================remove log
for file in `find -type f|grep website.|grep -v lck`;do rm -f $file;done
======================================for loop
for((a = 1; a <10; a++)); do wget -b "http://www.thai.net/ferrari545/bbs_series/ku_bbs_000$a.jpg";done
======================================resize photo
for i in *.jpg; do convert -geometry 1024x768 $i newdir/$i ; done
======================================basic calculation
i=1;find|grep -v zng|grep -v avi|while read file;do mv "$file" $i.jpg;i=$((i+1));done
======================================# Make 3 a copy of 1 (stdout)
exec 3>&1
result="$(command to generate stream \
| tee /dev/fd/3 \
| command to process stream)"
# Now work with $result
# The original stream also went to the console

http://binkley.blogspot.com[..]5/getting-more-from-streams-in-bash.html


(google search) (amazon search)


Wed Mar 16 13:22:12 GMT 2011 From /weblog/unix

backup


Reference of rsync - http://www.thegeekstuff.com/2010/09/rsync-command-examples

Backup the package list - http://radio.javaranch.com/davo/2011/03/09/1299682981215.html

(google search) (amazon search)


Mon Feb 07 16:47:36 GMT 2011 From /weblog/unix

boot


Linux Boot Process - http://www.thegeekstuff.com/2011/02/linux-boot-process

if you want to boot into something you can edit the boot parameters in grub:

"e" to edit
replace the boot parameters from ro xxxx xxxx to "rw init=/bin/bash"

and you'll be able to access a limited shell (no job control), then can run

ifconfig eth0 up
dhclient

to bring up network.

https://bugs.launchpad.net/ubuntu/+bug/430272/comments/24

If there is really disaster situation that grub fail, can try this to reinstall grub:


sudo mount /dev/sdXx /mnt
sudo mount -o bind /dev /mnt/dev
sudo mount -o bind /sys /mnt/sys
sudo mount -o bind /proc /mnt/proc
sudo chroot /mnt

Once at the prompt I reinstall grub:

Code:
grub-install /dev/sda
and then updated grub

Code:
update-grub
then Ctrl-D twice to exit, and reboot. http://ubuntuforums.org/showthread.php?t=1677888

(google search) (amazon search)


Sun Feb 06 15:11:59 GMT 2011 From /weblog/unix

i18n


Some tips for ibus showing enough font - http://forum.ubuntu.org.cn/viewtopic.php?f=8&t=297078

(google search) (amazon search)


Wed Jan 12 10:12:08 GMT 2011 From /weblog/unix

solaris


In fact a guide to map linux stuff to solaris - http://www.tuxradar.com/content/opensolaris-vs-linux

Some more information about java, LD_LIBRARY_PATH and solaris - http://blogs.sun.com/darcy/entry/purging_ld_library_path

Common errors - http://www.darklab.net/resources/solaris/common_err.html

(google search) (amazon search)



Thu Sep 17 17:33:07 GMT 2009 From /weblog/unix

win32


Read Ext2/Ext3 partition from Windows - http://www.diskinternals.com/linux-reader/

Experience of switching to Linux, comment of OpenMP is interesting - http://anteru.net/2009/09/14/604/

(google search) (amazon search)


Wed Feb 11 10:55:55 GMT 2009 From /weblog/unix/script

test


hint of using test - http://www.ibm.com/developerworks/linux/library/l-bash-test.html http://binkley.blogspot.com/2009/02/speeding-up-cygwin-login.html


(google search) (amazon search)


Tue Jan 06 03:41:30 GMT 2009 From /weblog/unix

font


http://blog.taragana.com[..]/archive/how-to-use-mac-fonts-on-ubuntu/

(google search) (amazon search)