'2017/10/19'에 해당되는 글 3건

  1. 2017.10.19 numactl 커맨드
  2. 2017.10.19 [docker] aufs
  3. 2017.10.19 [iterm2] 소리 안나게 하는 방법

numactl 커맨드

unix and linux 2017. 10. 19. 22:06


numa 아키텍처(Non-Uniform Memory Access, NUMA)는 멀티프로세서 시스템에서 사용되고 있는 컴퓨터 메모리 설계 방법중의 하나로, 메모리에 접근하는 시간이 메모리와 프로세서간의 상대적인 위치에 따라 달라진다. NUMA구조에서 프로세서는 자기의 로컬 메모리에 접근할 때가 원격 메모리에 접근할 때보다 더 빠르다. 원격 메모리는 다른 프로세서에 연결되어 있는 메모리를 말하고 로컬 메모리는 자기 프로세서에 연결되어 있는 메모리를 말한다.


https://ko.wikipedia.org/wiki/%EB%B6%88%EA%B7%A0%EC%9D%BC_%EA%B8%B0%EC%96%B5_%EC%9E%A5%EC%B9%98_%EC%A0%91%EA%B7%BC



numa를 잘 활용해야 훨씬 빠르게 메모리를 관리할 수 있다. 




https://github.com/numactl/numactl


numa 아키텍처에서 지원하는 간단한 AP로서 numa 아키텍처에서 동작하는 java daemon을 실행할 때 자주 사용될 수 있다. elasticsearch나 cassandra에 사용한다면 성능 효과를 얻을 수 있다. 




https://www.slideshare.net/slidunder/numa-and-java-databases





numactl은 공유 메모리 또는 파일에 대한 정책을 지정할 수 있다. 





예를 들어 간단한 numactl 커맨드가 있다.


$ numactl --interleave=all /home/www/elasticsearch-5.3/bin/elasticsearch -d


interleave 모드를 사용하면 라운드 로빈으로 메모리를 노드에 할당하게 한다. numa 아키텍처를 활용해 빠르게 접근하게 한다!





https://linux.die.net/man/8/numactl



--interleave=nodes, -i nodes
Set a memory interleave policy. Memory will be allocated using round robin on nodes. When memory cannot be allocated on the current interleave target fall back to other nodes. Multiple nodes may be specified on --interleave, --membind and --cpunodebind. You may specify "all", which means all nodes in the current cpuset. nodes may be specified as N,N,N or N-N or N,N-N or N-N,N-N and so forth. Relative nodes may be specifed as +N,N,N or +N-N or +N,N-N and so forth. The + indicates that the node numbers are relative to the process' set of allowed nodes in its current cpuset. A !N-N notation indicates the inverse of N-N, in other words all nodes except N-N. If used with + notation, specify !+N-N.



자바와 NUMA 아키텍처와 관련된 설명은 다음을 참조한다.

https://www.slideshare.net/slidunder/numa-and-java-databases


이 슬라이드는 numctl과 cassandra 간의 조심스러움을 표현하고 있다. 


NUMA and Java Databases from Raghavendra Prabhu






Posted by '김용환'
,

[docker] aufs

docker 2017. 10. 19. 21:46


docker info 커맨드를 실행하면 다음 스토리지 드라이버로 aufs가 나타난다.  


...

Storage Driver: aufs

 Root Dir: /var/lib/docker/aufs

 Backing Filesystem: extfs

 Dirs: 98

 Dirperm1 Supported: true




docker의 내부 스택이 바로 aufs로 되어 있다.

(출처 : https://docs.docker.com)






따라서 docker containerization을 지원하는 형태는 mesos는 지원하는 당연히 aufs 파일 시스템을 지원한다. 

ubuntu랑도 docker가 잘 궁합이 맞는 것도 그런 드 하다. 



http://mesos.apache.org/documentation/latest/container-image/


AUFS

The reason AUFS is introduced is because overlayfs support hasn’t been merged until kernel 3.18 and Docker’s default storage backend for ubuntu 14.04 is AUFS.

Like overlayfs, AUFS is also a unioned file system, which is very stable, has a lot of real-world deployments, and has strong community support.

Some Linux distributions do not support AUFS. This is usually because AUFS is not included in the mainline (upstream) Linux kernel.

For more information of AUFS, please refer to here.


Posted by '김용환'
,

* iterm2에서 소리 안나게 하는 방법


Preferences -> Profiles -> Terminal tab -> Check "Silence bell"



Posted by '김용환'
,