The Notebook Review forums were hosted by TechTarget, who shut down them down on January 31, 2022. This static read-only archive was pulled by NBR forum users between January 20 and January 31, 2022, in an effort to make sure that the valuable technical information that had been posted on the forums is preserved. For current discussions, many NBR forum users moved over to NotebookTalk.net after the shutdown.
Problems? See this thread at archive.org.

    Can't open cdrom unless in root user?

    Discussion in 'Linux Compatibility and Software' started by L4d_Gr00pie, Aug 5, 2009.

  1. L4d_Gr00pie

    L4d_Gr00pie Notebook Evangelist

    Reputations:
    94
    Messages:
    579
    Likes Received:
    0
    Trophy Points:
    30
    I have a cdrom that only lets me view files if I go as root in console, which bugs me because after that I need to do everything as root since I save these files afterwards. This might be a beginner's issue, but I'm a beginner in linux :) So how can I make my simple user be able to view the contents of the cd?

    EDIT : Sorry I totally forgot to say my distro.. I'm running Ubuntu 9.04 x64
     
  2. jas

    jas Notebook Evangelist

    Reputations:
    697
    Messages:
    622
    Likes Received:
    5
    Trophy Points:
    31
    This will depend on what version and distribution of Linux you are running, but assuming it's something relatively modern, you could try the following.

    Comment out any CD and/or DVD line in your /etc/fstab file. Like this;
    Code:
    #/dev/cdrom		/mnt/cdrom		auto		noauto,users						0 0
    (The # character at the beginning comments out the entire line). Save the file, reboot, and see if your user account can now access the CD.

    If that still doesn't work you want to make sure your user account is a member of the right group, thereby giving your user account the correct privileges to read from the optical drives. To add a user to a specific group you would use the command;
    Code:
    useradd -G {group-name} [username]
    The word inside of the {} brackets is the group name, and the word inside of the [] brackets is your username. When you issue the command you just type in the groupname and username without any brackets. In this case the group should be cdrom, and if the username was joe, you would issue the following command to add your user account to the cdrom group;
    Code:
    useradd -G cdrom joe
    Try adding your username to the cdrom group, reboot, and see if your user account can now access the CD. If that doesn't work, try adding your user to the plugdev group, reboot and see if it now works.

    Please note, you will need to do the editing of the /etc/fstab file, or adding users to groups, as the root user, or with the sudo command.

    Good Luck..
     
  3. L4d_Gr00pie

    L4d_Gr00pie Notebook Evangelist

    Reputations:
    94
    Messages:
    579
    Likes Received:
    0
    Trophy Points:
    30
    I commented a line about the cdrom in the fstab file like you said and it fixed it. Thanks alot