Find the answer to your Linux question:
Results 1 to 1 of 1
Back in the days of Unix, there was a file named "/etc/magic" which contained the known file layouts used with the "file" command. It worked FINE and anyone who wanted ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Aug 2006
    Posts
    2

    MAGIC file


    Back in the days of Unix, there was a file named "/etc/magic" which contained the known file layouts used with the "file" command. It worked FINE and anyone who wanted to add a file type need only understand the format and ID tools and he could add the file.

    Then, one day, in Linux, it became "/usr/share/magic" which is a COMPILED file from sources that are ..... wait for it .... NOT INCLUDED in the basic distribution (at least from Red Hat) and equally hard to find on the net.

    One option of course, is to rewrite all your scripts and retrain all your users to use the "-f /usr/share/magic.txt" command when using "file" command. Or better yet, change the NAME of "magic.mgc" to something else and then "file" will use the TEXTFILE version that IS supplied .....

    THEN all you have to do is rewrite all your scripts to redirect that pointless "Danger Will Robinson!" warning about using a "regular" file!

    All this .... just because someone changed the "magic" file and the "file" command from something that worked just fine.

    10% chance that they did this for an important reason
    90% chance that the reason is about as important as what Spock REALLY meant in scene 3 of episode 12

    I once had a belief that the purpose of Linux was so that I could do what *I* wanted to do .. and not have other people decide how it should be done.

    So my "suggestion" is: Please change it back to how it worked for us ... or include the source files and generation details.
    Last edited by dbdataplus; 08-04-2007 at 07:25 PM. Reason: forgot the last line!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •