Close Menu
    X (Twitter)
    Hectic GeekHectic Geek
    • Apps
      • Apps for Mac
      • Apps for PCs
      • Best Apps
    • Concepts
      • Comparison
      • For Geeks
      • IT Careers
    • Gadgets
      • Accessories
      • Best Work Laptops
      • Budget Laptops
    • GNU/Linux
      • Ubuntu
    • How To
      • Virtualization
      • Windows
      • Windows How-To
    Hectic GeekHectic Geek
    Home » Erase a CD-RW in ‘Linux’ (Command-line)
    GNU/Linux

    Erase a CD-RW in ‘Linux’ (Command-line)

    GayanBy GayanJanuary 21, 2016Updated:February 1, 20166 Comments3 Mins Read
    Twitter Reddit Telegram WhatsApp Email
    Share
    Twitter Reddit Telegram WhatsApp Email

    I have a USB DVD writer (Imation ‘Slimtype’) and the other day I tried to erase a CD-RW that I haven’t really used in a few months using Brasero DiscBurner (in Ubuntu 15.10). It had some data on it and the file manager was able to mount it, but Brasero for some reason failed to even recognize that a CD was present in the DVD burner, let along erasing it.

    Now I’m sure I could’ve done it by using a different disc burning GUI, but I’m a bit of a lazy bugger 😉 so I tried to erase the CD-RW using the command-line. For that I used a program called ‘wodim’ (it’s included by default in many GNU/Linux distributions) and it did the trick.

    In this post I’ll share with you what I did (it’s quite simple actually) in case you come across a similar situation where the GUI fails you.

    Brasero failed to even recognize my CD-RW (Ubuntu 15.10)

    Step 1:

    First attach (if it’s a removable) the disc burner device to your computer, then insert the CD-RW. Once it’s loaded, open the terminal window and enter the below command (we’re simply trying to find the device address of the disc burner):

    wodim --devices

    The command might take a couple of seconds to finish, once it finishes, take a look at the output and ‘wodim‘ will give you the device path (in this case it’s ‘/dev/sg1’) and a small description (usually the model name) of the hardware.

    'wodim' listing my Imation Slim Type DVD burner (on Ubuntu 15.10)

    If you have multiple devices attached, choose the correct one before moving on to the next section.

    Step 2:

    Since now we know the device path, we can now go ahead and erase the CD-RW. This will erase all the data on it, so if you want to backup something, this will be your last chance.

    When it comes to erasing a CD-RW, we can use two options (there are few others actually, but these two are the most common erasing methods). The first one is the ‘fast’ option (which doesn’t actually erase the whole disc and simply clears out the ‘metadata’. This is the fastest method and in most cases, it should be enough).

    The second option is the ‘all’ method which will fully erase the whole disc but it’s slow compared to the ‘fast’ method (it can last couple of minutes, depending on the speed of your CD-RW).

    [ms_alert icon=”fa-hand-paper-o” background_color=”#f5f5f5″ text_color=”” border_width=”0px” border_radius=”0px” box_shadow=”no” dismissable=”no” class=”” id=””]If you come across write or read failures after using the ‘fast’ blank method, then re-erase the disc with the ‘all’ method.[/ms_alert]

    If you want to get a list of all the available blanking methods, use the below command:

    wodim blank=help

    In my case, I just erased it with ‘fast’ method and for that I used the below command:

    wodim blank=fast dev=/dev/sg1 -v

    Make sure to replace the ‘/dev/sg1‘ with your device’s address and, from ‘fast‘ to ‘all‘, if necessary.

    wodim will notify you when it’s done with the blanking. Afterwards you can either use wodim to write files to the disc (which is what I did) or you can use the GUI since adding multiple files to the burning list is easy with GUI tools.

    wodim notifying when the CD-RW is finished (Ubuntu 15.10)

    Well, that’s it. Good luck.

    Share. Twitter Reddit Telegram WhatsApp Email
    Gayan

    An RHCE, 'Linux' user with 14+ years of experience. Extreme lover of Linux and FOSS. He is passionate to test every Linux distribution & compare with the previous release to write in-depth articles to help the FOSS community.

    Related Posts

    AlmaLinux vs Ubuntu – How to Select the Best One?

    October 22, 2023

    AlmaLinux vs Rocky Linux: What you need to know

    August 24, 2023

    Pop!_OS VS Linux Mint, Which One to Select in 2023

    July 27, 2023

    Debian vs Ubuntu Server: A Brief Comparison for Beginners

    July 2, 2023

    CPU Based Simple System Stability and Benchmark Tester for Ubuntu Linux – systester

    June 16, 2023

    Top Linux Distros for Web Development in 2023

    May 20, 2023

    6 Comments

    1. Igor on April 26, 2018 7:34 am

      Getting “wodim: Cannot set speed/dummy”

      Try
      dvd+rw-format -force /dev/cdrom

      Reply
    2. Leonardo on April 10, 2019 2:58 pm

      Thanks a lot. This method worked perfectly. I had tried to erase the cd (full method), but about halfway through the record it was interrupted because there was dirt that I didn’t notice. After cleaning the disc I tried again with Brasero but it stopped immediately. So I tried this solution and I recovered the disk. Thanks for sharing.

      Reply
      • Gayan on April 11, 2019 5:54 pm

        You’re welcome.

        Reply
    3. Delaney Elliott on July 20, 2019 11:16 pm

      I keep getting-
      wodim: Operation not permitted. Warning: cannot raise RLIMIT_MEMLOCK limits.
      What does this mean? I tried both ‘fast’ and ‘all’ and got the same thing.

      Reply
      • lili on January 3, 2020 12:31 am

        Try ‘sudo wodim –devices’

        Reply
    4. jonathan battle on September 15, 2019 3:29 pm

      Doewsn’t work on mine: “device does not support blanking”

      Reply

    Leave A Reply Cancel Reply

    This site uses Akismet to reduce spam. Learn how your comment data is processed.

    Latest Posts

    [Fixed] HDMI No Signal to TV or Monitor on Windows 10/11

    November 7, 2023

    AlmaLinux vs Ubuntu – How to Select the Best One?

    October 22, 2023

    Why Does My Gaming Laptop’s Battery Drain So Fast? The Science Behind It

    October 9, 2023

    Top 10 Best email Encrypting Software for Business and Personal Use

    October 7, 2023

    7 Essential Features A Learning Management System Should Include

    October 2, 2023

    The Importance of DNS for Mac Users: Why You Need to Know How It Works

    September 25, 2023

    Subscribe to Updates

    Get the latest news and updates from Hectic Geek. We won't overload you or sell your data!

    Contact
    • About Us
    • Contact Us
    • Privacy Policy
    • Write for Us
    X (Twitter)
    © 2023 Hectic Geek.

    Type above and press Enter to search. Press Esc to cancel.