/var/adm/sulog does not showing year


 
Thread Tools Search this Thread
Operating Systems Solaris /var/adm/sulog does not showing year
# 1  
Old 04-16-2014
/var/adm/sulog does not showing year

Hi,

I would like to know is there any way to capture the year in /var/adm/sulog file in solaris 10?

Please suggest
# 2  
Old 04-16-2014
I'm afraid, the format is hardcoded in the su program:
Code:
/*
 * write entry into SULOG or onto CONSOLE - if write fails, return
 */
(void) fprintf(logf, "SU %.2d/%.2d %.2d:%.2d %c %s %s-%s\n",
    tmp->tm_mon + 1, tmp->tm_mday, tmp->tm_hour, tmp->tm_min,
    how ? '+' : '-', ttyn + sizeof ("/dev/") - 1, username, towho);

(taken from the illumos source code of the su program).

---------- Post updated at 13:41 ---------- Previous update was at 13:38 ----------

You could rotate the sulog file yearly and put the year into the filename of the rotated log.
# 3  
Old 04-16-2014
Many Many Thanks Hergp for prompt response.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Solaris

Drive is showing offline in the /var/adm/messages and shows "drive type unknown" in the format outpu

Hi, I am facing issue with one of the drive is solaris 10. it is showing offline in the messages file scsi: WARNING: /pci@2,600000/QLGC,qlc@0/fp@0,0/ssd@w5006016746e00b1b,0 (ssd0): drive offline genunix: WARNING: Page83 data not standards compliant DGC LUNZ 0430 ... (1 Reply)
Discussion started by: Prasanth T K
1 Replies

2. Solaris

Message in /var/adm

Good Morning.. Hello Everyone, I've been receiving this message in /Var/adm 2 days ago, I'm a new administrator for Solaris 10 and don't know what it means.. Thanks for your help Here is the full message: Feb 18 03:30:45 sun3000 ebus: se0 at ebus0: offset 1,400000 Feb 18 03:30:45... (4 Replies)
Discussion started by: alexelchivo
4 Replies

3. Solaris

Difference between /var/log/syslog and /var/adm/messages

Hi, Is the contents in /var/log/syslog and /var/adm/messages are same?? Regards (3 Replies)
Discussion started by: vks47
3 Replies

4. Solaris

/var/adm & /var/sadm

what is the difference between tha /var/adm and /var/sadm files in solaris 10 Os please can any one respond quickly thanking you (2 Replies)
Discussion started by: wkbn86
2 Replies

5. Solaris

diff b/w /var/log/syslog and /var/adm/messages

hi sirs can u tell the difference between /var/log/syslogs and /var/adm/messages in my working place i am having two servers. in one servers messages file is empty and syslog file is going on increasing.. and in another servers message file is going on increasing but syslog file is... (2 Replies)
Discussion started by: tv.praveenkumar
2 Replies

6. Solaris

/var/adm/messages

Check message file and result posted below. Can anyone tell me what this is a sign of, what does it mean? server1% more messages.0 Dec 02 09:35:06 server1 bsd-gw: Inval id protocol request (65): AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA^\\2... (6 Replies)
Discussion started by: finster
6 Replies

7. UNIX for Dummies Questions & Answers

/var/adm/messages

Hi, No log entry is found in messages files. The file size is 0. We are using Solaris 9. Anyone knows what could be wrong. (3 Replies)
Discussion started by: FrankC
3 Replies

8. UNIX for Dummies Questions & Answers

var/adm/cron

Hi, Here im using WinSCP and looking into the remote dir var/adm/cron and I get the following error.Is this bcoz i dont have admin privileges: Cannot get real path for '/var/adm/cron'. Unexpected OK response. Error code: 0 Error message from server: Success Request code: 16 BTW im... (1 Reply)
Discussion started by: thumsup9
1 Replies

9. Solaris

/var/adm/loginlog

As root I have created the loginlog file in /var/adm with permissions (r and w) for root:root only. Failed attempts(> 5) to log in as root do not get logged in the file. What am I missing?? I am on a Solaris 8 Box. :confused: :confused: :confused: (4 Replies)
Discussion started by: encrypted
4 Replies

10. Solaris

/var/adm/messages- Help

Solaris 8/ sun 420R Checked /var/adm/messages file and got the following message: Dec 4 16:40:05 serverXYZ ConfigProvider: get_pkg_instdate: getdate failed for the standard C locale (7) Does anyone know what this means? Looked up getdate but do not understand.... Thanks. (1 Reply)
Discussion started by: finster
1 Replies
Login or Register to Ask a Question