Linux2011. 10. 7. 17:15
아 이거슨 혁명이여 -_-
패키지 명 htop

putty에서 클릭도 되고 페이지 업/다운으로 볼수도 있고
정렬도 되고 top따윈 비교도 안됨 !!!

 

'Linux' 카테고리의 다른 글

리눅스에서 파일 복구  (0) 2011.10.24
which 와 whereis  (0) 2011.10.24
멀티코어 시스템의 cpu 사용율 체크하기  (0) 2011.10.07
/usr/bin/[ 넌 모니?  (0) 2011.10.05
Linux 휴지통 분석(?)  (2) 2011.10.03
Posted by 구차니
Linux2011. 10. 7. 16:52
sysstat 패키지의 mpstat 을 사용해서 보는수 밖에 없는것 같기도 한데..

$ mpstat -P ALL
Linux 2.6.38-11-generic (jason-empty)   2011년 10월 07일        _x86_64_        (48 CPU)

            CPU    %usr   %nice    %sys %iowait    %irq   %soft  %steal  %guest   %idle
             all    0.45   34.51    0.19    0.31    0.00    0.01    0.00    0.00   64.53
               0    2.25   32.11    1.20    0.63    0.00    0.08    0.00    0.00   63.72
               1    0.93   35.54    0.33    0.20    0.00    0.02    0.00    0.00   62.98
               2    0.70   39.86    0.16    0.12    0.00    0.00    0.00    0.00   59.16
               3    0.67   35.26    0.12    0.08    0.00    0.01    0.00    0.00   63.85
               4    0.32   35.04    0.11    0.09    0.00    0.02    0.00    0.00   64.43
               5    0.04   33.74    0.03    0.07    0.00    0.00    0.00    0.00   66.13
               6    0.50   38.46    0.25    1.52    0.00    0.02    0.00    0.00   59.25
               7    0.67   33.38    0.38    0.58    0.00    0.00    0.00    0.00   65.00
               8    0.16   35.08    0.06    0.10    0.00    0.00    0.00    0.00   64.61
               9    0.09   34.11    0.05    0.14    0.00    0.00    0.00    0.00   65.61
              10    0.06   32.53    0.06    0.08    0.00    0.00    0.00    0.00   67.27
              11    0.00   33.08    0.01    0.07    0.00    0.00    0.00    0.00   66.83
              12    1.93   34.21    0.58    0.35    0.00    0.03    0.00    0.00   62.90
              13    1.09   33.55    0.42    0.12    0.00    0.00    0.00    0.00   64.81
              14    2.20   30.88    0.77    0.16    0.00    0.07    0.00    0.00   65.91
              15    0.68   32.55    0.25    0.12    0.00    0.00    0.00    0.00   66.39
              16    0.42   32.44    0.16    0.09    0.00    0.00    0.00    0.00   66.89
              17    0.37   32.33    0.13    0.07    0.00    0.00    0.00    0.00   67.10
              18    0.55   34.98    0.33    1.71    0.00    0.02    0.00    0.00   62.41
              19    0.56   32.82    0.27    0.77    0.00    0.00    0.00    0.00   65.58
              20    0.23   32.71    0.10    0.22    0.00    0.00    0.00    0.00   66.74
              21    0.27   32.12    0.11    0.10    0.00    0.00    0.00    0.00   67.40
              22    0.17   33.00    0.07    0.07    0.00    0.00    0.00    0.00   66.68
              23    0.05   33.69    0.02    0.00    0.00    0.00    0.00    0.00   66.24
              24    0.25   46.35    0.10    0.31    0.00    0.00    0.00    0.00   52.99
              25    0.85   36.71    0.20    0.17    0.00    0.00    0.00    0.00   62.07
              26    0.74   32.46    0.25    0.12    0.00    0.09    0.00    0.00   66.35
              27    0.11   34.07    0.03    0.08    0.00    0.00    0.00    0.00   65.70
              28    0.02   33.05    0.02    0.07    0.00    0.00    0.00    0.00   66.84
              29    0.04   33.04    0.02    0.07    0.00    0.00    0.00    0.00   66.83
              30    0.39   38.23    0.14    0.96    0.00    0.00    0.00    0.00   60.26
              31    0.26   35.39    0.16    0.55    0.00    0.00    0.00    0.00   63.64
              32    0.11   33.66    0.04    0.11    0.00    0.00    0.00    0.00   66.08
              33    0.03   34.54    0.02    0.06    0.00    0.00    0.00    0.00   65.35
              34    0.05   33.83    0.03    0.08    0.00    0.00    0.00    0.00   66.01
              35    0.06   33.03    0.03    0.07    0.00    0.00    0.00    0.00   66.82
              36    0.62   52.54    0.32    2.24    0.00    0.04    0.00    0.00   44.24
              37    0.29   33.69    0.18    0.27    0.00    0.00    0.00    0.00   65.57
              38    0.12   35.01    0.10    0.40    0.00    0.00    0.00    0.00   64.37
              39    0.19   33.44    0.09    0.09    0.00    0.00    0.00    0.00   66.20
              40    0.14   33.73    0.06    0.07    0.00    0.00    0.00    0.00   65.99
              41    0.07   33.27    0.03    0.02    0.00    0.00    0.00    0.00   66.61
              42    0.74   31.73    0.35    1.21    0.00    0.01    0.00    0.00   65.95
              43    0.65   33.18    0.37    0.45    0.00    0.00    0.00    0.00   65.35
              44    0.19   33.79    0.09    0.03    0.00    0.00    0.00    0.00   65.90
              45    0.15   33.24    0.10    0.01    0.00    0.00    0.00    0.00   66.50
              46    0.16   33.04    0.07    0.06    0.00    0.00    0.00    0.00   66.68
              47    0.26   32.19    0.13    0.00    0.00    0.00    0.00    0.00   67.42 
[링크 : http://www.cyberciti.biz/tips/how-do-i-find-out-linux-cpu-utilization.html]

아무튼 gnome의
gnome-system-monitor는 32개가 한계인것 같고 



KDE의 ksysguard 는 띄우기는 하는데 모니터의 압박이...

 

'Linux' 카테고리의 다른 글

which 와 whereis  (0) 2011.10.24
top은 잊어라! htop  (0) 2011.10.07
/usr/bin/[ 넌 모니?  (0) 2011.10.05
Linux 휴지통 분석(?)  (2) 2011.10.03
리눅스 부팅으로 부터의 시간  (0) 2011.09.27
Posted by 구차니
Linux/Ubuntu2011. 10. 5. 22:56
visudo를 이용해서 Defaults에 아래의 항목을 추가하면 600분(10시간) 동안 물어보지 않는다.
$ sudo visudo
Defaults        env_reset,timestamp_timeout=600 

[링크 : http://ubuntu.or.kr/viewtopic.php?p=47637]
[링크 : http://lumitech.tistory.com/entry/sudoAndSudoer]

'Linux > Ubuntu' 카테고리의 다른 글

vlan on ubnutu  (0) 2011.11.05
netbeans package - ubuntu  (0) 2011.10.22
리눅스에서 하드 I/O 사용량 측정하는 방법  (0) 2011.09.27
엠퍼시 (empathy) 에서 음성대화하기  (2) 2011.09.25
우분투 LTS 지원기간  (0) 2011.09.24
Posted by 구차니
Linux2011. 10. 5. 14:36
도대체 이녀석 정체가 멀까?
도움말 상으로는 test로 연결이 되는데 흐음...
쉘 스크립트에서 사용하는 [] 랑 연관이 있는걸까?

[링크 : http://linux.die.net/man/1/test


$ ll -al \[
-rwxr-xr-x 1 root root 42584 2010-09-22 03:33 [* 

$ man -k "\["
[ (1)                - check file types and compare values 

$ file [
[: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.15, stripped 

% ./\[ --help
BusyBox v1.14.2 (2011-01-24 14:35:28 KST) multi-call binary

Usage: [ EXPRESSION ]

Check file types, compare values etc. Return a 0/1 exit code
depending on logical value of EXPRESSION 

/usr/bin$ ./\[ --help
사용법: test 표현식
  또는:  test
  또는:  [ 표현식 ]
  또는:  [ ]
  또는:  [ 옵션
Exit with the status determined by EXPRESSION.

      --help     이 도움말을 표시하고 끝냅니다
      --version  버전 정보를 출력하고 끝냅니다

An omitted EXPRESSION defaults to false.  Otherwise,
EXPRESSION is true or false and sets exit status.  It is one of:

  ( EXPRESSION )               EXPRESSION is true
  ! EXPRESSION                 EXPRESSION is false
  EXPRESSION1 -a EXPRESSION2   both EXPRESSION1 and EXPRESSION2 are true
  EXPRESSION1 -o EXPRESSION2   either EXPRESSION1 or EXPRESSION2 is true

  -n STRING            the length of STRING is nonzero
  STRING               equivalent to -n STRING
  -z STRING            the length of STRING is zero
  STRING1 = STRING2    the strings are equal
  STRING1 != STRING2   the strings are not equal

  INTEGER1 -eq INTEGER2   INTEGER1 is equal to INTEGER2
  INTEGER1 -ge INTEGER2   INTEGER1 is greater than or equal to INTEGER2
  INTEGER1 -gt INTEGER2   INTEGER1 is greater than INTEGER2
  INTEGER1 -le INTEGER2   INTEGER1 is less than or equal to INTEGER2
  INTEGER1 -lt INTEGER2   INTEGER1 is less than INTEGER2
  INTEGER1 -ne INTEGER2   INTEGER1 is not equal to INTEGER2

  FILE1 -ef FILE2   FILE1 and FILE2 have the same device and inode numbers
  FILE1 -nt FILE2   FILE1 is newer (modification date) than FILE2
  FILE1 -ot FILE2   FILE1 is older than FILE2

  -b FILE     FILE exists and is block special
  -c FILE     FILE exists and is character special
  -d FILE     FILE exists and is a directory
  -e FILE     FILE exists
  -f FILE     FILE exists and is a regular file
  -g FILE     FILE exists and is set-group-ID
  -G FILE     FILE exists and is owned by the effective group ID
  -h FILE     FILE exists and is a symbolic link (same as -L)
  -k FILE     FILE exists and has its sticky bit set
  -L FILE     FILE exists and is a symbolic link (same as -h)
  -O FILE     FILE exists and is owned by the effective user ID
  -p FILE     FILE exists and is a named pipe
  -r FILE     FILE exists and read permission is granted
  -s FILE     FILE exists and has a size greater than zero
  -S FILE     FILE exists and is a socket
  -t FD       file descriptor FD is opened on a terminal
  -u FILE     FILE exists and its set-user-ID bit is set
  -w FILE     FILE exists and write permission is granted
  -x FILE     FILE exists and execute (or search) permission is granted

Except for -h and -L, all FILE-related tests dereference symbolic links.
Beware that parentheses need to be escaped (e.g., by backslashes) for shells.
INTEGER may also be -l STRING, which evaluates to the length of STRING.

NOTE: [ honors the --help and --version options, but test does not.
test treats each of those as it treats any other nonempty STRING.

NOTE: your shell may have its own version of test and/or [, which usually supersedes
the version described here.  Please refer to your shell's documentation
for details about the options it supports.

Report [ bugs to bug-coreutils@gnu.org
GNU coreutils home page: <http://www.gnu.org/software/coreutils/>
General help using GNU software: <http://www.gnu.org/gethelp/>
Report [ translation bugs to <http://translationproject.org/team/> 

Posted by 구차니
Linux2011. 10. 3. 08:01
윈도우에는 Recycled(WinXP) $RECYCLE.BIN(Win7) 이 존재하듯
리눅스에는 .Trash-1000이 존재한다. (뒤에 숫자는 임의로 생성되는걸려나?)

리눅스에서는 . 으로 시작하면 숨김파일이 되기때문에 일단 숨김 디렉토리이고
하위 디렉토리 구성은 files 와 info로 나누어 진다. 
 


files 에서는 지워진 파일이 들어있고 (과거에 rm은 mv 로 대체해서 사용하던 방식의 업그레이드)
info 에는 ini 파일과 같은 형식으로
지워진 파일에 대한 정보가 들어있다.
 

$ cat wxp-ragexl-5-10-2600-6009.exe.trashinfo

[Trash Info]

Path=program/driver/Server/Intel Server Board SE7520BD2/wxp-ragexl-5-10-2600-6009.exe

DeletionDate=2011-09-25T19:47:20 



gnome의 경우
$HOME/.local/share/Trash 에 존재한다.

Posted by 구차니
Linux/Ubuntu2011. 9. 27. 16:34
iostat 라는 멋진 녀석이 있다는데
ubuntu 10.04 LTS desktop edition에서는 기본 포함되어 있지 않고 systat 패키지를 설치해야만 한다.

$ idstat -d 3
이라고만 치면 3초에 한번 disk에 대해서 리포팅을 한다.

$ iostat -d -x 5 3

[링크 : http://www.cyberciti.biz/tips/linux-disk-performance-monitoring-howto.html

Blk_read/s
Indicate the amount of data read from the device expressed in a number of blocks per second. Blocks are equivalent to sectors with 2.4 kernels and newer and therefore have a size of 512 bytes. With older kernels, a block is of indeterminate size.

Blk_wrtn/s
Indicate the amount of data written to the device expressed in a number of blocks per second.

iostat -d 2
Display a continuous device report at two second intervals.

[링크 : http://linux.die.net/man/1/iostat

Posted by 구차니
Linux2011. 9. 27. 11:48
현재 시스템이 부팅으로 부터 얼마의 시간동안 켜져있었는지 확인하는 방법으로

uptime 이라는 명령어와
/proc/uptime 이라는 파일이 존재한다.

[링크 : http://masigani.tistory.com/entry/Linux의-시간]
[링크 : http://linux.die.net/man/1/uptime

'Linux' 카테고리의 다른 글

/usr/bin/[ 넌 모니?  (0) 2011.10.05
Linux 휴지통 분석(?)  (2) 2011.10.03
dd를 이용한 리눅스 하드 복제 / 백업  (0) 2011.09.26
XD 메모리를 못 읽을때  (0) 2011.09.24
xterm 에서 F1 / F10 키 할당 해제하기  (0) 2011.09.21
Posted by 구차니
Linux2011. 9. 26. 19:03
dd로 원본 드라이브에서 사본으로 복제가 가능하다는데
용량이 사본 드라이브가 작을 경우에는 gpart나 clonezilla등으로 하라고 한다.

$ dd if=/dev/zero of=/dev/null

[링크 : http://www.backuphowto.info/linux-backup-hard-disk-clone-dd]
[링크 : http://tuxradar.com/content/how-clone-hard-drives-clonezilla] clonezilla

[링크 : http://www.linuxquestions.org/.../cloning-1-hard-disk-to-smaller-hard-disk-dd-or-ghost-228341/]
[링크 : http://geekyprojects.com/storage/how-to-clone-hard-drive-to-smaller-drive/] clonezilla
 
----
2011.09.27 추가

/dev/sdb (mySSD 8GB)를 마운트하지 않은 상황에서 명령어를 치니
$ sudo dd if=/dev/sda of=/dev/sdb
dd: `/dev/sdb' 로 쓰는 중: No space left on device
1006833+0 레코드 들어옴
1006832+0 레코드 나감
515497984 바이트 (515 MB) 복사됨, 23.6966 초, 21.8 MB/초 
음.. 배를 째는데 -_- 

마운트하고 나서 한참을 기다려도 응답이 없어 취소하고
언마운트 하고 마운트 하니 (sda가 60기가 이고, sdb는 8기가)

 
다른 문서를 찾아보니, bs(Block Size) 와 count를 이용해서 필요한 만큼만 제한을 할 수도 있을것 같다.
BS=1M count=4096 이면 4기가 만 저장을 하려나?
dd if=/dev/hda3 of=/home/sam/backup_set_1.img bs=1M count=4430
[링크 : http://www.softpanorama.org/Tools/dd.shtml]  

아무튼 꽤 오랜 시간이 걸려 복사는 되었지만(의도한 만큼의 용량보다는 좀 큰데..)
$ sudo dd if=/dev/sda1 of=/dev/sdb1 bs=1M count=4096
4096+0 레코드 들어옴
4096+0 레코드 나감
4294967296 바이트 (4.3 GB) 복사됨, 665.479 초, 6.5 MB/초 
정작 마운트를 하려니 위와 같은 에러로 마운트가 되지 않는다 -_-

gpart를 이용해서 파티션을 확인해도 파티션 정보가 날아가서 확인불가.. 

'Linux' 카테고리의 다른 글

Linux 휴지통 분석(?)  (2) 2011.10.03
리눅스 부팅으로 부터의 시간  (0) 2011.09.27
XD 메모리를 못 읽을때  (0) 2011.09.24
xterm 에서 F1 / F10 키 할당 해제하기  (0) 2011.09.21
grub 부팅 옵션 vga=771  (0) 2011.09.16
Posted by 구차니
Linux/Ubuntu2011. 9. 25. 19:58
Xnote LW20 Express 에서 초기 설정이 "Microphone 1"으로 되어있는데
"Microphone 2"로 해야지 마이크로 연결이 된다.

이걸 제외하면 엠퍼시에서 별다르게 설정할건 없으니 패스~

 
Posted by 구차니
Linux/Ubuntu2011. 9. 24. 22:28
Desktop LTS는 2년
Server LTS는 5년간 지원한다.

A new LTS version is usually released every 2 years. With the Long Term Support (LTS) version you get 3 years support on Ubuntu Desktop, and 5 years on Ubuntu Server. There is no extra fee for the LTS version; we make our very best work available to everyone on the same free terms. Upgrades to new versions of Ubuntu are and always will be free of charge.

[링크 : https://wiki.ubuntu.com/LTS]
 


Posted by 구차니