Results 1 to 8 of 8

Thread: I cant use sudo

  1. #1
    Member registered user
    Join Date
    Oct 2006
    Location
    Delft-The netherlands
    Posts
    33

    I cant use sudo

    Hello and Thanx again I have installed the DVD on my HD and it works great dualbotting with win xp, I had to use sudo yesterday and when i try to use sudo in the command line it says RHCA is not in the sudoers list this incident will be reported. RHCA is my username and hostname any ideas?

  2. #2
    Junior Member
    Join Date
    Jan 2007
    Location
    Berlin, Germany
    Posts
    6
    Hi RHCA,

    I answered your question recently. As root-user you may edit your sudoers-file. That is, please type in at your command-line-prompt:

    su -

    Then, for the needed change, please look at this thread:

    "Super User at Knoppix 5.1.1 HD-installed"

    -nohype

  3. #3
    Member registered user
    Join Date
    Oct 2006
    Location
    Delft-The netherlands
    Posts
    33

    How do i do this?

    I dont understand so much what you said I am a little new to linux and i would like you to explain it more

  4. #4
    Junior Member
    Join Date
    Jan 2007
    Location
    Berlin, Germany
    Posts
    6
    Hi RHCA,

    you may want to edit your "sudoers" file. How to do that:

    login as "root" in a console window by typing

    $ su -

    at the prompt.

    Then you can edit (with any text-editor) the text-file "/etc/sudoers" by changing 1 line (by commenting out the line beginning with "knoppix" by a leading "#" - without using the quotation marks) and adding a new line for user "RHCA" - that's YOU - expressing the rights of "RHCA" for executing privileged commands by "sudo".
    _______________________
    # /etc/sudoers
    ...
    ...
    # knoppix ALL=NOPASSWD: ALL
    RHCA ALL=NOPASSWD: ALL
    _______________________

    Hth.

    -nohype

  5. #5
    Member registered user
    Join Date
    Oct 2006
    Location
    Delft-The netherlands
    Posts
    33

    It shows me an error

    Hello I have already edited the sudoers file bit now when i try to use sudo it says that it is on 660 and it should be on 440 or something like this. Have got any ideas?

  6. #6
    Junior Member
    Join Date
    Jan 2007
    Location
    Berlin, Germany
    Posts
    6

    Re: It shows me an error

    Quote Originally Posted by RHCA
    ...
    sudoers file ... should be on 440 or something like this.
    ...
    This is correct!
    Explanation: sudo is the "owner" of "/etc/sudoers" and allows to the owner (=itself) and to group members only read-access-rights to "/etc/sudoers" when executing sudo and forbids all other access-rights.

    FYI: file-access-rights are coded like this:

    0400 Allow read by owner.
    0200 Allow write by owner.
    0020 Allow write by group members.
    0040 Allow read by group members.

    Adding these codes means that access-rights are granted for the individual rights expressed by the unique summands.

    So 0660=660 is the unique sum of 0200,0400,0020,0040 with the obvious rights.
    But only 0440=440 being the (unique!) sum of 0400 and 0040 are allowed.

    So, change these access-rights accordingly with the chmod-command in root-user mode:

    $ su -

    and then

    # chmod 440 /etc/sudoers.

    That's it!

    Hth
    -nohype

  7. #7
    Member registered user
    Join Date
    Oct 2006
    Location
    Delft-The netherlands
    Posts
    33

    Thanx

    Hey Thanx It works great

  8. #8
    Senior Member registered user
    Join Date
    Jul 2006
    Posts
    122
    excellent quick explaination of file permissions nohype!!

    Take care,
    -Justin
    One Mynds Eye

Similar Threads

  1. sudo apt-get install xxx
    By logicmaster2003 in forum Customising & Remastering
    Replies: 2
    Last Post: 01-07-2006, 10:09 PM
  2. problem with sudo
    By waellinux in forum General Support
    Replies: 2
    Last Post: 04-30-2005, 05:36 PM
  3. Sudo under HD install
    By clarjon1 in forum Tips and Tricks
    Replies: 2
    Last Post: 03-11-2005, 10:05 PM
  4. Sudo list.
    By rrfish72 in forum General Support
    Replies: 19
    Last Post: 08-08-2004, 04:14 AM
  5. what's the difference with sudo ???
    By ptesone in forum Hdd Install / Debian / Apt
    Replies: 2
    Last Post: 03-18-2004, 07:01 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Lenovo ThinkPad L13 Yoga Touch Laptop 13.3” Core i5 8GB RAM 256GB SSD Win 11 Pro picture

Lenovo ThinkPad L13 Yoga Touch Laptop 13.3” Core i5 8GB RAM 256GB SSD Win 11 Pro

$239.99



Lenovo Thinkpad T14 Gen 2 14

Lenovo Thinkpad T14 Gen 2 14" 16GB 512GB, Black

$290.24



Lenovo ThinkPad L15 Gen 3 15.6

Lenovo ThinkPad L15 Gen 3 15.6" 16GB, Thunder Black

$241.50



Lenovo ThinkPad E14 Gen 2 Laptop 14” HD Ryzen 5 16GB RAM 512GB SSD Win 11 Pro picture

Lenovo ThinkPad E14 Gen 2 Laptop 14” HD Ryzen 5 16GB RAM 512GB SSD Win 11 Pro

$319.99



Lenovo ThinkPad E14 Gen 3 Laptop 14” FHD AMD Ryzen 5 16GB RAM 512GB SSD Win 11 picture

Lenovo ThinkPad E14 Gen 3 Laptop 14” FHD AMD Ryzen 5 16GB RAM 512GB SSD Win 11

$374.99



Lenovo Thinkpad T14 Gen 2i 14

Lenovo Thinkpad T14 Gen 2i 14" 16GB 512GB, Black

$313.00



Lenovo ThinkPad L14 Gen 3 14

Lenovo ThinkPad L14 Gen 3 14" FHD Laptop i5 12th Gen 16GB RAM 256GB SSD Win 11

$329.99



Lenovo ThinkPad T480s | i5-8350U | 256GB NVMe | 8GB RAM | W11 Pro | W/AC Adapter picture

Lenovo ThinkPad T480s | i5-8350U | 256GB NVMe | 8GB RAM | W11 Pro | W/AC Adapter

$169.99



Lenovo ThinkPad L15 Gen 3 15.6

Lenovo ThinkPad L15 Gen 3 15.6" 16GB, Thunder Black

$241.50



Lenovo ThinkPad T495 14” Laptop AMD Ryzen 5 PRO 16GB RAM 256GB SSD Windows 11 picture

Lenovo ThinkPad T495 14” Laptop AMD Ryzen 5 PRO 16GB RAM 256GB SSD Windows 11

$229.99