![](https://seccdn.libravatar.org/avatar/0d0434a1c7ca43ef1a88fee5ecda1edf.jpg?s=120&d=mm&r=g)
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Carlos E. R. wrote:
Hi,
I use the following sequence to burn dvds, in a script:
time growisofs -Z /dev/dvd=IMAGEFILE -dvd-compat -speed=8 sleep 5
echo Ejecting eject /dev/dvd
sleep 5 ls -l /dev/hdc file -s /dev/hdc sleep 1 file -s /dev/hdc
echo Comparing... time nice cmp --bytes=$(wc -c <IMAGEFILE) /dev/hdc IMAGEFILE date
And some times, not always, I see this output (the marked line):
[...] Ejecting brw-rw----+ 1 root disk 22, 0 2009-03-13 03:55 /dev/hdc couldn't open file /dev/hdc: writable, no read permission <======== THIS == /dev/hdc: LUKS encrypted file, ver 1 [aes, cbc-essiv:sha256, sha1] UUID: d6367de2-9ecd-4e74-85d3-6acc8e6 Comparing...
I explain. First, I burn the image. Then, I eject the dvd, to force the kernel to reread it (k3b does the same). Then, I compare the image with the just burned dvd, but in order to avoid the random error, I first run "file -s /dev/dvd", which makes the burner to close the door.
The curious thing is that, on some runs, the first attempt to read the dvd fails with the message:
/dev/hdc: writable, no read permission
which is not true, because the permissions, read just before, are:
brw-rw----+ 1 root disk 22, 0 2009-03-13 03:55 /dev/hdc
and the second attempt succeeds. That's why I run the "file" command before the "cmp", so that the cmp succeeds (ie, previously I got the same error on the cmp).
And it doesn't happen every day, just some times. If it happened every time, I'd think it could be the door closing and the system attempting to load the dvd. And it did not happen several months ago, with 10.3.
Curious, isn't it?
(running 11.0; gnome; stock install plus mandatory and recommended updates)
-- Cheers, Carlos E. R.
I have found that some checking of the output from wodim and growisofs allows the handling of time out and other transient errors. Bash is not really up to this kind of checking, it can be done but it is better to use something which is built for the job, I have a Perl module under development which encapsulates handling of some (but not all) the problems of this nature that I have encountered over time. I have not dealt with encrypted DVDs so there might be some special gotchas with that element. - -- ============================================================================== I have always wished that my computer would be as easy to use as my telephone. My wish has come true. I no longer know how to use my telephone. Bjarne Stroustrup ============================================================================== -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org iEYEARECAAYFAknAvdQACgkQasN0sSnLmgIewQCguPwuGeMzZoAaXCdkz/yEw7S0 9AYAoPU6INSMExMyK65AQg+oEy0PkDb2 =mkw3 -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org