Difference between revisions of "User:Klapmuetz/Install on windows by CoLinux"

From ArchWiki
Jump to: navigation, search
m (+template:out of date)
(new image file for the archlinux 2007.08-2)
Line 1: Line 1:
 
[[Category:Getting and installing Arch (English)]]
 
[[Category:Getting and installing Arch (English)]]
 
[[Category:HOWTOs (English)]]
 
[[Category:HOWTOs (English)]]
{{out of date}}
 
  
 
== Arch and coLinux==
 
== Arch and coLinux==
'''''This guide no longer works.''''' Please don't try, it's not fun.
+
The previous 0.7.x ArchLinux image can't workable, because ArchLinux changed the repository name from 'current' to 'core'. I've build a new image for CoLinux.  All you need to do is download the [http://web.twpda.com/co.7z co.7z] batch file. ref: http://web.twpda.com/colinux .
  
Here you can find and provide info about using Arch and [http://www.colinux.org colinux].
+
Install method:
 +
co arch 1
 +
 +
Daily usage:
 +
co arch
  
There is a page in the coLinux wiki for installing Arch [http://colinux.wikia.com/wiki/ArchLinuxHowTo here], which explains how to install it from scratch, but is more out of date. (As of Apr 21, 2006)
+
Or, you can download the images directly from http://web.twpda.com/colinux.
  
=== Using an Arch Linux image in coLinux===
+
== The image build steps (for expert users) ==
Using [[Remote_ArchLinux_Install]] and an existing archlinx installation I built a Arch Linux 0.7.2 base ext3 filesystem. To get a quick and working solution follow these steps:
+
Using [[Remote_ArchLinux_Install]] and an existing Debian image I built a Arch Linux 0.8.0 base ext3 filesystem. I put the method to build ArchLinux image here. (The newest version have put in co.7z) (Note: arch.cmd is the same as co.cmd which contains in co.7z)
  
# Download and install stable version and archlinux root fs for 2.6 kernel on [http://sourceforge.net/project/showfiles.php?group_id=98788 colinux's sf.net project].  
+
Build ArchLinux on Colinux From Debian
NOTE: you should click the <b>View older releases in the Root FS Images - 2.6.x-based package</b> on download the image, because it is long time don't need to upgrade the image(it is still workable till Jun 30, 2007).
+
colinux 0.8.0 (devel-coLinux-20080120.exe)
The image size is reduced to 16M bytes only. Also read the [http://sourceforge.net/project/shownotes.php?release_id=436233&group_id=98788 notes].
+
archlinux 2007.08-2 (Archlinux-i686-2007.08-2.ftp.iso)
# Extract the files into your coLinux directory.
+
Debian 4.0r0 (Debian-4.0r0-etch.ext3.1gb)
#  Run the ArchLinuxSlirp.bat
 
  
==== Additional Notes ====
+
1. download required files
* You may want to to change ArchLinuxSlirp.bat for your network environment. (eg. eth0=slirp,,tcp:22/22  to let your putty could connect to linux box)
 
* If you want more free space, use [http://csemler.com/ topresize] to enlarge the fs image.
 
* The alternate configuration uses the TAP driver. This should work out-of-the-box if you follow [http://wiki.colinux.org/cgi-bin/coLinuxNetworking#head-98c3abd1fe10ab8139428f0360386aaf77d8f36d "Setting up native network (Bridged), Step 1: Option 1: native Windows network bridge"]
 
* The steps for build this mini-size image is on build_mini_arch.txt.
 
* To run as a Windows service see [http://wiki.colinux.org/cgi-bin/RunningAsAService this coLinux wiki page]
 
* current image fix /etc/rc.sysinit to use the 'static /dev', because colinux's stable version still using older kernel.  And it seems hang on uevents when boot with brand new [http://www.henrynestler.com/colinux/testing/devel-2.6.15-hn/20060731/ 2.6.15 colinux version](2006/07/31).
 
  
* we don't need to modify /etc/rc.sysinit after [http://www.henrynestler.com/colinux/autobuild/devel-20061106/ colinux 0.8 beta], bacause it already support udev(2006/11/15).
+
    on sf.net's colinux download page
 +
        colinux 0.8.0
 +
        Debian-4.0r0.ext3-etch.ext3.1gb.bz2
 +
        install colinux 0.8.0
 +
    http://gniarf.nerim.net/colinux/fs       
 +
        download fs_256Mb.bz2 blank ext3 file system
 +
    http://gniarf.nerim.net/colinux/swap/
 +
        download swap_64Mb.bz2   
 +
    extract all *.bz2 file into colinux's directory (can use 7-zip to extract)
 +
PS. This step could complete by following command.(wget & 7-zip required)
 +
  arch.cmd deb 1  
 +
 
 +
2. get newarch script
 +
 
 +
    ref: http://wiki.archlinux.org/index.php?title=Quick_Custom_Installation
 +
Use copy & paste method to create pacman.conf, newarch in c:\colinux
 +
(Must be unix line feed format)
 +
 
 +
3. run dabian system and mount windows c:\colinux directory as /mnt/win
 +
 
 +
    run deb.cmd under windows cmd window
 +
    C> arch.cmd deb
 +
 
 +
    apt-get install wget
 +
    mkdir -p /mnt/win /mnt/arch
 +
    mount -t cofs cofs1:/ /mnt/win
 +
    cd /mnt/win/colinux/
 +
    # arch.fs is file download from http://gniarf.nerim.net/colinux/fs
 +
    # mke2fs -j arch.fs  # using ext3 format, if the arch.fs is not formated by ext3
 +
    mount -o loop arch.fs /mnt/arch/
 +
    ./newarch  # answer y, y, n(don't need to make tar.gz file)
 +
 
 +
4. using the new arch.fs to boot
 +
 
 +
    copy deb.cmd to arch.cmd and change every word DEB to ARCH, deb to arch.
 +
    colinux-daemon -t nt kernel=vmlinux mem=%MEM% initrd=initrd.gz hda1=arch.fs hda2=arch.swap cofs1=c:\ root=/dev/hda1 eth0=slirp,,tcp:22:22/tcp:5000:5000
 +
 +
    run arch.cmd under windows cmd window
 +
    c> arch.cmd arch
 +
 +
    under colinux box
 +
 +
    nano -w /etc/rc.conf
 +
    # change the 'eth0' line as following:
 +
    eth0=dhcp
 +
 +
    /etc/rc.d/network restart # to access the network via slirp's dhcp method
 +
 +
5. modify fstab
 +
 
 +
    mkdir -p /mnt/win
 +
    vi /etc/fstab, append following lines       
 +
    /dev/hda1      /        ext3    noatime        1      1
 +
    /dev/hda2      none    swap    defaults        0      0
 +
    cofs1:/       /mnt/win cofs    noauto          0      0
 +
   
 +
    # here we let /dev/hda1 do auto fsck that may cause first time boot failed
 +
    # but, just continue, and try boot again, it will successful.
 +
 
 +
== build minial image (optional) ==
 +
1. reduce the disk usage in fs.from by remove useless packages
 +
1.1 boot from arch.fs
 +
1.2 try to remove most BASE packages
 +
    mkdir /mnt/win
 +
mount -t cofs cofs1:/ /mnt/win
 +
cd /mnt/win/colinux
 +
./reduce.sh
 +
    # edit reqpkg.txt if some dependency failed
 +
1.3 poweroff
 +
 
 +
2. boot from debian, copy arch.fs to arch_to.fs
 +
2.1 in windows create new empty file system as arch_to.fs
 +
2.2 in debian box
 +
    mkdir -p /mnt/arch /mnt/arch_to
 +
cd /mnt/win/colinux
 +
mount -o loop arch.fs /mnt/arch
 +
mount -o loop arch_to.fs /mnt/arch_to
 +
./clean.sh  # remove some log files in arch.fs
 +
    cp -rdp /mnt/arch/* /mnt/arch_to

Revision as of 13:03, 2 February 2008


Arch and coLinux

The previous 0.7.x ArchLinux image can't workable, because ArchLinux changed the repository name from 'current' to 'core'. I've build a new image for CoLinux. All you need to do is download the co.7z batch file. ref: http://web.twpda.com/colinux .

Install method:

co arch 1 

Daily usage:

co arch

Or, you can download the images directly from http://web.twpda.com/colinux.

The image build steps (for expert users)

Using Remote_ArchLinux_Install and an existing Debian image I built a Arch Linux 0.8.0 base ext3 filesystem. I put the method to build ArchLinux image here. (The newest version have put in co.7z) (Note: arch.cmd is the same as co.cmd which contains in co.7z)

Build ArchLinux on Colinux From Debian
colinux 0.8.0 (devel-coLinux-20080120.exe)
archlinux 2007.08-2 (Archlinux-i686-2007.08-2.ftp.iso)
Debian 4.0r0 (Debian-4.0r0-etch.ext3.1gb)

1. download required files

   on sf.net's colinux download page
       colinux 0.8.0
       Debian-4.0r0.ext3-etch.ext3.1gb.bz2
       install colinux 0.8.0
   http://gniarf.nerim.net/colinux/fs        
       download fs_256Mb.bz2 blank ext3 file system
   http://gniarf.nerim.net/colinux/swap/
       download swap_64Mb.bz2    
   extract all *.bz2 file into colinux's directory (can use 7-zip to extract)

PS. This step could complete by following command.(wget & 7-zip required) arch.cmd deb 1

2. get newarch script

   ref: http://wiki.archlinux.org/index.php?title=Quick_Custom_Installation

Use copy & paste method to create pacman.conf, newarch in c:\colinux (Must be unix line feed format)

3. run dabian system and mount windows c:\colinux directory as /mnt/win

   run deb.cmd under windows cmd window
   C> arch.cmd deb
   apt-get install wget
   mkdir -p /mnt/win /mnt/arch
   mount -t cofs cofs1:/ /mnt/win
   cd /mnt/win/colinux/
   # arch.fs is file download from http://gniarf.nerim.net/colinux/fs
   # mke2fs -j arch.fs  # using ext3 format, if the arch.fs is not formated by ext3
   mount -o loop arch.fs /mnt/arch/
   ./newarch  # answer y, y, n(don't need to make tar.gz file)

4. using the new arch.fs to boot

   copy deb.cmd to arch.cmd and change every word DEB to ARCH, deb to arch.
   colinux-daemon -t nt kernel=vmlinux mem=%MEM% initrd=initrd.gz hda1=arch.fs hda2=arch.swap cofs1=c:\ root=/dev/hda1 eth0=slirp,,tcp:22:22/tcp:5000:5000
   run arch.cmd under windows cmd window
   c> arch.cmd arch
   under colinux box
   nano -w /etc/rc.conf
   # change the 'eth0' line as following:
   eth0=dhcp
   /etc/rc.d/network restart # to access the network via slirp's dhcp method

5. modify fstab

   mkdir -p /mnt/win
   vi /etc/fstab, append following lines        
   /dev/hda1      /        ext3     noatime         1       1
   /dev/hda2      none     swap     defaults        0       0
   cofs1:/	       /mnt/win cofs     noauto          0       0
   
   # here we let /dev/hda1 do auto fsck that may cause first time boot failed
   # but, just continue, and try boot again, it will successful.

build minial image (optional)

1. reduce the disk usage in fs.from by remove useless packages

1.1 boot from arch.fs
1.2 try to remove most BASE packages
   mkdir /mnt/win

mount -t cofs cofs1:/ /mnt/win cd /mnt/win/colinux ./reduce.sh

   # edit reqpkg.txt if some dependency failed
1.3	poweroff

2. boot from debian, copy arch.fs to arch_to.fs

2.1 in windows create new empty file system as arch_to.fs
2.2 in debian box
   mkdir -p /mnt/arch /mnt/arch_to

cd /mnt/win/colinux mount -o loop arch.fs /mnt/arch mount -o loop arch_to.fs /mnt/arch_to ./clean.sh # remove some log files in arch.fs

   cp -rdp /mnt/arch/* /mnt/arch_to