LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Password
Solaris / OpenSolaris This forum is for the discussion of Solaris, OpenSolaris, OpenIndiana, and illumos.
General Sun, SunOS and Sparc related questions also go here. Any Solaris fork or distribution is welcome.

Notices


Reply
  Search this Thread
Old 10-31-2011, 05:45 AM   #1
harshaabba
Member
 
Registered: Aug 2009
Posts: 73

Rep: Reputation: -14
Direct syslog messages from solaris 10...plz...help...


hi

I want to direct my syslog messages (from all routers ans switches) to the remote machine. Currently I stored them in a /logs/cis file using solaris 10 server.

cat /logs/cis

Oct 31 16:01:52 [10.XX.XXX.2.99.245] 30219: 4d00h: %LINK-3-UPDOWN: Interface FastEthernet0/15, changed state to down
Oct 31 16:01:55 [10.XX.XXX.2.13.180] 331: Oct 31 10:31:54.919: %LINK-3-UPDOWN: Interface Cellular0/0/0, changed state to up
Oct 31 16:01:55 [10.XX.XXX.2.213.180] 331: Oct 31 10:31:54.919: %LINK-3-UPDOWN: Interface Cellular0/0/0, changed state to up
Oct 31 16:01:57 [10.XX.XXX.2.199.245] 30220: 4d00h: %LINK-3-UPDOWN: Interface FastEthernet0/15, changed state to up
Oct 31 16:01:57 [10.XX.XXX.2.199.245] 30220: 4d00h: %LINK-3-UPDOWN: Interface FastEthernet0/15, changed state to up



My requirement is to direct these log to remote syslog server (which use as a backup for syslog messages)

cat /etc/syslog.conf

local7.err /logs/cis
local7.warn /logs/cis
auth.debug /logs/cis

