aix etherchannel 구성하기.

1. EtherChannel 이란?

스위치의 여러개의 포트를 묶어 하나의 포트처럼 작동하게 하는 기술로, 넓은 대역폭을 확보하거나, 하나의 포트가 고장나도 작동하는데 이상이 없도록하는 기술이다. 스위치 제조사에 따라서, port trunking, port aggregation, teaming, bonding 등 여러가지 이름으로 사용된다.

Continue reading

apache2 mod_evasive로 DDoS 방어하기.

debian 계열 Linux에서 apache2 웹서버를 운영한다면, 간단한 방법으로 DDoS 공격을 차단 할 수 있다.

mod_evasive 를 사용하는 방법이다. mod_evasive는 따로 설치해 주어야 하며, debian 계열에서는 간단하게 설치가 가능하다.
Continue reading

Linux Docker.

참고문서:
https://docs.docker.com/engine/installation/ubuntulinux/
https://docs.docker.com/engine/userguide/
https://docs.docker.com/engine/userguide/basics/

 

I. 설치

1. 설치(ubuntu 14.04 에서).

아래 커맨드로, docker repository를 위한 pgp key를 등록한다.

# apt-key adv --keyserver hkp://pgp.mit.edu:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --homedir /tmp/tmp.fq7Qgn6cd8 --no-auto-check-trustdb --trust-model always --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyserver hkp://pgp.mit.edu:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
gpg: requesting key 2C52609D from hkp server pgp.mit.edu
gpg: key 2C52609D: public key "Docker Release Tool (releasedocker) <docker@docker.com>" imported
gpg: Total number processed: 1
gpg:               imported: 1  (RSA: 1)

docker repository를 등록한다. /etc/apt/sources.list.d/docker.list 화일을(없으면 만들고) 아래와 같이 편집한다. os version이 ubuntu14.04이므로 trusty repository를 등록.

#vi /etc/apt/sources.list.d/docker.list
# Ubuntu Trusty
deb https://apt.dockerproject.org/repo ubuntu-trusty main

ubuntu 14.04 이전 버전에서는 설치 시 커널을 업그레이드 해 주어야 하지만, 여기서는 14.04 이기 때문에, 커널 업그레이드는 필요 하지 않다.

# apt-get install docker-engine
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  aufs-tools cgroup-lite git git-man liberror-perl
Suggested packages:
  git-daemon-run git-daemon-sysvinit git-doc git-el git-email git-gui gitk
  gitweb git-arch git-bzr git-cvs git-mediawiki git-svn
The following NEW packages will be installed:
  aufs-tools cgroup-lite docker-engine git git-man liberror-perl
0 upgraded, 6 newly installed, 0 to remove and 3 not upgraded.
Need to get 9,067 kB of archives.
After this operation, 50.4 MB of additional disk space will be used.
Do you want to continue? [Y/n]

Continue reading

dmidecode 로 알 수 있는 것 들.

dmidecode 는 컴퓨터의 DMI(또는 SMBIOs) 테이블의 정보를 사람이 볼 수 있도록 보여주는 tool 이다.

옵션 없이 사용하면 DMI의 모든 테이블이 표시된다. 결과는 아래 양식으로 표시된다.

Record Header: Handle {record id}, DMI type {dmi type id}, {record size} bytes
Record Value: {multi line record value}
Continue reading

puppet

puppet – 루비로 만든 서버 설정 자동화 툴

MySQL Replication (master – slave, master-master 구성)

구성환경
OS: CentOS6.6
mysql : rpm package 설치
server1: fox1 , 192.168.0.94
server2: fox2 , 192.168.0.95
mysql Replication : master-slave 방식 구성. server1 이 master, server2를 slave로 설정.(slave 는 여러 대를 설정 할 수 있지만, 여기서는 1대만 설정한다.)
참고 문서: https://dev.mysql.com/doc/refman/5.0/en/replication-howto.html

I. Mysql Master-Slave Replication

1. MySQL 설치(server1, server2)
RPM 패키지로 설치하기로 함. 설치 후에는 mysql_secure_installation 커맨드로, root 비밀번호를 설정하고, 불필요한 database, 계정 등을 제거한다.

Continue reading

centos 6.5 minimal version에서 x11 forwarding 오류.

centos 6.5 minimal version 에서 아래와 같이 X11 포워딩이 안되는 문제가 발생.

WARNING! The remote SSH server rejected X11 forwarding request.

sshd_config 화일에서, x11 forwarding을 허용하도록 설정이 되어 있다.

# cat /etc/ssh/sshd_config | grep -i x11
#X11Forwarding no
X11Forwarding yes
#X11DisplayOffset 10
#X11UseLocalhost yes
#       X11Forwarding no

확인 결과 xorg-x11-xauth, xorg-x11-fonts-*, xorg-x11-utils 패키지가 필수라고 한다. 이들 필수 패키지를 설치한다.

# yum install xorg-x11-xauth xorg-x11-fonts-* xorg-x11-utils

이후, desktop 실행하면 잘 된다.


CentOS 7 minimal 에서 위의 패키지 설치후 아래 오류 발생할 경우

X11 forwarding request failed on channel 0

xauth 패키지를 설치하면 됨.

# yum install xauth

linux powerpath 설치 – CentOS6

사용환경
CentOS Linux release 6.5 64bit, Minimal version
EMC powerpath

1. naviagentcli 설치

naviagentcli rpm 패키지가 있는 디렉토리로 이동하여, 패키지를 설치한다.

# yum install ./naviagentcli-6.26.32.0.72-1.noarch.rpm
Loaded plugins: fastestmirror
S...
Installed:
  naviagentcli.noarch 0:6.26.32.0.72-1

Complete!

navisphere agent를 실행한다.

# /etc/init.d/naviagent start
Starting Navisphere agent:                                 [  OK  ]

Continue reading

bash history에 시간 넣기

보통 history 커맨드를 내리면, 아래처럼 보인다.

  999  ls
 1000  ls -l
 1001  history
 1002  clear
 1003  history

Continue reading

보호된 글: sec. check 임시

이 콘텐츠는 비밀번호로 보호되어 있습니다. 이 콘텐츠를 보려면 아래에 비밀번호를 입력해주세요.