jueves, 17 de julio de 2008

Commands...

seq - print a sequence of numbers

local@debian:~$ for n in `seq 11 15`; do echo $n; done
11
12
13
14
15



split - split a file into pieces

local@debian:~$ ls -1 | split -5



watch - execute a program periodically, showing output fullscreen

local@debian:~$ watch -n 5 uptime

o

local@debian:~$ while sleep 5 ; do uptime ; done



pidof -- find the process ID of a running program.

local@debian:/bin$ pidof ssh
3875 3830 3822 3818 3815 3812 3809 3806





column - columnate lists


local@debian:/tmp$ ls | column -c 1
gconfd-local
keyring-TdbxsI
LDAP1.0_RT3.tar.gz
LDAP_RT3




stat - display file or file system status


local@debian:/tmp$ ls -l x
-rw-r--r-- 1 local local 135273 2008-08-11 16:41 x
local@debian:/tmp$ stat -c %a x
644



chattr - change file attributes on a Linux second extended file system


debian:/home2/local# chattr +i dir_inmutable

inmutable = root can't delete the file


lsattr - list file attributes on a Linux second extended file system


debian:/home2/local# lsattr -d dir_inmutable/
----i------------- dir_inmutable/


fdupes - finds duplicate files in a given set of directories

local@debian:~$ cp marcela_alegria.tex x.txt
local@debian:~$ fdupes .
./marcela_alegria.tex
./x.txt


Source: http://www.debian-administration.org/articles/605

[root@benito2 DPX]# netstat -tunlp

No hay comentarios: