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.

strings myfile.dat

Thanks for your immediate response..

I have tried that too already. But of no use. Its not giving any output.
So is any other command available?

Hmmm... "od -c" ?

1) what is the name of your file ?

2) please post the result of the commands

type strings
file yourfile.dat

type strings
strings is /usr/bin/strings

file hr_rrate_127aws.dat
hr_rrate_127aws.dat: data

And what gives the following command ?

ls -l hr_rrate_127aws.dat
strings hr_rrate_127aws.dat
wc -l hr_rrate_127aws.dat
uname -a 

Please post the output as well as the error messages if you get some.

  1. ls -l hr_ts_127aws.dat
    -rw-r--r-- 1 root root 1901952 Jan 29 10:13 hr_ts_127aws.dat

  2. strings hr_ts_127aws.dat | head -10
    Aff&Aff
    ff^A
    Aff
    Aff~Aff
    ff~A
    LA33
    Aff^Aff
    A33KA33
    A33 B
    B33 B33

Since its a big file i have given the first 10 lines alone.

  1. wc -l hr_ts_127aws.dat
    2963 hr_ts_127aws.dat

  2. uname -a
    Linux paru 2.6.18-128.el5xen #1 SMP Wed Jan 21 11:55:02 EST 2009 i686 i686 i386 GNU/Linux

---------- Post updated at 04:40 AM ---------- Previous update was at 04:31 AM ----------

Even od -c does not work.

# od -c hr_ts_127aws.dat | head -10
0000000 315 314 314 A 315 314 314 A 315 314 310 A 3 3 317 A
0000020 232 231 I A 232 231 205 A 232 231 211 A 3 3 257 A
0000040 315 314 220 A 315 314 254 A \0 \0 244 A \0 300 y 304
0000060 232 231 I A 315 314 224 A \0 \0 220 A f f & A
0000100 f f 232 A 232 231 211 A 232 231 265 A 232 231 321 A
0000120 3 3 343 A f f 266 A f f 342 A f f 342 A
0000140 f f 332 A 232 231 351 A 315 314 300 A \0 \0 \b A
0000160 f f 316 A f f 322 A 232 231 315 A f f 326 A
0000200 232 231 325 A 315 314 314 A 232 231 325 A 315 314 334 A
0000220 315 314 350 A 3 3 333 A 3 3 343 A 232 231 201 A

---------- Post updated at 04:45 AM ---------- Previous update was at 04:40 AM ----------

hi,

FYI

[root@paru Desktop]# ls -l hr_rrate_127aws.dat
-rw-r--r-- 1 root root 1901952 Jan 29 14:51 hr_rrate_127aws.dat
[root@paru Desktop]# strings hr_rrate_127aws.dat
[root@paru Desktop]# wc -l hr_rrate_127aws.dat
0 hr_rrate_127aws.dat
[root@paru Desktop]# uname -a
Linux paru 2.6.18-128.el5xen #1 SMP Wed Jan 21 11:55:02 EST 2009 i686 i686 i386 GNU/Linux
[root@paru Desktop]#