auth.debug ifdef(`LOGHOST', /var/log/authlog, @remotelog
)


cat /etc/hosts

XXX.XX.XX.XX <Remote syslog server name> remotelog


But still I cannot receive the logs from my remote machine. How can I achieve this. Please be kind enough to reply me.

Thanks.
 
Old 10-31-2011, 06:37 AM   #2
harshaabba
Member
 
Registered: Aug 2009
Posts: 73

Original Poster
Rep: Reputation: -14
syslog in solaris10

hi all,

I want to log all the authentication successfull and failure messages to my syslog server. I received the authentication failure messages.

Oct 31 17:02:05 [10.XX.XXX.1.204.75] 22: Oct 31 11:32:04.607: %SEC_LOGIN-4-LOGIN_FAILED: Login failed [user: ] [Source: 10.XX.XX.XX] [localport: 22] [Reason: Login Authentication Failed] at 17:02:04 CST Mon Oct 31 2011


But I didnt receive the authentication successfull messages.

cat /etc/syslog.conf

auth.* /logs/cis

please help me to achieve this

Thanks
 
Old 10-31-2011, 10:05 AM   #3
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,757

Rep: Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983
Quote:
Originally Posted by harshaabba View Post
hi all,
I want to log all the authentication successfull and failure messages to my syslog server. I received the authentication failure messages.

Oct 31 17:02:05 [10.XX.XXX.1.204.75] 22: Oct 31 11:32:04.607: %SEC_LOGIN-4-LOGIN_FAILED: Login failed [user: ] [Source: 10.XX.XX.XX] [localport: 22] [Reason: Login Authentication Failed] at 17:02:04 CST Mon Oct 31 2011

But I didnt receive the authentication successfull messages. cat /etc/syslog.conf
auth.* /logs/cis

please help me to achieve this
Did you look at the syslog documentation for Solaris 10, or try to look up any of the how-to guides on how to do this??
http://www.softpanorama.org/Logs/syslog.shtml
 
Old 10-31-2011, 10:11 AM   #4
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,757

Rep: Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983
Quote:
Originally Posted by harshaabba View Post
hi
I want to direct my syslog messages (from all routers ans switches) to the remote machine. Currently I stored them in a /logs/cis file using solaris 10 server.

My requirement is to direct these log to remote syslog server (which use as a backup for syslog messages)

But still I cannot receive the logs from my remote machine. How can I achieve this. Please be kind enough to reply me.
Not sure what your question is. You say you want to put all your router and switch syslog messages to one server, and say that you CURRENTLY are doing this. Then say you want to put the syslogs onto a remote server...which you said you're already doing. ??????

Do you mean that you want your current central syslog server to be mirrored?? If so, you need to check out syslog-ng for Solaris, which will give you lots of flexibility, and let you do this.
 
Old 10-31-2011, 11:00 PM   #5
harshaabba
Member
 
Registered: Aug 2009
Posts: 73

Original Poster
Rep: Reputation: -14
Quote:
Originally Posted by TB0ne View Post
Not sure what your question is. You say you want to put all your router and switch syslog messages to one server, and say that you CURRENTLY are doing this. Then say you want to put the syslogs onto a remote server...which you said you're already doing. ??????

Do you mean that you want your current central syslog server to be mirrored?? If so, you need to check out syslog-ng for Solaris, which will give you lots of flexibility, and let you do this.
Sorry for inconvenience , I wants to achive this.

I have solaris 10 server which collects syslog from Network Devices. Now I want to direct this to another syslog server.

Oct 31 16:01:52 [10.XX.XXX.2.99.245] 30219: 4d00h: %LINK-3-UPDOWN: Interface FastEthernet0/15, changed state to down
Oct 31 16:01:55 [10.XX.XXX.2.13.180] 331: Oct 31 10:31:54.919: %LINK-3-UPDOWN: Interface Cellular0/0/0, changed state to up
Oct 31 16:01:55 [10.XX.XXX.2.213.180] 331: Oct 31 10:31:54.919: %LINK-3-UPDOWN: Interface Cellular0/0/0, changed state to up
Oct 31 16:01:57 [10.XX.XXX.2.199.245] 30220: 4d00h: %LINK-3-UPDOWN: Interface FastEthernet0/15, changed state to up
Oct 31 16:01:57 [10.XX.XXX.2.199.245] 30220: 4d00h: %LINK-3-UPDOWN: Interface FastEthernet0/15, changed state to up


I want same thing to be appeared in another syslog server(these messages). Hope now you clear with my requirement.


Thanks
 
0 members found this post helpful.
Old 11-01-2011, 01:10 AM   #6
harshaabba
Member
 
Registered: Aug 2009
Posts: 73

Original Poster
Rep: Reputation: -14
hi all,

I got the things work for me except one issue.Here's the config I used in /etc/syslog.conf

local7.warn @<remote server ip>

Now I can receve the same messages from remote syslog server except one issue.

Here's the original message from solaris 10 - 192.168.1.1

Nov 1 11:17:18 [10.1.1.1.204.75] 58: Nov 1 05:47:17: %SEC_LOGIN-1-QUIET_MODE_ON: Still timeleft for watching failures is 11 secs, [user: ] [Source: XX.XX.XX.XX] [localport: 22] [Reason: Login Authentication Failed] [ACL: sl_def_acl] at 11:17:17 CST Tue Nov 1 2011

But in the remote syslog server message changed slightly. Device ip (10.1.1.1) changed to syslog server ip (192.168.1.1)

Date 11-01-2011
Time 11:17:18
Priority Local7.err
Hostname 192.168.1.1
Message 58: Nov 1 05:47:17: %SEC_LOGIN-1- etc...


But in here this should not be the solaris ip it should be the actual device ip(10.1.1.1) which original message contains.I want to retain original source ip address without change it to forward ip/hostname.

Please provide me a way to achieve this.
Thanks

Last edited by harshaabba; 11-01-2011 at 05:02 AM.
 
Old 11-01-2011, 01:45 PM   #7
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,757

Rep: Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983
Quote:
Originally Posted by harshaabba View Post
hi all,
I got the things work for me except one issue.Here's the config I used in /etc/syslog.conf

local7.warn @<remote server ip>

Now I can receve the same messages from remote syslog server except one issue. Here's the original message from solaris 10 - 192.168.1.1 But in the remote syslog server message changed slightly. Device ip (10.1.1.1) changed to syslog server ip (192.168.1.1)

But in here this should not be the solaris ip it should be the actual device ip(10.1.1.1) which original message contains.I want to retain original source ip address without change it to forward ip/hostname.
I did in my first reply...use syslog-ng, instead of standard syslog.

And you could also put two syslog entries in your routers/switches, too, and accomplish the same thing.
 
Old 11-01-2011, 04:35 PM   #8
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Two closely related threads merged and moved to Solaris
 
Old 11-02-2011, 01:41 AM   #9
harshaabba
Member
 
Registered: Aug 2009
Posts: 73

Original Poster
Rep: Reputation: -14
Quote:
Originally Posted by TB0ne View Post
I did in my first reply...use syslog-ng, instead of standard syslog.

And you could also put two syslog entries in your routers/switches, too, and accomplish the same thing.
hi all,

Thanks a lot for your replies. Im having another syslog server which runs syslog-ng. I modified the /etc/syslog-ng.conf
But Still I didnt receive the logs from the remote syslog server.

source s_all {
internal();
unix-stream("/dev/log");
file("/proc/kmsg" log_prefix("kernel: "));
udp();
};
destination remote_log_server
{
udp("XX.XX.XX.XX" port(514));
};

log { source(s_all); destination(remote_log_server); };

I test the loggins from installing the kiwi syslog server in remote_log_server. It displays a error. " I/O error occured while reading fd='13' ,error=Bad file descriptor (9)"

Thanks

Last edited by harshaabba; 11-02-2011 at 04:29 AM.
 
Old 11-02-2011, 05:12 PM   #10
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,757

Rep: Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983
Quote:
Originally Posted by harshaabba View Post
hi all,
Thanks a lot for your replies. Im having another syslog server which runs syslog-ng. I modified the /etc/syslog-ng.conf
But Still I didnt receive the logs from the remote syslog server.

source s_all {
internal();
unix-stream("/dev/log");
file("/proc/kmsg" log_prefix("kernel: "));
udp();
};
destination remote_log_server
{
udp("XX.XX.XX.XX" port(514));
};

log { source(s_all); destination(remote_log_server); };

I test the loggins from installing the kiwi syslog server in remote_log_server. It displays a error. " I/O error occured while reading fd='13' ,error=Bad file descriptor (9)"
Ok...unless BOTH servers are running syslog-ng, you shouldn't expect any different behavior. Also, again, you could add a second syslog entry on your switches/routers, and that would also solve your problem.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Redistribution of Syslog Messages Linux_Kidd Linux - Server 1 04-29-2010 05:21 AM
[SOLVED] How can i direct kernel messages to COM port? 10110111 Linux - General 3 03-31-2010 04:39 PM
Syslog messages... stevemad Slackware 4 10-15-2005 03:45 PM
syslog messages on SLES9 console MrHPUX Linux - Software 0 10-13-2005 01:44 PM
syslog and firestarter - log messages to another file than messages mule Linux - Newbie 0 08-07-2003 03:35 AM

LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris

All times are GMT -5. The time now is 10:24 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration