Request for advise with mounting particular ISO 9660 sessions
Hi, looking over the system dependencies in our project i come to the xorriso mount helper. It reads the table-of-content of multi-session media or files and produces a mount command for mounting a particular session. Typically used to retrieve older states from multi-session backups. I read from the porting instructions that i shall assume userland to be like Linux. But this line is a bit obscure to me: Example of uname check: Linux|GNU|GNU/*) I could need an example of the string which uname(uts); returns as uts.sysname Currently recognized: FreeBSD and Linux. Another question is the mount command option by which one can address a non-default superblock in an ISO 9660 image. On Linux:mount -t iso9660 -o sbsector=... On FreeBSD: mount_cd9660 -s ... Given we have an ISO 9660 image with several sessions of which one starts at block number 122880, would this Linux shell command work for the superuser ? mount -t iso9660 \ -o nodev,noexec,nosuid,ro,sbsector=122880 \ /dev/cd0 /mnt On FreeBSD xorriso would issue this line mount_cd9660 -o noexec,nosuid -s 122880 \ /dev/cd0 /mnt PS: I am subscribed now. No need to Cc me any more. The following are test proposals for the case that my question cannot be answered flatly. The mount commands mount the last session on CD by default. The first session has block address 0. So at least this one is easy to find on any multi-session CD. Linux: -o sbsector=0 FreeBSD: -s 0 Typically you will see more files in the last session than in the first session. A multi-session CD-RW is traditionally produced by interaction of mkisofs and cdrecord. First session: mkisofs -graft-points \ /tree1=prepared_for_iso/tree1 | \ cdrecord -v dev=/dev/cd0 blank=fast -multi -eject - Follow-up session: m=$(cdrecord dev=/dev/cd0 -msinfo) mkisofs -graft-points -M /dev/cd0 -C $m \ /tree2=prepared_for_iso/tree2 | \ cdrecord -v dev=/dev/cd0 -waiti -multi -eject - mkisofs and cdrecord stand for the originals or for compatible programs like genisoimage, wodim, xorriso -as mkisofs, cdrskin. The Debian xorriso package can produce multi-session ISO images in disk files. For mount, this should make no difference. First session: xorriso -dev /tmp/image.iso -blank as_needed \ -map prepared_for_iso/tree1 /tree1 Follow-up session: xorriso -dev /tmp/image.iso \ -map prepared_for_iso/tree2 /tree2 Here the first session begins at block 32. At block 0 there is a superblock copy of the last session. (superblock means System Area plus Volume Descriptors. Usually 18 blocks.) When mounting sbsector=0 on CD resp. sbsector=32 in disk file you should only see /mnt/tree1. When mounting with no sbsector option you should see both, /mnt/tree1 and /mnt/tree2. Have a nice day :) Thomas -- To UNSUBSCRIBE, email to debian-bsd-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Re: Request for advise with mounting particular ISO 9660 sessions
I read from the porting instructions that i shall assume userland to be like Linux. Well, the kernel is the same as in FreeBSD, the libc is the same as in libc. Majority of userland is the same as Linux, but see bellow. But this line is a bit obscure to me: Example of uname check: Linux|GNU|GNU/*) I could need an example of the string which uname(uts); returns as uts.sysname Currently recognized: FreeBSD and Linux. salin...@asdfasdf:~$ uname -a GNU/kFreeBSD asdfasdf 7.2-1-amd64 #0 Tue Oct 6 23:17:13 UTC 2009 x86_64 amd64 AMD Sempron(tm) Processor 3000+ GNU/kFreeBSD salin...@asdfasdf:~$ uname -s GNU/kFreeBSD salin...@asdfasdf:~$ uname -o GNU/kFreeBSD Another question is the mount command option by which one can address a non-default superblock in an ISO 9660 image. On Linux:mount -t iso9660 -o sbsector=... On FreeBSD: mount_cd9660 -s ... Given we have an ISO 9660 image with several sessions of which one starts at block number 122880, would this Linux shell command work for the superuser ? mount -t iso9660 \ -o nodev,noexec,nosuid,ro,sbsector=122880 \ /dev/cd0 /mnt On FreeBSD xorriso would issue this line mount_cd9660 -o noexec,nosuid -s 122880 \ /dev/cd0 /mnt Use the FreeBSD one, as mount is just user friendly interface to kernel specific syscall. salin...@asdfasdf:~$ /sbin/mount_cd9660 -h /sbin/mount_cd9660: invalid option -- 'h' usage: mount_cd9660 [-begjrv] [-C charset] [-o options] [-s startsector] special node This command comes from freebsd-utils package, which is available (and essential) for both kfreebsd-i386 and kfreebsd-amd64, see http://packages.debian.org/sid/kfreebsd-amd64/freebsd-utils/filelist Thanks for your care about GNU/kFreeBSD. Petr -- To UNSUBSCRIBE, email to debian-bsd-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Request for advise with struct stat, ACL, xattr, zlib
Hi, looking over the system dependencies in our project i come to the xorriso mount helper. It reads the table-of-content of multi-session media or files and produces a mount command for mounting a particular session. Typically used to retrieve older states from multi-session backups. I read from the porting instructions that i shall assume userland to be like Linux. But this line is a bit obscure to me: Example of uname check: Linux|GNU|GNU/*) I could need an example of the string which uname(uts); returns as uts.sysname Currently recognized: FreeBSD and Linux. Another question is the mount command option by which one can address a non-default superblock in an ISO 9660 image. On Linux:mount -t iso9660 -o sbsector=... On FreeBSD: mount_cd9660 -s ... Given we have an ISO 9660 image with several sessions of which one starts at block number 122880, would this Linux shell command work for the superuser ? mount -t iso9660 \ -o nodev,noexec,nosuid,ro,sbsector=122880 \ /dev/cd0 /mnt On FreeBSD xorriso would issue this line mount_cd9660 -o noexec,nosuid -s 122880 \ /dev/cd0 /mnt PS: I am subscribed now. No need to Cc me any more. The following are test proposals for the case that my question cannot be answered flatly. The mount commands mount the last session on CD by default. The first session has block address 0. So at least this one is easy to find on any multi-session CD. Linux: -o sbsector=0 FreeBSD: -s 0 Typically you will see more files in the last session than in the first session. A multi-session CD-RW is traditionally produced by interaction of mkisofs and cdrecord. First session: mkisofs -graft-points \ /tree1=prepared_for_iso/tree1 | \ cdrecord -v dev=/dev/cd0 blank=fast -multi -eject - Follow-up session: m=$(cdrecord dev=/dev/cd0 -msinfo) mkisofs -graft-points -M /dev/cd0 -C $m \ /tree2=prepared_for_iso/tree2 | \ cdrecord -v dev=/dev/cd0 -waiti -multi -eject - mkisofs and cdrecord stand for the originals or for compatible programs like genisoimage, wodim, xorriso -as mkisofs, cdrskin. The Debian xorriso package can produce multi-session ISO images in disk files. For mount, this should make no difference. First session: xorriso -dev /tmp/image.iso -blank as_needed \ -map prepared_for_iso/tree1 /tree1 Follow-up session: xorriso -dev /tmp/image.iso \ -map prepared_for_iso/tree2 /tree2 Here the first session begins at block 32. At block 0 there is a superblock copy of the last session. (superblock means System Area plus Volume Descriptors. Usually 18 blocks.) When mounting sbsector=0 on CD resp. sbsector=32 in disk file you should only see /mnt/tree1. When mounting with no sbsector option you should see both, /mnt/tree1 and /mnt/tree2. Have a nice day :) Thomas -- To UNSUBSCRIBE, email to debian-bsd-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Request for advise with struct stat, ACL, xattr, zlib (2nd try)
Hi, Sorry for sending the same old mail again. It should have been this one: I had a look at the buildd logs of our libisofs https://buildd.debian.org/fetch.cgi?pkg=libisofs;ver=0.6.24-1;arch=kfreebsd-amd64;stamp=1255540287 https://buildd.debian.org/fetch.cgi?pkg=libisofs;ver=0.6.24-1;arch=kfreebsd-i386;stamp=1255540772 I am puzzled by this warning: libisofs/builder.c:209: warning: passing argument 2 of 'aaip_cleanout_st_mode' from incompatible pointer type Is stat.st_mode not of type mode_t ? The line in question is: aaip_cleanout_st_mode(a_text, (info.st_mode), 4 | 16); Argument number two is a component of struct stat info; The function prototype is int aaip_cleanout_st_mode(char *acl_text, mode_t *st_mode, int flag); Can somebody please have a look into sys/stat.h whether struct stat.st_mode is of different size than mode_t ? The warning appears on amd64 and on i386. Another unexplainable warning on both and also on Linux i386: libisofs/tree.c:917: warning: 'brk_info' may be used uninitialized in this function I see in http://bazaar.launchpad.net/%7Elibburnia-team/libisofs/scdbackup/annotate/head%3A/libisofs/tree.c line 917: char *ptr, *brk_info, *component; ... no goto , no open blocks ... component = strtok_r(ptr, /, brk_info); and understand from man 3 strtok_r that brk_info is to be initialized by that function. Looking into my local /usr/include/string.h brings no insight either. Does anybody have an idea what the compiler wants to tell me ? None of the optional libraries and system features is used in the buildd compile runs: - libacl - support for Extended Attributes - zlib At least on Linux this astonishes me. I'll have to ask George for exploring the reason. Nevertheless, the aspects of ACL and xattr are also porting issues. It might be that a Linux-centric configure test prevents the use of the prepared ACL adapter for FreeBSD even on the original system. checking sys/acl.h usability... no checking sys/acl.h presence... no checking for sys/acl.h... no Do the buildd machines have ACL support installed ? Are there any header files like sys/acl.h to include ? To test ACL on Debian kfreebsd would require a little hack in ./configure, an #ifdef __FreeBSD_kernel__, and somebody who has files with non-trivial ACLs. (The reward would be a backup engine which can record and restore ACLs in ISO images. The images are mountable but OS kernels show no ACLs in them.) Anybody bored enough to volunteer ? Are there Extended Attributes with any of the kfreebsd filesystems ? See on Linux: man 1 getfattr, setfattr. If yes, then i would have to de-Linuxify ./configure checking attr/xattr.h usability... no checking attr/xattr.h presence... no checking for attr/xattr.h... no and i would need documentation of functions like Linux man 2 listxattr, getxattr, removexattr, setxattr. The lack of zlib is a bit pity: checking zlib.h usability... no checking zlib.h presence... no checking for zlib.h... no as it would allow to write compressed files into the image on-the-fly. Is there zisofs support in the FreeBSD kernel ? (Linux can uncompress zisofs formatted files by its read-only isofs filesystem code. So one can mount ISO images with compressed files and sees them uncompressed.) There is also portable intransparent compression if zlib is available. This produces *.gz files inside the ISO image. You unpack them from mounted images by gunzip. Have a nice day :) Thomas -- To UNSUBSCRIBE, email to debian-bsd-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Re: Bootable USB images (Re: using d-i to install kfreebsd-i386 from usb)
On Mon, Dec 21, 2009 at 11:37:28PM +0100, Robert Millan wrote: On Thu, Dec 17, 2009 at 01:48:10PM +, Thorsten Glaser wrote: The standard (I have Ecma 119 (= ISO 9660), SUSP, RRIP and El Torito here as PDFs, they’re “freeware”) however specifies that the first 32 KiB of an ISO 9660 filesystem image are empty and available for, for example, bootloaders. I found this a very interesting observation. In fact I just implemented support in GRUB to build USB-capable CD images, using this approach. You just need to dd them: $ dd if=mini.iso of=/dev/sdb You will need 1.98~20091221-1 (which I just uploaded to sid), plus attached patch. This takes advantage of the new infrastructure for bootable image generation (grub-mkrescue), which abstracts the architecture-specific GRUB setup so that you only need to worry about your grub.cfg and not about image building. I have tried that, but it doesn't work. It works fine when used on a CD-ROM, but not when used on an hard-drive. The grub menu is shown correctly, but when selecting the install entry, it freezes on Loading When trying to boot using commands, it also freezes after entering kfreebsd /boot/kernel/kfreebsd.gz. -- Aurelien Jarno GPG: 1024D/F1BCDB73 aurel...@aurel32.net http://www.aurel32.net -- To UNSUBSCRIBE, email to debian-bsd-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#563122: RM: gcl [kfreebsd-amd64 kfreebsd-i386] -- NBS; needs porting
Package: ftp.debian.org Severity: normal Hi Please remove gcl for kfreebsd-* as they FTBFS and seem to need porting (buildsys-related?). Cheers Luk -- To UNSUBSCRIBE, email to debian-bsd-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org