User Tools

Site Tools


users:pikpik:notes

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

users:pikpik:notes [2014/11/12 10:32]
lionelsambuc created
users:pikpik:notes [2014/11/12 10:32] (current)
lionelsambuc created
Line 1: Line 1:
 +====== Notes ======
  
 +===== Performance =====
 +
 +==== Limits ====
 +
 +^  Commit c248e23 ^  Memory ​            ​^ ​ Storage ​              ​^ ​ Network Speed                                       ||
 +^  Condition ​     |  Single-user mode   ​| ​ Installation onto MFS |  AMD Lance/​PCI ​         |  Intel PRO/1000 MT          |
 +^  Minimum ​       |  16 MiB             ​| ​ 598 MB<​sup>​1 2</​sup> ​ |  0 Bps                  |  0 Bps                      |
 +^  Maximum ​       |  4 GiB ?            |  2 TB ?                |  ~1200 kBps<​sup>​3</​sup>​ |  ~1.19 MiB/​s<​sup>​4</​sup> ​   |
 +
 +  - There might be an off-by-one error in //setup// or VirtualBox: when a VirtualBox VDI (disk) of 597 MB is created, //setup// states that the **596 MB** disk doesn'​t meet the requirement of 597 MB.
 +  - More space is needed for normal operation. Subsystems show errors when there isn't sufficient storage space for additional tasks.
 +  - The test involved using //fetch// to download a 356 MB file from the Apache Web server on Mac OS X (10.5.8) with 4 GiB of memory and a gigabit network adapter and router. MINIX ran in VirtualBox (4.1.23) with 512 MiB of memory and an SATA (AHCI) storage controller.
 +  - //cd /usr; make pkgsrc-create//​ on //​minix3_2_1_ide_20121207_1118489.iso//​ in Qemu 0.15.1 with 1 GiB of memory.
 +
 +==== Build times ====
 +
 +^ Version ​                                                                              ^ Time taken           ^ Build environment ​                           |
 +| [[https://​github.com/​pikpik/​minix/​tree/​building-on-darwin|custom:​ building-on-darwin]] | ~20 minutes ​        | 4GiB RAM on Mac OS X (10.5.8) ​               |
 +| current ​                                                                               | ~3.5 hours          | 1 GiB RAM in VirtualBox on Mac OS X (10.5.8) |
 +| current ​                                                                               | ~3.5 hours          | 1 GiB RAM in QEMU 0.15.1 on Windows 7        |
 +
 +
 +===== Installation =====
 +
 +==== Installing with ext2 ====
 +
 +<​code>​
 +export FSTYPE=ext2
 +
 +setup
 +</​code>​
 +
 +
 +===== Building =====
 +
 +==== Cross-compiling ====
 +
 +<​code>​
 +git clone git://​git.minix3.org/​minix.git minix
 +
 +cd minix
 +
 +sh build.sh -m i386 distribution
 +</​code>​
 +
 +
 +===== Packages =====
 +
 +==== How to create a package repository ====
 +
 +  - Build the packages you want in pkgsrc.
 +  - Find and enter into the repository (in ///​usr/​pkgsrc/​packages/​[release]/​[architecture]/​All//​).
 +  - Run the following in each //​[architecture]/​All//​ directory:
 +<​code>​
 +# pkg_info -X *.tgz | gzip > pkg_summary.gz
 +# pkg_info -X *.tgz | bzip2 > pkg_summary.bz2
 +</​code>​
 +  - Copy the //​packages//​ directory recursively,​ with symbolic-links,​ to its destination.
 +  - Point //pkg_add// or //pkgin// at the repository. See their manual pages for details.
 +
 + //​Voilà!//​ Your repository should now be up and running.
 +
 +
 +===== Virtual machines =====
 +
 +==== Using Qemu on Windows 7 ====
 +
 +Sometimes I need a virtual machine system that doesn'​t install anything. This means no installer, no kernel modules, and no virtual network adapter.
 +
 +For this I use "​Qemu-0.15.1-windows-Medium.zip,"​ from Eric Lassauge'​s [[http://​lassauge.free.fr/​qemu/​release/​|Qemu release directory]]. This has everything required by the [[:​usersguide:​runningonqemu|Qemu tutorial]].
 +
 +
 +==== How make NE2000 work in Bochs on Windows 7 ====
 +
 +On Windows 7, [[http://​bochs.sourceforge.net/​|Bochs]] 2.5.1 emulates the NE2000 network adapter. By default, its settings are incompatible with MINIX. While I didn't get it working, here's how I got it recognized by MINIX.
 +
 +In Bochs, I opened "​networking,"​ enabled the NE2000, and set it to use I/O address 0x300 and interrupt (or IRQ) 5.
 +
 +In MINIX, I edited...
 +
 +  - ///​bin/​netconf//:<​code>​
 + 3) driver=dp8390; ​ driverargs="​dp8390_0_arg='​DPETH0=300:​5'"​
 +</​code>​ \\ (The ":​5"​ refers to IRQ 5.)
 +  - //​system.conf//​ for "​dp8390":<​code>​
 + irq 5;
 +
 + io 0x300:20;
 +</​code>​ \\ (Here, the ":​20"​ is the number of ports to use. This is probably unrelated to how //DPETH0// works.)
 +
 +Upon start-up I see:
 +
 +<​code>​
 +dp8390#0: NE2000 at 300:5
 +</​code>​
 +
 +This is great, but next I'd have to get Bochs integrated with Windows'​ networking. I found out that Qemu does this far better, so I'll be using that instead.
 +
 +==== Pasting From MINIX ====
 +
 +Need to paste something from MINIX to a [[http://​en.wikipedia.org/​wiki/​Pastebin|pastebin]] site?
 +
 +1. Install Python
 +
 +<​code>​
 +pkgin search python
 +
 +pkgin install pythonNN (python24, python25, python27, etc.)
 +
 +ln -s /​usr/​pkg/​bin/​pythonN.N /​usr/​pkg/​bin/​python
 +</​code>​
 +
 +2. Install the Python Setuptools
 +
 +<​code>​
 +cd /​usr/​pkgsrc/​devel/​py-setuptools
 +
 +bmake bin-install
 +</​code>​
 +
 +3. Install Dpaster
 +
 +<​code>​
 +cd ~
 +
 +git clone git://​github.com/​zodman/​dpaster.git dpaster
 +
 +cd dpaster
 +
 +python setup.py install
 +</​code>​
 +
 +4. Use it
 +
 +<​code>​
 +cat something.txt | dpaster paste
 +</​code>​
 +
 +5. Open it
 +
 +A URL will appear. Type it into a Web browser, and then press Enter.
users/pikpik/notes.txt · Last modified: 2014/11/12 10:32 by lionelsambuc