본문 바로가기

작업일지/coLinux

coLinux 설치

coLinux 설치에 대한 내용.

먼저 coLinux와 linux커널(debian)을 다운로드.
coLinux-0.7.5.exe
Debian-5.0r2-lenny.7z

c:\coLinux에 coLinux-0.7.5를 설치한다.

Windows의 제어판->네트웍연결을 보면 새로 생성된 네트웍이 있다.("로컬 영역 연결 2"와 같은것...)
(속성을 보면 장치가 "TAP-Win32 Adapter V8 (coLinux)"로 되어 있는것이 새로 생성한 것이다.)
"로컬 영역 연결 2"의 이름을 "coLinuxNet"등 알기쉬운 이름으로 변경한다.
속성을 수정한다.
IP:192.168.50.100
NETMASK:255.255.255.0
나머지는 속성을 비워둔다.



Debian-5.0r2-lenny.7z를 다운로드 한다.
d:\coLinux\Images\DebianLenny
Debian-5.0r2-lenny.7z를 압축 해제후 debian-lenny.conf을 수정한다.

 #
# This is an example for a configuration file that can
# be passed to colinux-daemon in this manner:
#
#    colinux-daemon @example.conf
#
# Note that you can still prepend or append configuration and
# boot parameters before and after '@', or you can use more
# that one '@ to load several settings one after another.
#
#    colinux-daemon @example.conf @overrider.conf mem=32
#
# Full list of config params is listed in colinux-daemon.txt.

# The default kernel
kernel=c:\coLinux\vmlinux                      <- coLinux가 설치된곳의 vmlinux파일

# File contains the root file system.
# Download and extract preconfigured file from SF "Images for 2.6".
cobd0="Debian-5.0r2-lenny.ext3.2gb"

# Swap device, should be an empty file with 128..512MB.
cobd1="swap.disk"

# Tell kernel the name of root device (mostly /dev/cobd0,
# /dev/cobd/0 on Gentoo)
# This parameter will be forward to Linux kernel.
root=/dev/cobd0

# Additional kernel parameters (ro = rootfs mount read only)
ro

# Initrd installs modules into the root file system.
# Need only on first boot.
initrd=c:\coLinux\initrd.gz                  <- coLinux가 설치된곳의 initrd.gz파일

# Maximal memory for linux guest
mem=256

# Select console size, default is 80x25
#cocon=120x40

# Slirp for internet connection (outgoing)
# Inside running coLinux configure eth0 with this static settings:
# ipaddress 10.0.2.15   broadcast  10.0.2.255   netmask 255.255.255.0
# gateway   10.0.2.2    nameserver 10.0.2.3
#eth0=slirp
eth0=tuntap, coLinuxNet

# Tuntap as private network between guest and host on second linux device
#eth1=tuntap

# Setup for serial device
#ttys0=COM1,"BAUD=115200 PARITY=n DATA=8 STOP=1 dtr=on rts=on"

# Run an application on colinux start (Sample Xming, a Xserver)
#exec0=C:\Programs\Xming\Xming.exe,":0 -clipboard -multiwindow -ac"



debian-lenny.bat을 수정한다.

@ECHO OFF

set COLINUX_CONSOLE_FONT=Lucida Console:12
set COLINUX_CONSOLE_EXIT_ON_DETACH=1
"c:\coLinux\colinux-daemon.exe" -v 3 -t nt @debian-lenny.conf


debian-lenny.bat를 더블클릭. coLinux실행
root의 비밀번호 변경.
# passwd root











이미지 사이즈 변경 2GB -> 10GB
- 디스크 생성
콘솔에서 다음명령 수행
> fsutil.exe file createnew Debian-5.0r2-lenny.ext3.10gb 10737418240

기존 이미지 백업.
> copy Debian-5.0r2-lenny.ext3.2gb Debian-5.0r2-lenny.ext3.2gb.old

debian-lenny.conf을 수정
 #
# This is an example for a configuration file that can
# be passed to colinux-daemon in this manner:
#
#    colinux-daemon @example.conf
#
# Note that you can still prepend or append configuration and
# boot parameters before and after '@', or you can use more
# that one '@ to load several settings one after another.
#
#    colinux-daemon @example.conf @overrider.conf mem=32
#
# Full list of config params is listed in colinux-daemon.txt.

# The default kernel
kernel=c:\coLinux\vmlinux

# File contains the root file system.
# Download and extract preconfigured file from SF "Images for 2.6".
cobd0="Debian-5.0r2-lenny.ext3.2gb"

# Swap device, should be an empty file with 128..512MB.
cobd1="swap.disk"

# Tell kernel the name of root device (mostly /dev/cobd0,
# /dev/cobd/0 on Gentoo)
# This parameter will be forward to Linux kernel.
root=/dev/cobd0

# Additional kernel parameters (ro = rootfs mount read only)
ro

# Initrd installs modules into the root file system.
# Need only on first boot.
initrd=c:\coLinux\initrd.gz

# Maximal memory for linux guest
#mem=256

# Select console size, default is 80x25
#cocon=120x40

# Slirp for internet connection (outgoing)
# Inside running coLinux configure eth0 with this static settings:
# ipaddress 10.0.2.15   broadcast  10.0.2.255   netmask 255.255.255.0
# gateway   10.0.2.2    nameserver 10.0.2.3
#eth0=slirp
eth0=tuntap, coLinuxNet

# Tuntap as private network between guest and host on second linux device
#eth1=tuntap

# Setup for serial device
#ttys0=COM1,"BAUD=115200 PARITY=n DATA=8 STOP=1 dtr=on rts=on"

