Can't view directory content - SUNOS


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users Can't view directory content - SUNOS
# 1  
Old 06-26-2006
Can't view directory content - SUNOS

Hi,

The app I support has a directory used for debugg files. It has just come to light there are no files in there. Or is there Smilie


Changing into the directory and completing an ls -lta you get no files. This is truly not right for the application. If I go up one directory the directory size is
drwxrwxr-x 2 user bin 71168 Jun 26 00:03 logdebug

If you cat ./logdebug you get the following nonsense (actually not nonsense these are the names of the files I should be able to see. I can link the name PID to other logs, the yare new), This just stream for pages as there a lot of log files.
cftp-19517-trans.log@cftp-25712-trans.log cftp-21911-trans.log¬dcs_cftp_flx-19487.logŒcftp-1897-trans.log cftp-22
468-trans.log cftp-10589-trans.log0cftp-11166-trans.log.logans.log.............

If you do a file logedug it comes up as a directory. I can't figure out how this one directory has totally screwed up.

SunOS prod002 5.8 Generic_117350-13 sun4u sparc SUNW,Sun-Fire-15000

Any idea where the files really are?

Cheers,
Neil
# 2  
Old 06-26-2006
Well, the cat command should not be working on directories. Check below:
HTML Code:
/$ uname -a
SunOS xxxxxx 5.8 Generic_117350-24 sun4u sparc SUNW,Ultra-Enterprise
/$ cat /tmp
cat: input error on /tmp: Invalid argument
/$ less /tmp
/tmp is a directory
/$ more /tmp

*** /tmp: directory ***
Also, don't go by the size field for a directory. The directory size increases as more files are added (this is the size field in the directory that I am talking about and not 'size of directory'='total size of all files'), but it may not decrease if you remove files.
# 3  
Old 06-27-2006
Are you using wildcards for the "ls"? The fact that you have a large amount of files inside, could affect the use of wildcards.

Try to "cd" to the directory and give:
Code:
find . -ls

Chek perms also Smilie

Regards.
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Cd to another directory to view a log file

Hi guys Today I have been working on a script to execute to view entries within a log file. I have successfully got the command I want to execute within the script itself. I want to view the last 5 entries within a log file and see just the last numbers. The file name would change depending... (5 Replies)
Discussion started by: simpsa27
5 Replies

2. Solaris

SunOS confusing root directory and user home directory

Hello, I've just started using a Solaris machine with SunOS 5.10. After the machine is turned on, I open a Console window and at the prompt, if I execute a pwd command, it tells me I'm at my home directory (someone configured "myuser" as default user after init). ... (2 Replies)
Discussion started by: egyassun
2 Replies

3. UNIX for Advanced & Expert Users

Using vim to view the contents of a directory

When I use this command: vi /home/bob/.vimI expect to see. " ============================================================================ " Netrw Directory Listing (netrw v149) " /home/bob/.vim " Sorted by name " Sort sequence:... (4 Replies)
Discussion started by: cokedude
4 Replies

4. Shell Programming and Scripting

SunOS: How to exclude directory in find command?

Hi All, First my OS version is: ksh:0$ uname -a SunOS 5.9 Generic_122300-48 sun4u sparc SUNW,Sun-Fire-V440 I want to exclude the following DIR(./country111) in my search pattern: ksh:0$ find . -name "*.tar" ./country111/COUNTRY_BATCH-801.tar ./country111/COUNTRY_BATCH-802.tar... (3 Replies)
Discussion started by: saps19
3 Replies

5. Shell Programming and Scripting

Command to view files in Directory

Hi, Can u provide me the command to view files in a directory.Urgent Pls. -Vamsi (4 Replies)
Discussion started by: VamsiVasili
4 Replies

6. Shell Programming and Scripting

Command to view files in Directory

Hi, Can you help me in providing me a command to view all files present in a directory. Thanks a lot. -Vamsi (1 Reply)
Discussion started by: VamsiVasili
1 Replies

7. Solaris

Read/View .img files from SunOs 5.8

We use imaging software from a cardiology clinic on SunOS 5.8 and I want to be able to see these image files (.img extension) on Windows XP. Can this be done? If so, with what software (on Windows XP)? On Windows XP, I've used software like Ulead PhotoImpact and Corel PhotoPaint but I've had no... (16 Replies)
Discussion started by: sreyes27
16 Replies

8. AIX

View lastest content in the file

Hi, May i know how can i view the lastest content of the log file. Currently, i use the "more" command : more logfile However, it will give me the content last year first and i had to keep using the space bar to move down to the lastest content for current date. How can i view the lastest... (3 Replies)
Discussion started by: Lauran Kerry
3 Replies

9. UNIX for Dummies Questions & Answers

view user permissions on directory

Hello, and thanks in advance- I just installled red hat and pinged my machine and got a reply. When i go to http://myIPhere from my other machine it asks for a password and username. It doesnt accepts the username and passwords I use to login to my linux box. I therefore think its a premissions... (1 Reply)
Discussion started by: 99miles
1 Replies
Login or Register to Ask a Question