OT: Tales of future past: the bluray BD-RE (rewritable) for data storage

Discussion in 'Professional Video Production' started by Jan Panteltje, Aug 27, 2012.

  1. I use bluray BD-RE (rewritable) for data storage,
    where data storage of course includes multimedia, and software.


    Whenever you look at 'how it is done' you see the ISO9660 filesystem.
    I do not particularly like that filesystem, all its changes over time, its structure etc.
    I have hundreds of normal DVDs with ISO9660 data made with mkisofs program.

    Linux has many good filesystems, so why should I use ISO9660?

    On normal DVD+R if I have a movie (recorded from satellite for example),
    I just burn it as image:
    growisofs -Z /dev/dvd=movie.ts

    And then you can get it back to disk later with:
    cp /dev/dvd ./movie.ts

    So far so good, no authoring crap needed.

    But with the the blurays 25 GB minimum size, one can have more than 1 movie,
    so we need some filesystem.

    This will show you how to create a reiser filesystem on a bluray .iso (image) file,
    add files to it until it is full,
    and then burn it to a bluray disk.

    It should work with ANY other Linux filesystem, ext2 ext3, whatever too,
    just change the relevant line.

    Although it will not play in one of those Hollywood crippled bluray boxes
    that you connect to a TV with HDMI,
    it will mount in Linux, if it has a bluray player.


    # For a 25 GB size BD-RE

    # create a disk image
    dd if=/dev/zero bs=1000000000 count=25 > bluray.iso

    # create a filesystem (reiserfs here), use mke2fs for ext2, etc, avoid any Microsoft copyrighted stuff, FREEDOM!
    mkreiserfs -f bluray.iso

    # mount the image
    mount -o loop=/dev/loop0 bluray.iso /mnt/loop

    # copy all files in current directory to the image (recursive -r should work too)
    cp -p * /mnt/loop/

    # unmount the image
    umount /dev/loop0

    # burn the image
    growisofs -overburn -Z /dev/dvd=bluray.iso

    # verify the burned disk against the image
    dvdimagecmp -a bluray.iso -b /dev/dvd
    #>count=24219779072 (24219.78MB), speed=218104kbps (19.EOF found in file2 at 24220008448
    #>Ready, 24220008448 bytes read, 0 errors found, 0 defective blocks
    # Strange Mr Verbatim, it says 25 GB on the box?

    # store disk

    # days pass, weeks, years, store disks in a DARK!!!!!!!! place (I use alu case).

    # get it back, and mount it again:
    mount /dev/dvd /mnt/dvd
    #>/dev/sr0 24413308 23322696 1090612 96% /mnt/dvd

    # let's see:
    mount
    #>/dev/sr0 on /mnt/dvd type reiserfs (rw)

    # go there
    cd /mnt/dvd

    # all your files are here
    ls -rtla
    #>-rw-r--r-- 1 root root 5211180836 Jul 15 02:09 cant_tel_ye.ts
    #>-rw-r--r-- 1 root root 6474147352 Jul 20 22:48 oops_hollywood_sucks.ts
    #>-rw-r--r-- 1 root root 3493260336 Jul 22 00:30 not_at_total_secret.ts
    #>-rw-r--r-- 1 root root 4788239868 Jul 24 15:30 the_end_of_hollywood.ts
    #>drwxr-xr-x 27 root root 680 Aug 26 20:27 ../
    #>-rw-r--r-- 1 root root 3858276316 Aug 27 11:58 a3_hd_with_sound.avi

    # How much data we have?
    /mnt/dvd # du
    #>23289428


    # Hey fun!






    F*CK you Hollywood.
    I won't buy one of your stinking crippled boxes.
    I won't use your dictated filesystems
    Keep your bloat



    FAQ:
    This is all based on the fact that in Unix everything is a file.
    Even a filesystem can be o na file.

    mkisofs? Where is it?
    No need for it whatsoever.

    Rockridge? Joliet? file size limitations? Copyrights?
    No

    So how do I play these saved files on my TeaFee?
    Insert USB stcik
    mount /dev/sdd1 /mnt/sdd1
    cp /mnt/dvd/the_end_of_hollywood.ts /mnt/sdd1/
    umount /dev/sdd1

    Stick in my Samsung 3D TV
    select media play
    play.
     
    Jan Panteltje, Aug 27, 2012
    #1
    1. Advertisements

  2. Jan Panteltje

    jdd Guest

    Le 27/08/2012 14:22, Jan Panteltje a écrit :
    yes and loop mounting is extremely handy

    you can use any linux filesystem in the loop mounted file (I would
    prefere ext2 against reiser, because we do not need a journal and
    reiser is not cleanly maintained. ext2 will be supported forever :)

    jdd
     
    jdd, Aug 27, 2012
    #2
    1. Advertisements

  3. Yes.
    Actually you can directly write to a bluray-BE in Linux,
    but a good reason for doing it the way I described is speed.
    You can just fill your loop file with files at normal speed,
    and when full burn the image to the disk.
    The burning could then be done overnight,
    as it takes some hours on very large disks.
     
    Jan Panteltje, Aug 27, 2012
    #3
  4. Jan Panteltje

    jdd Guest

    Le 27/08/2012 14:53, Jan Panteltje a écrit :
    if you use the joerg cdrecord (not wodim), it's extremely fast (around
    30 minutes max for 25Go)

    jdd
     
    jdd, Aug 27, 2012
    #4
  5. That seems to be some sort of commercial effort?
    I could not get it to work.
    In any case you can simply use the copy command:
    cp bluray.iso /dev/dvd

    It is not so fast, but not slower than growsiofs here...
    And 'dd' should work too, and gives you more control,
    as 'cp' will ditch the last file if it runs out of space it seems,
    just tried that.
    I would think that 'dd' with the correct size would be safer.
     
    Jan Panteltje, Aug 27, 2012
    #5
  6. Jan Panteltje

    jdd Guest

    Le 27/08/2012 20:13, Jan Panteltje a écrit :
    not tried. I use cdrecord dev=x,y,z /.../bd.iso

    http://cdrecord.berlios.de/private/cdrecord.html

    jdd
     
    jdd, Aug 27, 2012
    #6
  7. Yes, Ok, I remember cdrecord from the CD days (dao etc),
    but all that is no longer needed in recent kernels,
    dd is probably the best way.
    dd if=bd.iso of=/dev/dvd

    That inheritance and false 'needed' must go!
     
    Jan Panteltje, Aug 28, 2012
    #7
  8. Jan Panteltje

    jdd Guest

    Le 28/08/2012 10:25, Jan Panteltje a écrit :
    how do you manage the burnfree options?

    jdd
     
    jdd, Aug 28, 2012
    #8
  9. I tried today with 'cp', it works but is slow,
    did not wait for it to finish.
    I am back to growisofs, works for me.

    I think as long as you get no buffer underrun there is no problem with any method.
    In DVD+ you can pause a burn with ctrl Z, the format allows that.
    I have not tried to pause in bluray, probably will cause errors?
    May try that tomorrow :)
     
    Jan Panteltje, Aug 28, 2012
    #9
  10. Ok, some follow up, this is how it seems to go here.
    To *format* the BD-RE you need growisofs or cdrecord,
    I managed to burn a BD-RE with cdrecord too now.
    But once formatted, you can just put in the disk and make a filesystem on it:
    mkreiserfs /dev/dvd

    Mount it:
    mount /dev/dvd /mnt/dvd


    And then I copied a 4363448494 bytes (4.36 GB) file to that BD-RE with dd:
    dd if=/mnt/sda1/video/movies/avi-hd/0bamas-birth-in-kenia-hd.avi | pv -n -s 4363448494 > /mnt/dvd/

    As you can see I ran it through the 'pv' program, 'progress view', is shows the percentage that way, very useful in pipes.
    Then at 39 % transfer I typed control Z, stopping the transfer, and waited 5 minutes.
    The drive STOPPED.
    5 minutes later I typed 'fg' and its started running again
    Then when finished I ran 'diff' on the source and the destination files, NO DIFFERENCE.
    So I think it is safe to say Linux handles all that 'burnfree' or whatever, as I also did this
    with 100% load from some h264 encoding in an other xterm the same time.

    The only thing with using 'dd' is that you cannot set burn speed, and it clocked in slightly? slower than 1x
    So I use growisofs as it allows me to set speed (as does cdrecord). Ultimately speed is set by your system.
    This is all with a LG bluray burner.
    I am happy as from the test it seems I do not have to worry about buffer underruns.
    Sorry for the late reply, bit busy here, but now Saturday afternoon had some time to have a good look.
     
    Jan Panteltje, Sep 1, 2012
    #10
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.