how to read systems current date and time

Answers were Sorted based on User's Feedback



how to read systems current date and time..

Answer / siba sankar nayak

In Unix, to know the current date and time, the command is
date.

Is This Answer Correct ?    2 Yes 1 No

how to read systems current date and time..

Answer / santana20142003

$date -u +%r -->02:26:38 PM
$ date -u +%T -->14:26:48

Is This Answer Correct ?    1 Yes 0 No

how to read systems current date and time..

Answer / m.venkata ramana

read `date '+%m-%d-%y %H-%M-S%'`

Is This Answer Correct ?    1 Yes 0 No

how to read systems current date and time..

Answer / kirtiranjan sahoo

we can use DATE command to know the system date and time.
and want to any modify, then
date +%Y-%m-%d
Y: Year
m: No of month
d: date number
If you want to know the yesterday date, simply you can write the below command
date -d "yesterday"
or
date -d "-1day"

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Shell Script Interview Questions

What is the need of including script interpreter in your shell script?

2 Answers  


How to check if a directory exists?

0 Answers  


When we login into our account which files are executed?

3 Answers   Chip Quest,


Why do we use shell scripting?

0 Answers  


What is the default shell of solaris?

0 Answers  






What is a program shell?

0 Answers  


I have 2 files and I want to print the records which are common to both.

0 Answers  


madhar chod unix ke 10 commands dhang se likh nahi sakta hai

0 Answers   Cap Gemini,


What is bourne shell scripting?

0 Answers  


How will you print the login names of all users on a system?

0 Answers  


What are the advantages of shell scripting?

0 Answers  


How to initialize a directory size to a variable??

2 Answers  


Categories