Announcement

Collapse
No announcement yet.

Permissions completey ruined!

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Permissions completey ruined!

    I can't use sudo and things like KNetworkManager will not detect the network card at all. I'm dead in the water!

    Here's the sudo error
    Code:
    sudo: must be setuid root
    I've tried to chown root:root /usr/bin/sudo but that hasn't helped.

    HELP!!!!!!!!!!!!!!!!!!!!

    Kev

    #2
    Re: Permissions completey ruined!

    I found a post over at the ubuntu forums describing your problem, and the solution posted there is to boot into recovery mode and run the following commands:
    Code:
    chown root:root /usr/bin/sudo
    Code:
    chmod 4755 /usr/bin/sudo
    Then, reboot and all should be fine; let me know how it works out for you
    Asus G1S-X3:
    Intel Core2 Duo T7500, Nvidia GeForce 8600M GT, 4Gb PC2-5300, 320Gb Hitachi 7k320, Linux ( )

    Comment


      #3
      Re: Permissions completey ruined!

      Suid is not just owned by root as you have already learned. note the result from the following ls -l command:

      Code:
      lrh@Rainbow:~$ ls -al /usr/bin/sudo
      -rwsr-xr-x 2 root root 107776 2008-02-25 06:22 /usr/bin/sudo
      What is needed is the "s" in the user permissions: "rws" I believe this is set by chmod but haven't done it for so long that I forget the exact command sequence.

      It should be something like:
      Code:
      chmod u +s filename
      check it first though.

      Comment


        #4
        Re: Permissions completey ruined!

        Originally posted by integr8e
        I found a post over at the ubuntu forums describing your problem, and the solution posted there is to boot into recovery mode and run the following commands:
        Code:
        chown root:root /usr/bin/sudo
        Code:
        chmod 4755 /usr/bin/sudo
        Then, reboot and all should be fine; let me know how it works out for you
        I tried that and it did nothing for me...

        Comment


          #5
          Re: Permissions completey ruined!

          Originally posted by Bladerunner
          Suid is not just owned by root as you have already learned. note the result from the following ls -l command:

          Code:
          lrh@Rainbow:~$ ls -al /usr/bin/sudo
          -rwsr-xr-x 2 root root 107776 2008-02-25 06:22 /usr/bin/sudo
          What is needed is the "s" in the user permissions: "rws" I believe this is set by chmod but haven't done it for so long that I forget the exact command sequence.

          It should be something like:
          Code:
          chmod u +s filename
          check it first though.
          so I us
          Code:
          ls -l
          and see if the "s" is there? Then what file do I chmod?

          Kev

          Comment


            #6
            Re: Permissions completey ruined!

            Well, as a guess, I would think it would be "/usr/bin/sudo"

            OK! I checked to see how the chmod would work. See the following where I took a file without suid and then changed it to have that attribute.

            Code:
            lrh@Rainbow:~/work$ ls -l fusion-icon.sh
            -rw-r--r-- 1 lrh lrh 55 2008-04-01 22:01 fusion-icon.sh
            lrh@Rainbow:~/work$ chmod u+s fusion-icon.sh
            lrh@Rainbow:~/work$ ls -l fusion-icon.sh
            -rwSr--r-- 1 lrh lrh 55 2008-04-01 22:01 fusion-icon.sh
            If the "ls" command shows /usr/bin/sudo to be owned by root you will need to be root to change it's properties. To do that, boot into recovery mode and select the drop to root option.

            Comment


              #7
              Re: Permissions completey ruined!

              Fabulous!

              I'll give it a try at lunch time.

              I was so tired last night that I thought /usr/bin/sudo was a directory... thanks for your reply.

              Kev

              Comment


                #8
                Re: Permissions completey ruined!

                Bladerunner -

                I checked and the "s" was already there. It came out as "rwsr." I tried the chmod u+s /usr/bin/sudo anyway.. with almost no effect.

                I say almost because now I can access my second internal drive... but sudo still does not work, and knetworkmanager doesn't find my network card either.

                Kev

                Comment


                  #9
                  Re: Permissions completey ruined!

                  Well, I'm a bit lost now - not sure where to go next. Just out of curiosity, what happens when you try to run adept package manager from the main menu? Does it prompt you for a password? If yes, when you provide the password, does it work?

                  The reason I ask is because that prompt should be coming from kdesudo which is a front end to sudo. If adept works at that point - sudo is working in some conditions.

                  Good luck.

                  Comment


                    #10
                    Re: Permissions completey ruined!

                    OK I decided to a complete new install of the KDE4 Remix

                    Now I'm back to my original problem, the one I was trying to solve when I messed up the permissions. My second HDD does not mount. I used to be able to get it to mount using the KDE3 Dolphin (which I do not have installed now that I'm running the re-mix). I would go to Storage Media and it would ask for my password and then mount it. It would stay mounted as long as I stayed in the folders.

                    Anyway, I used to get my second HDD to mount by following this guide http://www.psychocats.net/ubuntu/mountlinux this stopped working for me recently in Gutsy and has never worked in Hardy.

                    It may offer a clue as to why my second drive doesn't mount now. In Dolphin (KDE4) I see the drive but every time I click on it it just comes back to my home directory.

                    I really need to be able to see this drive - obviously. Any help?

                    Thanks,
                    Kev

                    Comment


                      #11
                      Re: Permissions completey ruined!

                      results of sudo fdisk -l

                      The 250 GB is where I've installed Kubuntu, and the 80GB drive is the second one I'm trying to have automount.


                      Code:
                      Disk /dev/sda: 250.0 GB, 250059350016 bytes
                      255 heads, 63 sectors/track, 30401 cylinders
                      Units = cylinders of 16065 * 512 = 8225280 bytes
                      Disk identifier: 0x00098d93
                      
                       Device Boot   Start    End   Blocks Id System
                      /dev/sda1 *     1   29268 235095178+ 83 Linux
                      /dev/sda2     29269   30401  9100822+ 5 Extended
                      /dev/sda5     29269   30401  9100791 82 Linux swap / Solaris
                      
                      Disk /dev/sdb: 80.0 GB, 80026361856 bytes
                      255 heads, 63 sectors/track, 9729 cylinders
                      Units = cylinders of 16065 * 512 = 8225280 bytes
                      Disk identifier: 0x000f2b01
                      
                       Device Boot   Start    End   Blocks Id System
                      /dev/sdb1 *     1    9729  78148161 83 Linux
                      here is /etc/fstab

                      Code:
                       /etc/fstab: static file system information.
                      #
                      # <file system> <mount point>  <type> <options>    <dump> <pass>
                      proc      /proc      proc  defaults    0    0
                      # /dev/sda1
                      UUID=50c0249d-1d3f-46f7-bd7d-0f4dc30a2ea1 /        ext3  relatime,e$
                      # /dev/sda5
                      UUID=09ef5236-5f3c-4dc7-ba92-fcb0d5d687fb none      swap  sw    $
                      /dev/hdb    /media/cdrom0  udf,iso9660 user,noauto,exec,utf8 0    0
                      /dev/fd0    /media/floppy0 auto  rw,user,noauto,exec,utf8 0    0
                      Kev

                      Comment


                        #12
                        Re: Permissions completey ruined!

                        Kev, can you run blkid in the konsole, so we can see the UUID of that second hard drive?

                        Comment


                          #13
                          Re: Permissions completey ruined!

                          Originally posted by dibl
                          Kev, can you run blkid in the konsole, so we can see the UUID of that second hard drive?
                          I can't figure out how. lol! It's ok though I've fixed the issue. Will post in a sec.

                          Comment


                            #14
                            Re: Permissions completey ruined!

                            I have been going through this same scenario. sudo not working. can't access my second hard drive and it is somehow linked to the root. I had to remove noexec from the root partition entry in my fstab file to get rebooted. Been a wild ride this last few days. I am eagerly awaiting your solution.
                            FKA: tanderson

                            Comment


                              #15
                              Re: Permissions completey ruined!

                              Kev@

                              In your fstab, you have the following for root and swap:
                              UUID=50c0249d-1d3f-46f7-bd7d-0f4dc30a2ea1 / ext3 relatime,e$
                              # /dev/sda5
                              UUID=09ef5236-5f3c-4dc7-ba92-fcb0d5d687fb none swap sw $
                              What is relatime,e$ in your root partion information? I've never seen that before. Likewise the $ in your swap partition information.

                              This is from my fstab file for my root and swap partitions. I'm also running HH:
                              Code:
                              # /dev/sda3
                              UUID=f6ca0eb3-83b3-461b-8cae-4809e701ea39 /       ext3  errors=remount-ro 0   1
                              # /dev/sda8
                              UUID=90d97410-ea54-40e3-8795-43ee0443df4d none      swap  sw       0   0
                              Windows no longer obstructs my view.
                              Using Kubuntu Linux since March 23, 2007.
                              "It is a capital mistake to theorize before one has data." - Sherlock Holmes

                              Comment

                              Working...
                              X