10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
I am trying to work on a script to grab the UTC time from a website
So far I was able to cobble this together.
curl -s --head web-url | grep ^Date: | sed 's/Date: //g'
Which gives me the result I need.
Wed, 06 Dec 2017 21:43:50 GMT
What I need to is extract the 21:43:50 and convert... (4 Replies)
Discussion started by: allisterB
2. Shell Programming and Scripting
i have file 1.txt
i want to add today's date and time in the end of each row
todays date... (10 Replies)
Discussion started by: radius
3. Shell Programming and Scripting
My server time is in EDT. And i am sending automated mails from that server in which i need to display the current date time as per IST (GMT+5:30). Please advice how to display the date time as per IST.
IST time leads 9:30 mins to EDT. and i wrote something like below.
... (6 Replies)
Discussion started by: Showdown
4. Shell Programming and Scripting
Following is my small script:-
for i in `cat /users/jack/mainfile-dr.txt`
sudo cp -r $i /users/jack/DR01/.
sudo tar cvf system1-DR.tar *
scp system1-DR.tar backupserver:/DRFiles/system1
sudo rm -rf system1-DR.tar
In this script I... (10 Replies)
Discussion started by: manalisharmabe
5. UNIX for Dummies Questions & Answers
I want to add some hours and minutes to the current date. For example, if the current date is "July 16, 2012 15:20", i want to add 5 hours 30 minutes to "July 16, 2012 00:00" not to "July 16, 2012 15:20". Please help.
Thanks! (4 Replies)
Discussion started by: manojgarg
6. Shell Programming and Scripting
give a date and time:
Jun 12 21:05:16
How can i subtract these dates and times from the current date and time and get back the difference in seconds?
a one liner like:
echo "Jun 12 21:05:16" | some perl/awk programming
90900s (2 Replies)
Discussion started by: SkySmart
7. Shell Programming and Scripting
I've used various scripts in the past to work out the date last week from the current date, however I now have a need to work out the date 1 week from a given date.
So for example, if I have a date of the 23rd July 2010, I would like a script that can work out that one week back was... (4 Replies)
Discussion started by: Donkey25
8. Shell Programming and Scripting
I need to write a script, that will take the current date, time, and the output from # ps -eo pid,tid,class,rtprio,ni,pri,psr,pcpu,stat,wchan:14,comm
and spit it to a file, so it'll look like this...
PID TID CLS RTPRIO NI PRI PSR %CPU STAT WCHAN COMMAND
1 1 TS... (2 Replies)
Discussion started by: Bloke
9. Shell Programming and Scripting
I need to get the date and time for past 1 hour from the current date. Anyone know how to do so?
Thanks (5 Replies)
Discussion started by: spch2o
10. Shell Programming and Scripting
I need to pass param on aix "errpt -a -s MMDDHHMMYY -e MMDDHHMMYY".
How do I read the date+time on the system and pass it as parameter? I need also the -s as previous day and the -e as current day.
itik (1 Reply)
Discussion started by: itik