Bug 106007

Summary: file ideintifier not functional
Product: [openSUSE] SUSE LINUX 10.0 Reporter: Gábor Sári <sari.gabor>
Component: BasesystemAssignee: Vladimir Nadvornik <nadvornik>
Status: RESOLVED WORKSFORME QA Contact: E-mail List <qa-bugs>
Severity: Major    
Priority: P5 - None CC: snwint, werner
Version: Beta 2   
Target Milestone: ---   
Hardware: Other   
OS: All   
Whiteboard:
Found By: Other Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: from file-4.14-2.i586.rpm from 10.0 beta2

Description Gábor Sári 2005-08-20 14:39:58 UTC
openSUSE beta2 
 
Creating the iso file these commands:  
  
mkisofs -v -V SU100OSS.001 -r -J -l -L -P "SuSE Linux AG" \  
    -b "boot/loader/isolinux.bin" -c "boot/loader/boot.cat" -no-emul-boot \  
    -boot-load-size 4 -boot-info-table -graft-points -o \  
    ../iso.iso .  
  
The file command say this:  
  
yellow:/ # file iso.iso  
iso.iso:  
  
And checkmedia say this:  
  
yellow: # checkmedia iso.iso  
not an iso
Comment 1 Danny Al-Gaaf 2005-08-20 16:53:45 UTC
please report openSUSE bugs against SUSE 10.0 not against the wiki. see http://
www.opensuse.org/index.php/Submit_a_bug
Comment 2 Vladimir Nadvornik 2005-08-22 12:03:53 UTC
The problem with file command is probably some conflict in magic file.
If I remove everything except this from the magic file, it work OK:

# CDROM Filesystems
32769    string    CD001     ISO 9660 CD-ROM filesystem data
# "application id" which appears to be used as a volume label
>32808   string    >\0       '%s'
>34816   string    \000CD001\001EL\ TORITO\ SPECIFICATION    (bootable)
37633    string    CD001     ISO 9660 CD-ROM filesystem data (raw 2352 byte sectors)
32776    string    CDROM     High Sierra CD-ROM filesystem data


>file -m mymagic iso.iso 
iso.iso: ISO 9660 CD-ROM filesystem data 'SU100OSS.001                   '
(bootable)

Werner, can you please look into this?

Checkmedia works for me. Can you please attach strace output?
strace -o traceoutput checkmedia iso.iso 
Comment 3 Dr. Werner Fink 2005-08-22 12:37:17 UTC
If there is an output of the file command in the report (hopefully not
deleted) I'd like to see this.
Comment 4 Dr. Werner Fink 2005-08-22 12:42:35 UTC
Btw: what does

        file -k iso.iso

report?  The option -k force file not to
stop on the first report but keep going.
Comment 5 Vladimir Nadvornik 2005-08-22 13:03:17 UTC
There is no other output from file iso.iso. Strace shows this:
write(1, "iso.iso: \n", 10)


> file -k iso.iso
iso.iso: \012- ISO 9660 CD-ROM filesystem data 'SU100OSS.001                   '
(bootable)

strace shows:
write(1, "iso.iso: \\012- ISO 9660 CD-ROM f"..., 92) = 92
Comment 6 Dr. Werner Fink 2005-08-22 14:38:08 UTC
Hmmm ... 012 is newline.  What character is the first of the image?
Comment 7 Dr. Werner Fink 2005-08-22 14:42:47 UTC
Btw: I can not remove all entries im the magic file which uses
characters before the offset 32769 ... IMHO you should use
the `-k' option of file ... and Steffen may change the program
checkmedia.  Btw: there is no manual page for checkmedia nor
tagmedia.
Comment 8 Steffen Winterfeldt 2005-08-22 14:53:16 UTC
No, but both have '--help' and there is a README in the doc directory. 
 
checkmedia is ok; the 'no iso' message basically means the file has a size of 
less than about 33k. 
Comment 9 Vladimir Nadvornik 2005-08-22 15:01:53 UTC
The image starts with 32k of zeros. IMHO this should not match anything.

'no iso' is printed even if the file does not exist. I'd guess that this
is the case here, let's wait for strace output.







Comment 10 Dr. Werner Fink 2005-08-22 15:14:32 UTC
IMHO this could be a file shortage
Comment 11 Vladimir Nadvornik 2005-08-23 08:42:50 UTC
The problem is in magic file at line 2933. It contains:
0       long    0
Comment 12 Dr. Werner Fink 2005-08-23 10:12:10 UTC
From which /usr/share/misc/magic do you talk about?
Please attach this file because if I do a

   /suse/werner> grep -E '^0[[:space:]]+long[[:space:]]+0' /usr/share/misc/magic

I do not get such a line.
Comment 13 Vladimir Nadvornik 2005-08-23 10:42:14 UTC
Created attachment 47164 [details]
from file-4.14-2.i586.rpm from 10.0 beta2
Comment 14 Dr. Werner Fink 2005-08-23 11:03:06 UTC
Args ... this is a BUG in the magic description of the cracklib.
Compare with /usr/share/cracklib/cracklib.magic

Thorsten? Please provide a corrected magic entry. The line

0    long    0

is broken
Comment 15 Thorsten Kukuk 2005-08-23 11:45:49 UTC
Use this one:

# cracklib:  file (1) magic for cracklib v2.7
0       lelong  0x70775631      Cracklib password index, little endian
>4      long    >0              (%i words)
0       belong  0x70775631      Cracklib password index, big endian
>4      long    >0              (%i words)


This does not detect old, broken 64bit index files, but since I don't
have one for testing, I cannot fix that. New submitted cracklib contains a fixed
one, too.
Comment 16 Thorsten Kukuk 2005-08-23 11:59:53 UTC
A better version:

0       lelong  0x70775631      Cracklib password index, little endian
>4      lelong  >0              (%i words)
0       belong  0x70775631      Cracklib password index, big endian
>4      belong  >0              (%i words)
Comment 17 Dr. Werner Fink 2005-08-23 12:03:15 UTC
OK, I've put a new file package with a corrected magic entrie for cracklib.
Thanks to Thorsten.
Comment 18 Vladimir Nadvornik 2005-08-23 12:34:20 UTC
There still may be bug in checkmedia or mkisofs. Please reopen this bug
and attach strace output if you can reproduce it.
Comment 19 Dr. Werner Fink 2005-08-23 12:35:43 UTC
Reopen to brake down the bug in checkmedia or mkisofs
Comment 20 Dr. Werner Fink 2005-08-23 12:37:44 UTC
Gábor?  We need more information about the bug.  E.g. the strace
output of mkisofs and checkmedia.
Comment 21 Vladimir Nadvornik 2005-09-27 16:10:25 UTC
no info on checkmedia or mkisofs bug -> worksforme