# Run an application on colinux start (Sample Xming, a Xserver)
#exec0=C:\Programs\Xming\Xming.exe,":0 -clipboard -multiwindow -ac"

# 디스크 확장을 위해 장치로 잡음.
cobd2=Debian-5.0r2-lenny.ext3.2gb.old            <- 추가
cobd3=Debian-5.0r2-lenny.ext3.10gb"               <- 추가  


debian-lenny.bat를 더블클릭. coLinux실행
root 로그인.
파일시스템 테크
 # e2fsck /dev/cobd1
e2fsck 1.41.3 (12-Oct-2008)
/dev/cobd2: clean, 178740/1310720 files, 2146309/2621440 blocks


디스크 복사
# dd if=/dev/cobd2 of=/dev/cobd3

파일시스템 체크
# e2fsck -f /dev/cobd3

파일시스템 리사이징
# resize2fs -p /dev/cobd3

파일시스템 체크
# e2fsck -f /dev/cobd3

coLinux 종료
# shutdown now


debian-lenny.conf을 수정
  #
# This is an example for a configuration file that can
# be passed to colinux-daemon in this manner:
#
#    colinux-daemon @example.conf
#
# Note that you can still prepend or append configuration and
# boot parameters before and after '@', or you can use more
# that one '@ to load several settings one after another.
#
#    colinux-daemon @example.conf @overrider.conf mem=32
#
# Full list of config params is listed in colinux-daemon.txt.

# The default kernel
kernel=c:\coLinux\vmlinux

# File contains the root file system.
# Download and extract preconfigured file from SF "Images for 2.6".
cobd0="Debian-5.0r2-lenny.ext3.10gb"                       <- 10기가짜리 이미지로 변경

# Swap device, should be an empty file with 128..512MB.
#cobd1="swap.disk"

# Tell kernel the name of root device (mostly /dev/cobd0,
# /dev/cobd/0 on Gentoo)
# This parameter will be forward to Linux kernel.
root=/dev/cobd0

# Additional kernel parameters (ro = rootfs mount read only)
ro

# Initrd installs modules into the root file system.
# Need only on first boot.
initrd=c:\coLinux\initrd.gz

# Maximal memory for linux guest
#mem=256

# Select console size, default is 80x25
#cocon=120x40

# Slirp for internet connection (outgoing)
# Inside running coLinux configure eth0 with this static settings:
# ipaddress 10.0.2.15   broadcast  10.0.2.255   netmask 255.255.255.0
# gateway   10.0.2.2    nameserver 10.0.2.3
#eth0=slirp
eth0=tuntap, coLinuxNet

# Tuntap as private network between guest and host on second linux device
#eth1=tuntap

# Setup for serial device
#ttys0=COM1,"BAUD=115200 PARITY=n DATA=8 STOP=1 dtr=on rts=on"

# Run an application on colinux start (Sample Xming, a Xserver)
#exec0=C:\Programs\Xming\Xming.exe,":0 -clipboard -multiwindow -ac"

파일 저장후 debian-lenny.bat를 수행해서 coLinux실행
디스크 사이즈 검사.
# df -h

기존에 사용하던 2GB 디스크 이미지는 삭제한다.
windows에 있는 "cobd1=Debian-5.0r2-lenny.ext3.2gb"과 "cobd1=Debian-5.0r2-lenny.ext3.2gb.old" 삭제.



topresize툴을 이용한 방법도 있다.
사용 해보진 않음.
다운로드:
http://csemler.com/cs.html
사용기:
http://carlstrom.com/andlinux/
http://www.ioware.ca/wiki/doku.php/colinux:virtual_disks
http://www.pendrivelinux.com/how-to-resize-casper-rw-images/
http://colinux.wikia.com/wiki/ExpandingRoot




ntfs마운트를 위해 ntfs라이브러리 설치(설 치 안해도 마운트됨)
# apt-get install ntfs-3

마운트 설정
# more /etc/fstab
# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0

/dev/cobd0      /               ext3    relatime,errors=remount-ro 0       1
/dev/cobd1      none            swap    sw                         0       0
/dev/cobd2      /tmp            ext2    defaults                   0       0

/dev/scd0       /media/cdrom0   udf,iso9660 user,noauto,exec,utf8 0       0

#Windows disks

cofs0          /etc/portable_ubuntu    cofs    user,dmask=0777,fmask=0666 0       0
cofs1          /mnt/C              cofs    user,dmask=0777,fmask=0666 0       0








# dhclient





설치하기
http://affo.springnote.com/pages/3347939
swap파일 생성
http://colinux.wikia.com/wiki/HowtoCreateSwapFile
루트파일시스템 확장
http://colinux.wikia.com/wiki/ExpandingRoot
coLinux 소개 및 설치
http://infeat.co.cc/1
coLinux Network 설정하기 (coLinux Network Configuration Guide)
http://techblog.tistory.com/entry/coLinux-Network
coLinux 시작 및 내부 네트워크 설정
http://rhapxodist.springnote.com/pages/5319847
coLinux 설치 및 설정 (Ubuntu 기반)
http://rhapxodist.springnote.com/pages/5319847
disk resize
http://www.vtk.org/Wiki/User:Andy/Colinux#Resizing_your_filesystem
http://www.tekcited.net/colinux-expanding-the-root-file-system/
http://www.linuxquestions.org/questions/slackware-14/howto-expand-root-image-in-slackware-on-colinux-776526/







[tap win32 네트웍 아탑터가 network 연결 안될때]
1. 네트워크 연결에서 coLinux 네트워크(tap win32)의 속성을 선택.
2. 구성 -> 고급 탭 선택
4. 속성 중에 Media Status 를 선택해서 값을 Always conneted 로 변경.