not able to view the file


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers not able to view the file
# 1  
Old 12-06-2010
not able to view the file

Hi All,
I am experiencing a strange and serious issue.
I can see, a file exist there inside a directory
while doing cat i can see the file exists, but while trying to view that its saying NO such File or Directory.
Code:
(ipbala01)/env/balast7/app/working/batch_loader/data/system_2/input>ll
total 12
-rw-rw-rw-   1 CDTBUTC    users         5357 Dec  6 12:17 BAL100005.10000000
(ipbala01)/env/balast7/app/working/batch_loader/data/system_2/input>cat BAL100005.10000000
cat: Cannot open BAL100005.10000000: No such file or directory

even not able to cat, cp, mv .. nothing is working
permission is there as it says -rw-rw-rw-
please help.
# 2  
Old 12-06-2010
Hi.

What is the output of:

Code:
ls -d *BAL100005* | od -c

# 3  
Old 12-06-2010
hi, i can see

Code:
$ ls -d *BAL100005* | od -c
0000000   B   A   L   1   0   0   0   0   5   .   1   0   0   0   0   0
0000020   0   0 032  \n
0000024

# 4  
Old 12-06-2010
Try:

Code:
mv "BAL100005.10000000 " BAL100005.10000000

# 5  
Old 12-06-2010
Thanks Scottn,
but I am still getting the same error.
even tried with some other options aswell.

Just to mention, I have managed the very issue by asking the clienet to resend the file.
but, how to deal with it. issue still not resolved Smilie
# 6  
Old 12-06-2010
Was there any output from the mv command?

The od command suggests a space after the filename.

Confirm this with
Code:
ls -b

Or try another approach:
Code:
ls BAL100005* | xargs -I{} mv {} BAL100005.10000000

# 7  
Old 12-06-2010
When facing a file that can not be accessed by its visible name I try to address it by inode:
Code:
stefan@srvap05:~/tmp$ touch "a\ta"
stefan@srvap05:~/tmp$ ls -la
total 8
drwxr-xr-x 2 stefan stefan 4096 2010-12-06 15:54 .
drwxr-xr-x 6 stefan stefan 4096 2010-12-06 15:54 ..
-rw-r--r-- 1 stefan stefan    0 2010-12-06 15:54 a\ta
stefan@srvap05:~/tmp$ mv a\ta xxx
mv: cannot stat `ata': No such file or directory
stefan@srvap05:~/tmp$ ls -i
8069 a\ta
stefan@srvap05:~/tmp$ find . -inum 8069 -exec mv {} new.txt \;
stefan@srvap05:~/tmp$ ls -la
total 8
drwxr-xr-x 2 stefan stefan 4096 2010-12-06 15:56 .
drwxr-xr-x 6 stefan stefan 4096 2010-12-06 15:54 ..
-rw-r--r-- 1 stefan stefan    0 2010-12-06 15:54 new.txt

(PS of course in my simple example mv "a\ta" new.txt would have worked too Smilie )
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. What is on Your Mind?

Moving from Desktop View to Mobile View

See attached video for a demo on how to move back and forth from the desktop view to the mobile view. Currently this only works for the home page, but I will work on some new PHP code in the future to make this work with the page we are currently on. Edit: The issue with making every page ... (2 Replies)
Discussion started by: Neo
2 Replies

2. UNIX for Beginners Questions & Answers

View file flags

hello: how could i view the file's flags? "ls -loa" doesn't seem to do the trick: root@giraffe:/etc # ls -alo total 820 drwxr-xr-x 23 root wheel - 2048 Oct 23 19:48 . drwxr-xr-x 19 root wheel - 1024 Nov 16 15:01 .. drwxr-xr-x 2 root wheel - 512 Nov 11 2014 X11... (6 Replies)
Discussion started by: ipfreak
6 Replies

3. Shell Programming and Scripting

How to view the control characters in a file?

Hello, How can I view control and special characters of a text file?. For example, space, tabs, new line chars etc. Can I use hexdump for it? Thanks (3 Replies)
Discussion started by: reddyr
3 Replies

4. Shell Programming and Scripting

how to view unix file ?

Hi to all, 1- I'm trying to open a certain file in unix with the tool KEA! 2- i get to the correct folder with the CD command 3- Once in the correct directory i try the following unix command: vi NameOfFile.Z 4- Yes those files finish with a .Z 5 - I get something in the KEA!... (3 Replies)
Discussion started by: Sanchoniathon
3 Replies

5. Red Hat

How to view .dat file?

What is the command that can be used to open or view the .dat file in linux? Unable to read the contents of .dat file. (7 Replies)
Discussion started by: Rupaa
7 Replies

6. Shell Programming and Scripting

View ouput as a file

Hi all , I have a view in teradata , the ouput of that view have to be stored as a file with delimitere as '|'.Is there any possibility of doing this in unix ? Thanks in advance , Vinoth (6 Replies)
Discussion started by: vino.paal
6 Replies

7. Solaris

How do I view file?

I am trying to view the files in /etc/security/audit/SERVERNAME/files, but when I gunzip them and then do a cat I get a bunch of garbage with some stuff that makes sense. I need to view this file without having all the garbage. I tried to cat it and vi it without any luck. Can someone show me an... (4 Replies)
Discussion started by: jastanle84
4 Replies

8. Solaris

view HTML file through browser

Howdy experts, I have a HTML file in /var/tmp/file.html How can i view it through the webbrowser (mozilla or IE explorer) Thanks, purple (3 Replies)
Discussion started by: thepurple
3 Replies

9. UNIX for Dummies Questions & Answers

To view end of file

I have a large file of about 2500 lines. I want to see last few lines. any command. please help. (1 Reply)
Discussion started by: manish.s
1 Replies

10. Shell Programming and Scripting

How to view the contents of .gz file without extracting the file?

Hi All, I have several .gz files and i need to see the contents of these file, without extracting these file. If i extract these file the space will be full so. I need to see the contents and parse the contents to a script to extract data from these. Please let me know if you need any more... (10 Replies)
Discussion started by: amitkhiare
10 Replies
Login or Register to Ask a Question