Skip to content

리눅스 IO 스케쥴러 변경하기

조회 수 33226 추천 수 0 2010.12.13 16:32:31

현재 리눅스에서 제공되는 IO 스케쥴러는 아래의 4가지가 기본으로 제공된다.

 

  • Completely Fair Queuing?elevator=cfq (default)
  • Deadline?elevator=deadline
  • NOOP?elevator=noop
  • Anticipatory?elevator=as

     

    IO 스케쥴러에 대한 변경은 부팅시와 런타임 모두 가능하며 현재 default로 지정된 IO 스케쥴러의 확인은

     /sys/block/sda/queue/scheduler 에서 살펴볼 수 있다.

     # cat scheduler
    anticipatory deadline [cfq]

    출력값에서 [ ] 안의 스케쥴러가 현재 사용중인 스케쥴러이다. 따라서 cfq가 디폴드 스케쥴러로 되어있음을

    알수 있다.

     

    부팅 타임시에 변경은 /etc/grub.conf 의 kernel 옵션을 아래와 같이 추가함으로써 가능하다.

     

    # grub.conf generated by anaconda
    #
    # Note that you do not have to rerun grub after making changes to this file
    # NOTICE:  You have a /boot partition.  This means that
    #          all kernel and initrd paths are relative to /boot/, eg.
    #          root (hd0,0)
    #          kernel /vmlinuz-version ro root=/dev/sda2
    #          initrd /initrd-version.img
    #boot=/dev/sda
    default=0
    timeout=5
    splashimage=(hd0,0)/grub/splash.xpm.gz
    hiddenmenu
    title Booyo Server (2.6.16-404.BS2smp)
            root (hd0,0)
            kernel /vmlinuz-2.6.16-404.BS2smp ro root=LABEL=/12 rhgb quiet elevator=cfq
            initrd /initrd-2.6.16-404.BS2smp.img
    title Booyo Server-up (2.6.16-404.BS2)
            root (hd0,0)
            kernel /vmlinuz-2.6.16-404.BS2 ro root=LABEL=/12 rhgb quiet elevator=noop
            initrd /initrd-2.6.16-404.BS2.img


     

    런타임시에 변경은  /sys/block/sda/queue/scheduler의 파일 내용을 아래와 같이 직접 write 함으로써 가능하다.

    단순히 변경하고자 하는 스케쥴러의 이름을 echo 시키면 반영된다.

     

    # cd /sys/block/sda/queue

    # echo anticipatory > scheduler
    # cat scheduler
    [anticipatory] deadline cfq noop

  • profile

    일요일은 짜빠게뤼~ 먹는날~^^

    엮인글 :
    http://adminplay.com/32146/e22/trackback
    List of Articles
    번호 제목 글쓴이 날짜 조회 수sort
    367 도메인 Status 상태별 설명 안내 ADMINPLAY 2012-12-28 4892
    366 HDD Guardian (a graphical user interface for smartctl) ADMINPLAY 2013-09-22 4998
    365 dpkg 사용법 ADMINPLAY 2013-04-03 5009
    364 top 화면 내용중 load average와 PRI : priority(우선순위... ADMINPLAY 2013-12-24 5200
    363 ubuntu 10.04 에서 Nginx, Mysql, PHP5 ADMINPLAY 2013-02-28 5237
    362 HP 서버 disk 증설 (hpacucli 사용) ADMINPLAY 2015-08-05 5237
    361 리눅스 메모리 관리, 왜 메모리 여유공간이 없을까? (top ... ADMINPLAY 2013-04-25 5298
    360 windows smartctl ADMINPLAY 2013-09-22 5328
    359 ZFS 파일에 ACL 설정 ADMINPLAY 2014-02-03 5335
    358 make 정리 ADMINPLAY 2013-05-12 5340
    357 SSL 패스워드 삭제 하기 ADMINPLAY 2014-04-27 5442
    356 EXT4 파일 시스템을 Btrfs 파일 시스템으로 변환하기 ADMINPLAY 2015-07-07 5452
    355 tar 압축을 실수로 디렉토리 생성 안하고 풀었을때 대처법 ADMINPLAY 2013-09-22 5462
    354 ll 명령시 날짜 전체가 보이도록 하기 ADMINPLAY 2014-01-02 5481
    353 hddtemp와 mrtg를 이용한 하드디스크 온도 체크 file ADMINPLAY 2013-12-19 5514
    352 python과 mysql 연동시 libmysqlclient_r.so.* 에러가 날 ... ADMINPLAY 2014-03-27 5592
    351 linux 커널 파라메터 수정 ADMINPLAY 2013-05-12 5613
    350 우분투(Ubuntu) ssh 설정하기 ADMINPLAY 2013-02-27 5664
    349 error: Hm, kex protocol error: type 30 seq 1 [preauth]... file ADMINPLAY 2016-05-20 5664
    348 운영중인 Linux 서버에서 NTFS 파일 시스템 삭제하기 ADMINPLAY 2013-01-16 5734

    Copyright ADMINPLAY corp. All rights reserved.

    abcXYZ, 세종대왕,1234

    abcXYZ, 세종대왕,1234