Operating System - HP-UX
1752653 Members
5905 Online
108788 Solutions
New Discussion юеВ

Re: ls command not showing directories or files

 
SOLVED
Go to solution
Donald Thaler
Super Advisor

ls command not showing directories or files

when i'm positioned in the directory
/u01/app/oracle11g/product/.patch_storage/75323755_jul_17_2009/ and i do an ls -la or ls -ltr i only see two of the 5 subdirectories. if i use the cde file manager it shows me all the subdirectories. if I position myself in one of the subdirectories that does show with the ls -la and do a ls -all, all i get are . .., yet with the file manager i see all the files that exist... when i try to run an oracle opatch uninstall it tells me that some of the directories that i can't see with an ls -la are missing, and yet the file manager shows them all ?? what am i missing ???
6 REPLIES 6
Dennis Handly
Acclaimed Contributor

Re: ls command not showing directories or files

You might want to add -b to see if there unprintable chars in your filenames.
Solution

Re: ls command not showing directories or files

try to unmount the Filesystem , run fsck on the Filesystem and then mount it again ..

i think there might be some inconsistencies with the FS .
Donald Thaler
Super Advisor

Re: ls command not showing directories or files

what are the commans to unmount a file system and then remount it, not something i've done in my limited role as sysadmin?
James R. Ferguson
Acclaimed Contributor

Re: ls command not showing directories or files

Hi Donald:

> what are the commans to unmount a file system and then remount it, not something i've done in my limited role as sysadmin?

The commands are 'umount' and 'mount'. You will find their respecitve manpages in section 1M; hence:

# man 1M mount
# man 1M umount

Be aware that to un-mount a filesystem, no processes can be using it.

Regards!

...JRF...
Elmar P. Kolkman
Honored Contributor

Re: ls command not showing directories or files

A commandsyntax like the -b option mentioned above but that works on all UX-variants:
$ ls -al | cat -tv
It helps if for instance things like a escape sequences are in file-/directorynames.
And make sure you use the -a option if there are files or directories with names starting with a '.'.
Every problem has at least one solution. Only some solutions are harder to find.
Donald Thaler
Super Advisor

Re: ls command not showing directories or files

had to download the directory in question to a different mount point, /u04, and then copy the directory back to it's home base and that allowed me to see all the subdiretories and files...i then issued the umount/ fsck / mount... but nothing was flagged ...could writing over the existing directory have cleared up the problem