set DAY=`date +%y%m%d`
set H=`date +%H`
set M=`date +%M`
mailx -s "$H-Mydata" myemail@mail.com<mydata
I am looking to set the current hour to have 1 hour less in the subject header:
For example: let's say the system time is 8
I want to have "7-Mydata" not "8-Mydata"
Can some1... (6 Replies)
My program:
__________________________________
#!/bin/ksh
DAY=`date +%y%m%d`
H=`date +%H`
M=`date +%M`
day=`date +%m/%d/%y`
let h=$H-1
echo DAY $DAY
echo H $H
echo M $M
echo day $day
echo h $h
_____________________________________
My result: (3 Replies)
Hi,
Just wondering, is there anyway I can get the total of logs generated by hours ? Let say I have these logs,
Sep 23 04:48:43 hsbcufs: NOTICE: realloccg /: file system full
Sep 23 04:48:47 hsbcufs: NOTICE: alloc: /: file system full
Sep 23 04:48:51 hsbcufs: NOTICE: realloccg /: file... (14 Replies)
Hi friends, I want to convert 24 hour timing to 12 hour please help me...
my data file looks like this..
13-Nov-2011 13:27:36 15.32044 72.68502
13-Nov-2011 12:08:31 15.31291 72.69807
16-Nov-2011 01:16:54 15.30844 72.74028
15-Nov-2011 20:09:25 15.35096 ... (13 Replies)
Hi guys
I want any script to get me next hour
For example
Nexthour.sh 2013022823
It get me result
2013030100
Thanks a lot , I'm using Solaris 10 (5 Replies)
Hi, the follow can add the day time to my Log file
My_Log_$(date +%F).log
can I add the hour to the end of my log file then my log file will looks like
My_Log_07-24:(:confused: (3 Replies)
I want to extract a pattern from a log file within last hour.
I am doing
grep "pattern" filename | tail -1
It gives the last latest pattern but not within last hour.
and if the pattern found in last hour, output success or else failure. (3 Replies)
Hello please help me on this,
pick the last one hour lines from the log, which have the prefix time format like this.
log message
log message
i tried to do grep, but that failed.
my code
grep '(date +)' log_file_path
This checking only the current time stamp. How to get the log... (16 Replies)
Hi, im trying to write a grep script that returns me the last inputs added in the last hour in the log file. Literally i have nothing yet but:
grep 'Line im looking for' LOGFILE.log | tail -1
this only gives me the last input, but no necessarily from the last hour.
Help Please. (4 Replies)
I want to get CPU average value only (not required user CPU & memory) with each hours on individual date. The sample output is below
| | | User |Memory| User |
Date | Time |CPU %|CPU % | % |Mem % |
03/02/2015|00:00:00| 24.56| 20.66| 89.75| 63.48|... (13 Replies)
Discussion started by: Saravanan_0074
13 Replies
LEARN ABOUT OPENSOLARIS
ds.log
ds.log(4) File Formats ds.log(4)NAME
ds.log - Availability Suite data services log file
DESCRIPTION
The /var/adm/ds.log file contains the Availability Suite data services command log. The administration commands log activities to the file
in the format:
date time product: message
Note that when the size of the log file exceeds 10 Mbytes, ds.log is renamed /var/adm/ds.log.bak and a new /var/adm/ds.log file is cre-
ated.
The ds.log fields are:
date
The date format is mmm nn, where mmm is the local three-character abbreviation for the month and nn is the day of the month on which
the event occurred.
time
The time of the event, in hh:mm:ss format.
product
A product code that identifies which component of the data services produced the event. The code is separated from the message that
follows by a colon (:) and a space.
message
A message that can extend over more than one line describing the event that occurred. The second or following lines are not pre-
fixed by the date, time, and product code strings.
EXAMPLES
The example below shows sample ds.log file content:
Jan 25 05:26:17 ii: iiboot suspend cluster tag <none>
Jan 25 05:32:02 ii: iiboot resume cluster tag <none>
Jan 25 05:32:04 sv: svboot: resume /dev/vx/rdsk/bigmaster
Jan 25 05:32:04 sv: svboot: resume /dev/vx/rdsk/bigshadow
Jan 25 05:32:04 sv: svboot: resume /dev/vx/rdsk/mstvxfs
Jan 25 05:32:04 sv: svboot: resume /dev/vx/rdsk/master01
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+---------------------+---------------------------------------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+---------------------+---------------------------------------------------------+
|Architecture | x86 |
+---------------------+---------------------------------------------------------+
|Availability | SUNWscmu |
+---------------------+---------------------------------------------------------+
|Interface Stability | Committed |
+---------------------+---------------------------------------------------------+
SEE ALSO iiadm(1M), sndradm(1M), svadm(1M), attributes(5)SunOS 5.11 08 Jun 2007 ds.log(4)