AIX lost+found directory Issue

I have created a filesystem on AIX as root called /opt/orautils, Now I changed the permissions on the orautils to oracle:dba, there is a lost_found directory in /opt/orautils with root:system permissions, What does this mean and can I change it to oracle:dba
aanya247Asked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
woolmilkporcConnect With a Mentor Commented:
lost+found is created automatically during filesystem initialization.
It is the place where "fsck" ("file system check") puts orphaned files which you
can try to recover manually (maybe only in part) after an fsck run if required.
The fsck command reconnects any orphaned files and directories by placing
them in the lost+found directory with an assigned i-node number.

Leave it as is, it doesn't hurt anybody because it's usually empty.

If you accidentally deleted such a directory you can recreate it by means of the "mklost+found" utility.
0
 
aanya247Author Commented:
does it effect if the permissions are changed to oracle:dba, As all the files in the directory belong to oracle:dba.
0
 
woolmilkporcCommented:
Since fsck has to be run by root the ownership shouldn't really matter.
I'd suggest changing it back to "root:system" with permissions "700" ("drwx------") nonetheless so only root can view the contents (a security measure).
0
 
aanya247Author Commented:
can u please explain with an example on what files are placed in lost+found and how they can be recovered
0
 
woolmilkporcCommented:
Orphaned files/directories are those whose inode is not referenced in any directory.

fsck puts them into lost+found, assigning a name consisting of a "#" followed by some random numbers.
You can run the "file" command against these items to find out what kind of data might be contained.

For text files ("ASCII text"):  You can simply open them in an editor to check the content.

For directories:  You can run "ls -l" against them. The files and subdirectories inside  should still have their original names.

For other files like binaries ("executable"):  Run the "strings" command against them, maybe the file contains a hint on its identity and content. There's probably not much more you can do, however.

Thanks for the points!
0
All Courses

From novice to tech pro — start learning today.