[ubuntu] 우분투 기본 설정 및 명령어
[root 패스워드 지정]
# sudo passwd root
2번 입력
# su -
전환 확인
[종료 및 재부팅]
종료 : sudo shutdown -h now
sudo power off
재시작 : shudo shutdown -r now
reboot
[IP 설정]
1. 설정파일 수정
vi /etc/network/interfaces
auto eth0
iface eth0 inet static
address 192.168.50.41
netmask 255.255.255.0
gateway 192.168.50.1
[본딩 설정]
1. ifenslave 패키지 설치 및 설정 변경
apt-get install ifenslave-2.6
vi /etc/modules
# /etc/modules: kernel modules to load at boot time.
#
# This file contains the names of kernel modules that should be loaded
# at boot time, one per line. Lines beginning with "#" are ignored.
loop
lp
rtc
bonding
-> bonding 라인 추가
2. networking 서비스 및 모듈 로딩
/etc/init.d/networking stop
modprobe bonding
3. 설정파일 수정
vi /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
auto eth0
iface eth0 inet dhcp
#auto eth1
#iface eth1 inet dhcp
#eth1 configuration
auto eth1
iface eth1 inet manual
bond-master bond0
bond-primary eth0
eth2 configuration
auto eth2
iface eth2 inet manual
bond-master bond0
# Bonding eth1 & eth2 to create bond0 NIC
auto bond0
iface bond0 inet static
address 192.168.56.220
gateway 192.168.56.1
netmask 255.255.255.0
bond-mode active-backup
bond-miimon 100
bond-slaves none
bond-fail-over-mac 1 // VirtualBox 절체 테스트 이슈로 인한 설정
/etc/init.d/networking start
cat /proc/net/bonding/bond0 // 확인
[참고 URL]
https://help.ubuntu.com/community/UbuntuBonding