06-04-2025 11:01 PM - edited 06-04-2025 11:02 PM
Hi Community Members,
I have two switches one of which is able to send the syslogs to server, whereas one of them is having issue. I have compared the configs between two and found out that only below commands are different. My question here is does these commands make any difference as both switches are configured with vlan5 and at the same time interface gig0/10 on both switches are configured as layer 3 information (ip from vlan5).
logging source interface vlan5 (sending logs to syslog server)
logging source interface GigabitEthernet0/1 (not sending logs to syslog server)
06-05-2025 01:15 AM
Hello @M Talha,
yes, it does indeed make a difference whether you specify a SVI (interface vlan) or a physical interface as source-interface.
Using a physical interface on a switch only works, if this interface is configured as a routed port.
So the config on this interface should look like this:
interface Gi0/1
no switchport
ip address <ip> <mask>
no shutdown
You can only use a physical interface on a switch as a source-interface if you configured the ip address directly on this interface.
However, if you configured an interface vlan 5 - a so called SVI - with the ip address, then you have to use the SVI as the source-interface. In that case the physical interface is a switchport that does not have an ip address but is assigned to vlan 5 - either as access port or trunk port.
You do not get an error message if you configure a switchport as a source-interface but it simply does not work.
As a summary, you have to use the interface that has the IP address assigned to it.
HTH!
06-05-2025 04:12 AM
Hello @M Talha
Does Gi0/1 interface is UP/UP ?
From your switch please do that commands and share the result:
#sh run int gi0/1
#ping a.b.c.d source vlan5
#ping a.b.c.d source Gi0/1
-- a.b.c.d the Syslog IP add.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide