6 Replies Latest reply on Mar 16, 2016 12:26 PM by EdStevens

    root account suddenly get permission denied on a folder

    JonTen

      I am logged in as root and now cannot see a certain folder (u01/mnt/backup) via SSH putty or wincsp. Error message on putty when I type the command ls "cannot access backup: Permission denied".  I have not seen this issue since I started managing this RedHat Linux server hosting our Oracle db 11g. The only change done was to revise the password of an ERP system account used to connect to this database and nothing else.

        • 1. Re: root account suddenly get permission denied on a folder
          EdStevens

          JonTen wrote:

           

          I am logged in as root and now cannot see a certain folder (u01/mnt/backup) via SSH putty or wincsp. Error message on putty when I type the command ls "cannot access backup: Permission denied".  I have not seen this issue since I started managing this RedHat Linux server hosting our Oracle db 11g. The only change done was to revise the password of an ERP system account used to connect to this database and nothing else.

          "Error message on putty when I type the command ls"

          When you type what command?

          Copy and paste the entire command and the entire response.

          And why are you trying to do database operations as root?  That's just asking for trouble.

          • 2. Re: root account suddenly get permission denied on a folder
            Igoroshka

            Is your /u01/mnt/backup a mount? If yes, what are your mount options?

            Was immutable attribute set?

            • 3. Re: root account suddenly get permission denied on a folder
              JonTen

              command = ls  (trying to view the content of folder \backup in the database server)

              here is the entire command and response:

               

              [root@e1dbs01 mnt]# ls

              ls: cannot access backup: Permission denied

              backup

              [root@e1dbs01 mnt]#

              • 4. Re: root account suddenly get permission denied on a folder
                JonTen

                trying to view attribute of the folder:

                [root@e1dbs01 u01]# ls -l

                total 44

                drwxr-xr-x. 4 oracle oinstall  4096 Dec 22  2014 app

                drwxr-xr-x. 2 oracle oinstall  4096 Oct 22  2012 downloads

                drwxr-xr-x. 3 oracle oinstall  4096 Aug 18  2012 jdedwards

                drwxr-xr-x. 3 oracle oinstall  4096 Aug 18  2012 jdedwardsppack

                drwxr-xr-x. 2 oracle oinstall  4096 Aug 18  2012 logs

                drwx------  2 root   root     16384 Aug 15  2012 lost+found

                drwxr-xr-x. 3 oracle oinstall  4096 Aug 18  2012 mnt

                drwxr-xr-x. 3 oracle oinstall  4096 Aug 19  2012 scripts

                [root@e1dbs01 u01]# lsattr mnt

                mnt/backup: Permission denied

                [root@e1dbs01 u01]#

                • 5. Re: root account suddenly get permission denied on a folder
                  Dude!

                  Is /u01/mnt/backup a NFS network share? By default root on a client is mapped to user nobody on the NFS server. This is a security measure. Root squash is a reduction of the access rights for the remote superuser (root). You may have to check your NFS exports file.

                   

                  What is the output of the mount command.

                  • 6. Re: root account suddenly get permission denied on a folder
                    EdStevens

                    JonTen wrote:

                     

                    command = ls  (trying to view the content of folder \backup in the database server)

                    here is the entire command and response:

                     

                    [root@e1dbs01 mnt]# ls

                    ls: cannot access backup: Permission denied

                    backup

                    [root@e1dbs01 mnt]#

                    Ah, I need to clean my reading glasses.  I read that as "Error message on putty when I type the command is "cannot access backup: Permission denied""  Or, reduced to "Error message is .."

                     

                    But that does highlight one more reason it is preferable to copy/paste actual sessions instead of just describing what you think you did.