(My appologies for late answer.) From: "Jason Gunthorpe" <[EMAIL PROTECTED]> > > I had not experienced such problems in Potato with Potato's apt. Everything > > worked fine. > > It is possible that the volume-identification scheme has been broken by a > newer kernel. There is no difference in the CD handling from potato to > woody. > > Try using the Debug::Acquire::cdrom option to see what idents are being > calculated for the CD.
I've tried it. Yes, apt calculates different IDs on the same CD. This is the log of conversation between apt-get and me. Options "Debug::IdentCdrom" and "Debug::Acquire::Cdrom" set to "true" in apt.conf. === begin === lynxer:~# apt-get install colorgcc Reading Package Lists... Done Building Dependency Tree... Done The following NEW packages will be installed: colorgcc 0 packages upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 0B/8804B of archives. After unpacking 81.9kB will be used. 0% [Working]ID 2 d41d8cd98f00b204e9800998ecf8427e-2.debug ID 1 d41d8cd98f00b204e9800998ecf8427e-1.debug Media Change: Please insert the disc labeled 'Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-2 (20020718)' in the drive '/cdrom/' and press enter 0% [Working]ID 2 d322ef71d5c244fef82cb140072fee83-2.debug ID 1 241399ecfca04a7ee3c9a399aa6b142e-1.debug Media Change: Please insert the disc labeled 'Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-2 (20020718)' in the drive '/cdrom/' and press enter 0% [Working]ID 2 2f3fcd9cec45e290f5e67a8b27d9be31-2.debug ID 1 1c9d2b50f5646a518a3f45763bbd6997-1.debug Media Change: Please insert the disc labeled 'Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-2 (20020718)' in the drive '/cdrom/' and press enter (pressing Ctrl-C) === end === As you see, IDs calculated are different in all cases (except for ID 1 and ID 2 from the first try, when CD is probably not mounted). "apt-cdrom ident" also reports different IDs on defferent runs. Luckily, I have access (though it is technically hard) to that old machine with Potato on which apt sources from smb CD-ROMs work fine. It runs kernel 2.0.38. I've downloaded apt sources of Potato and Woody versions and made some diffs, you are right, CD handling is not changed, except for fixing typo "umount" to "mount". My current machine (on which I experience problems) runs vanilla kernel 2.2.20 from Debian Woody distribution. So, your assumption about kernel behaviour changing seems to be true. What can I do now? (I need to access apt smb-cdrom sources?) Should I try to write a patch myself or you better do it yourself? I have an idea how to do it. I beleive IdentCdrom() function from the file cdromutl.cc needs to be changed, namely "for (struct dirent *Dir = readdir(D); Dir != 0; Dir = readdir(D))" loop. There is a comment that says that directory entries might go in different orders on different directory readings, so let's make the order persistent. To do this, let's read the entire directory listing (names) into std::map <std::string entry_name, unsigned long entry_mtime> ourmap and run the second cycle from ourmap.begin() to ourmap.end(), adding the correspondent values to Hash variable. The second idea is to add the contents of [cdrom]/.disk/info file to the unique string that forms md5 sum later. Regards, Alexei.

