Bash update cdrom status

Johnny Rosenberg gurus.knugum at gmail.com
Sun Nov 24 17:33:29 UTC 2013


2013/11/24 Colin Law <clanlaw at googlemail.com>

> On 24 November 2013 15:46, Johnny Rosenberg <gurus.knugum at gmail.com>
> wrote:
> > 2013/11/24 Colin Law <clanlaw at googlemail.com>
> >>
> >> On 24 November 2013 12:32, Johnny Rosenberg <gurus.knugum at gmail.com>
> >> wrote:
> >> > 2013/11/24 Colin Law <clanlaw at googlemail.com>
> >> >> ...
> >> >> What does the udisks command in your script show before and after
> >> >> blanking
> >> >> it?
> >> >
> >> >
> >> > They showed the same thing before and after blanking. Just to be sure,
> >> > I'll
> >> > test that again right now:
> >>
> >> Sorry, I was not clear enough,   I meant you to look at the complete
> >> output from udisks to see if there is any change at all after the
> >> erase.
> >
> >
> > No, you wasn't clear enough… he he he… Well, now you are, so I'll try
> again…
>
> [skipped stuff that shows that nothing changes when it is erased]
>
> Oh well, it might have helped.
>
> You could try
> udisks --poll-for-media ...
> after erasing it.  But I am just guessing really.
>
> Colin
>

Well, that guess seems to be spot on…!

Erasing the disk and running some tests afterwards:
$ cdrecord blank=fast dev=$CdRom
wodim: Operation not permitted. Warning: Cannot raise RLIMIT_MEMLOCK limits.
Device type : Removable CD-ROM
Version : 5
Response Format: 2
Capabilities :
Vendor_info : 'Optiarc '
Identification : 'DVD RW AD-5540A '
Revision : '2.61'
Device seems to be: Generic mmc2 DVD-R/DVD-RW.
Using generic SCSI-3/mmc CD-R/CD-RW driver (mmc_cdr).
Driver flags : MMC-3 SWABAUDIO BURNFREE
Supported modes: TAO PACKET SAO SAO/R96R RAW/R96R
Speed set to 706 KB/s
Starting to write CD/DVD at speed 4.0 in real BLANK mode for single session.
Last chance to quit, starting real write in 0 seconds. Operation starts.
$ if IsNotEmpty; then echo "Not empty"; else echo "Empty"; fi
Not empty
$ udisks --poll-for-media $CdRom
$ if IsNotEmpty; then echo "Not empty"; else echo "Empty"; fi
Empty
$

Great, thanks!


Johnny Rosenberg



>
> --
> ubuntu-users mailing list
> ubuntu-users at lists.ubuntu.com
> Modify settings or unsubscribe at:
> https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20131124/609307f2/attachment.html>


More information about the ubuntu-users mailing list