From: Bill C. R. <do...@fr...> - 2009-03-02 04:46:11
|
I spent a number of hours this weekend attempting to get Anaconda to work with coLinux. coLinux has come a long way, and even the Live CD almost works. I would like to briefly describe some of the problems I found, some of the solutions, and where I am stuck right now. The biggest problem I've had so far is debugging. I can find no way to scroll in the console window. So tracebacks, and errors quickly appear on the screen and disappear. Is there anyway to redirect the console output to a log file or such? If so, it would make life much easier. For now, I've just been entering print statements in code, and sleep commands to give me time to read the output. It doesn't always tell me where it crashed, but it does help me figure out where it didn't crash. The first problem I found is anaconda needs the driver modules. I found simply appending the modules to the initrd.img file works just fine to fix this: gunzip -c initrd.img > initrd.cpio tar xfz vmlinux-modules.tar.gz find lib/modules |cpio -o -H newc -A -F initrd.cpio gzip -c initrd.cpio > initrd.img The first code problem I found is the capacity for cobd devices is listed as 16. As none removable devices, anaconda expect the size value to be valid. However, the size is always read as 0, so anaconda skip past the devices. On a hunch, I added a open command into the code, and found once a cobd device has been opened, the size value is nolonger 0, so anaconda will recognize it. So the solution is coLinux either needs to mark all cobd devices as removable, or it needs to initialize the size parameter. The next problem I came across is that anaconda expects CD's to have the cd capacity set. Since coLinux treats all cobd devices the same, none are marked as CD. So again, I did a quick hack and modified my build of anaconda to consider all coLinux devices as both CD's and hard disks. Next, for some reason NetManager in the initrd.img is unable to initialize the network for slirp network, even when I explicitly specify the networking parameters. I've had similar problems in the past with qemu, and managed to get around it by using a different networking setup. I will try the same for coLinux, but for now this problem stopped me dead in my tracks. Now, you might think as I did, that we don't need networking. Just specify an ISO image and install from that. However, the problem is the only headless option for anaconda is to use vnc. But in order to use vnc, we need networking. Otherwise anaconda consistently crashes trying to set-up graphical display. I am not certain that having networking, and thus vnc will avoid this crash, but I am certain it can not work without networking for a headless install. The last sticker is going to be the partitioning. In that there seems to be no capacity in anaconda to deal with hard disks of type 16. However, once I get past the networking problem I will try and add this capability to anaconda. Any insight others have, especially in the NetworkManager problem and how to debug this code would be greatly appreciated. Bill |
From: Bill C. R. <do...@fr...> - 2009-03-02 23:46:49
|
As a follow-up, I figured out a better way to debug and traced the problem in NetworkManager. It occurred to me I could run anaconda in a chroot environment. It seems that NetworkManager will ignore any device without an associated driver. e.g. an info.linux.driver entry for the net.originating_device. I will try patching NetworkManager to by-pass this limitation, and see where that gets us. Bill On Sun, Mar 1, 2009 at 11:46 PM, Bill C. Riemers <do...@fr...> wrote: > I spent a number of hours this weekend attempting to get Anaconda to > work with coLinux. coLinux has come a long way, and even the Live CD > almost works. I would like to briefly describe some of the problems I > found, some of the solutions, and where I am stuck right now. > > The biggest problem I've had so far is debugging. I can find no way > to scroll in the console window. So tracebacks, and errors quickly > appear on the screen and disappear. Is there anyway to redirect the > console output to a log file or such? If so, it would make life much > easier. For now, I've just been entering print statements in code, > and sleep commands to give me time to read the output. It doesn't > always tell me where it crashed, but it does help me figure out where > it didn't crash. > > The first problem I found is anaconda needs the driver modules. I > found simply appending the modules to the initrd.img file works just > fine to fix this: > gunzip -c initrd.img > initrd.cpio > tar xfz vmlinux-modules.tar.gz > find lib/modules |cpio -o -H newc -A -F initrd.cpio > gzip -c initrd.cpio > initrd.img > > The first code problem I found is the capacity for cobd devices is > listed as 16. As none removable devices, anaconda expect the size > value to be valid. However, the size is always read as 0, so anaconda > skip past the devices. On a hunch, I added a open command into the > code, and found once a cobd device has been opened, the size value is > nolonger 0, so anaconda will recognize it. So the solution is coLinux > either needs to mark all cobd devices as removable, or it needs to > initialize the size parameter. > > The next problem I came across is that anaconda expects CD's to have > the cd capacity set. Since coLinux treats all cobd devices the same, > none are marked as CD. So again, I did a quick hack and modified my > build of anaconda to consider all coLinux devices as both CD's and > hard disks. > > Next, for some reason NetManager in the initrd.img is unable to > initialize the network for slirp network, even when I explicitly > specify the networking parameters. I've had similar problems in the > past with qemu, and managed to get around it by using a different > networking setup. I will try the same for coLinux, but for now this > problem stopped me dead in my tracks. > > Now, you might think as I did, that we don't need networking. Just > specify an ISO image and install from that. However, the problem is > the only headless option for anaconda is to use vnc. But in order to > use vnc, we need networking. Otherwise anaconda consistently crashes > trying to set-up graphical display. I am not certain that having > networking, and thus vnc will avoid this crash, but I am certain it > can not work without networking for a headless install. > > The last sticker is going to be the partitioning. In that there seems > to be no capacity in anaconda to deal with hard disks of type 16. > However, once I get past the networking problem I will try and add > this capability to anaconda. > > Any insight others have, especially in the NetworkManager problem and > how to debug this code would be greatly appreciated. > > Bill > |
From: Henry N. <hen...@ar...> - 2009-03-04 00:36:27
|
Hello Bill, Bill C. Riemers wrote: > The first code problem I found is the capacity for cobd devices is > listed as 16. As none removable devices, anaconda expect the size > value to be valid. However, the size is always read as 0, so anaconda > skip past the devices. On a hunch, I added a open command into the > code, and found once a cobd device has been opened, the size value is > nolonger 0, so anaconda will recognize it. So the solution is coLinux > either needs to mark all cobd devices as removable, or it needs to > initialize the size parameter. Please try the devel version 0.8.0 from snapshot page. The size problem should not exist with the scsi driver. This type of driver allows partition tables and give the installer the exactly size from image file. An example for config: scsi0=disk,file.img You can add a size parameter to create empty disk images. But be carefully, it can shrink the size (and delete) existing images. For example to create a 1GB image: scsi0=disk,file.img,1073741824 In the installer (Anaconda) than you need to create a partition. > The next problem I came across is that anaconda expects CD's to have > the cd capacity set. Since coLinux treats all cobd devices the same, > none are marked as CD. So again, I did a quick hack and modified my > build of anaconda to consider all coLinux devices as both CD's and > hard disks. In the devel version exist scsi for cdrom support. This works also with mostly installers. An example for config: scsi1=cdrom,file.iso All parameters you will find in colinux-daemon.txt after installing coLinux, or in the SVN: http://colinux.svn.sourceforge.net/viewvc/colinux/branches/devel/doc/colinux-daemon -- Henry N. |
From: Henry N. <hen...@ar...> - 2009-03-04 21:45:52
|
Henry Nestler wrote: > You can add a size parameter to create empty disk images. But be > carefully, it can shrink the size (and delete) existing images. For > example to create a 1GB image: > scsi0=disk,file.img,1073741824 The size should give in megabytes, not in bytes. The right example with 1GB is: scsi0=disk,file.img,1024 -- Henry N. |
From: Henry N. <hen...@ar...> - 2009-03-15 21:14:50
|
Hello Bill, At 05.03.2009 00:55, wrote Doctor Bill: > Looks like it is not timing errors. With local file, the SCSI driver > is consistently bombing at about 27%. That is pretty close to the > 1GiB boundary, so if there is any math performed on this position > value, it could be integer overflow. > > Bill you are right with problems near 1GB limit. I have configured a 3.1GB iso image file and also have tested as cdrom directly. Both stops reading after 1073741312 (0x3FFFFE00) bytes. Configured as scsi1=cdrom,C:\Fedora.iso or scsi1=cdrom,\Device\Cdrom0 Inside coLinux: debian:~# dd if=/dev/sr0 | md5sum d2546596e7b2378388c14c0cff6a8fe1 - 2097151+0 records in 2097151+0 records out 1073741312 bytes (1.1 GB) copied, 216.493 seconds, 5.0 MB/s My idea was to check corrupted data between the iso-file and the sr0-device driver. But it fails before it was finish. This error will be find. -- Henry N. |
From: Henry N. <hen...@ar...> - 2009-03-28 23:07:48
|
Am 04.03.2009 16:49, schrieb Bill C. Riemers: > On Tue, Mar 3, 2009 at 7:37 PM, Henry Nestler<hen...@ar...> wrote: > Cool. These look like exactly the features needed. However, the > SCSI driver is giving lots of errors. The command > > $ ./colinux-daemon.exe kernel=vmlinux initrd=initrd.cpio.gz mem=256 > eth0=slirp,,tcp:5902:5900 scsi1=cdrom,$(cygpath -wa > //cisco1.local/share/Download/images/Fedora-10-i386-DVD.iso) > scsi0=disk,test.img,4000000000 > > correctly finds CDROM, but validation tests always fail. I've made > it as far as 27% before erroring out. Using my hacked version of > anaconda, I find the cobd devices work as expected: > > $ ./colinux-daemon.exe kernel=vmlinux initrd=initrd.cpio.gz mem=256 > eth0=slirp,,tcp:5902:5900 cobd1=$(cygpath -wa > //cisco1.local/share/Download/images/Fedora-10-i386-DVD.iso) > scsi0=disk,test.img,4000000000 > > I can even get as far as partitioning in text mode, but I see lots of > errors, and there are no recognized disks. Errors like "ERROR; ddf1. > seeking device /dev/sda to 18446744073709551104". > > I thought maybe this was an integer overflow problem, but reducing the > size of scsi0 does not seem to help. Is fixed in SVN revision r1239. Please use todays snapshot. It was an unsupported GFP_DMA inside function get_sectorsize. So the sr driver falls back to "capacity = 0x1fffff". I have checked the Fedora 10 DVD image inside coLinux and all is ok now. :-) debian:~# dd if=/dev/sr0 | sha1sum 086fd570518ac58d3966c43c1b6d146e38919d8d - 7153464+0 records in 7153464+0 records out 3662573568 bytes (3.7 GB) copied, 604.809 seconds, 6.1 MB/s The DVD was configured in colinux config file as: scsi1=cdrom,\Device\Cdrom0 -- Henry N. |