Reset Search
 

 

Article

How to change syslog server port number on VDX

« Go Back

Information

 
TitleHow to change syslog server port number on VDX
Objective
How to change syslog server port number on VDX
Environment
  • VDX
  • NOS7.x.x and above
Procedure

NOTE: UDP 514 is the default and we can't change it
If you want to change it to different port, then you need CA certificate to allow you to change the secure port which will use TCP. Below example demonstrate using a Linux server to generate a self-signed certificate. 
  1. Please confirm if the VDX is able to ping your Linux server via the management VRF
    sw0(config)# do sh run int man
    interface Management 1/0
    no tcp burstrate
    ip icmp echo-reply
    no ip address dhcp
    ip address 10.26.136.60/17
    ipv6 icmpv6 echo-reply
    no ipv6 address autoconfig
    no ipv6 address dhcp
    vrf forwarding mgmt-vrf
    no shutdown
    !
    
    sw0# ping 10.26.138.86 vrf mgmt-vrf count 2
    Type Control-c to abort
    PING 10.26.138.86 (10.26.138.86): 56 data bytes
    64 bytes from 10.26.138.86: icmp_seq=0 ttl=64 time=0.367 ms
    64 bytes from 10.26.138.86: icmp_seq=1 ttl=64 time=0.998 ms
    --- 10.26.138.86 ping statistics ---
    2 packets transmitted, 2 packets received, 0% packet loss
    round-trip min/avg/max/stddev = 0.367/0.682/0.998/0.316 ms
    
  2. On the Linux server, generate the certificate. 
[root@hcmRh5 ~]# openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /root/vdx.key -out /root/vdx.pem
Generating a 2048 bit RSA private key
..................+++
.........+++
writing new private key to '/root/vdx.key'
-----
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [GB]:US
State or Province Name (full name) [Berkshire]:California
Locality Name (eg, city) [Newbury]:San Jose
Organization Name (eg, company) [My Company Ltd]:Extreme
Organizational Unit Name (eg, section) []:Support
Common Name (eg, your name or your server's hostname) []:hcmRh5
Email Address []:

[root@hcmRh5 ~]# ls -lh /root/vdx*
-rw-r--r-- 1 root root 1.7K May 21 19:48 /root/vdx.key
-rw-r--r-- 1 root root 1.5K May 21 19:48 /root/vdx.pem

[root@hcmRh5 ~]# ifconfig eth1
eth1 Link encap:Ethernet HWaddr 00:1A:64:25:12:BE
inet addr:10.26.138.86 Bcast:10.26.255.255 Mask:255.255.128.0
inet6 addr: fe80::21a:64ff:fe25:12be/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:463967 errors:0 dropped:0 overruns:0 frame:0
TX packets:1523 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:39038067 (37.2 MiB) TX bytes:201636 (196.9 KiB)
Interrupt:169 Memory:ca000000-ca012800

  1. Import the certificate
    sw0# certutil import syslogca directory /root file vdx.pem host 10.26.138.86 user root password pass protocol SCP
    
  2. Confirm certificate is successfully imported
    sw0# show cert-util syslogcacert
    rbridge-id:1
    -----BEGIN CERTIFICATE-----
    MIIEJzCCAw+gAwIBAgIJANQvQ1uSSbvDMA0GCSqGSIb3DQEBBQUAMGoxCzAJBgNV
    BAYTAlVTMRMwEQYDVQQIEwpDYWxpZm9ybmlhMREwDwYDVQQHEwhTYW4gSm9zZTEQ
    MA4GA1UEChMHRXh0cmVtZTEQMA4GA1UECxMHU3VwcG9ydDEPMA0GA1UEAxMGaGNt
    Umg1MB4XDTE4MDUyMjAyNDg1MVoXDTE5MDUyMjAyNDg1MVowajELMAkGA1UEBhMC
    VVMxEzARBgNVBAgTCkNhbGlmb3JuaWExETAPBgNVBAcTCFNhbiBKb3NlMRAwDgYD
    VQQKEwdFeHRyZW1lMRAwDgYDVQQLEwdTdXBwb3J0MQ8wDQYDVQQDEwZoY21SaDUw
    ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDExHonHcR50oHnch7jwdfS
    pBxMJFtA+cIIm6q84SGvB4N2zuN9MkJZT03HXA3ZcRpYcuWRewu1pjOqlSIjFKmU
    CFu/gP0ciWs+b419gRIQiYciwvhy534TltyZh1GZFIJEo1s7vk3Ah7nReAVxfDW6
    v05bmc60UEAKVcg7l6ia0dmfAVqcArgg+x0dy8/F0dWfxFq0x2BKdCJUZ6SMq/Wz
    ZfTvoP1ZCRRzllv8MgLZWDH1eS2+riAKsz9XzryyAiOiMb3XQjzjArtby+YSavLq
    zit/yg4zDqQVB7wnYOCfcvwyG/HBgGOSJayVM4TlULuwXfMycL7qdL2T38nygJ8T
    AgMBAAGjgc8wgcwwHQYDVR0OBBYEFAQSOLjswIG0OUi+jiSwlp8paBItMIGcBgNV
    HSMEgZQwgZGAFAQSOLjswIG0OUi+jiSwlp8paBItoW6kbDBqMQswCQYDVQQGEwJV
    UzETMBEGA1UECBMKQ2FsaWZvcm5pYTERMA8GA1UEBxMIU2FuIEpvc2UxEDAOBgNV
    BAoTB0V4dHJlbWUxEDAOBgNVBAsTB1N1cHBvcnQxDzANBgNVBAMTBmhjbVJoNYIJ
    ANQvQ1uSSbvDMAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEFBQADggEBAIN/plsy
    lZxLv9paJzppkTiSf0p88OENGQUFM7tGHgz3XOD5iDaEQwmNZeTNELp8DOq/OtI+
    8os6/34QPck/vSeGWuIHJtj5jeS9EtkLS25flZt2D5eSWdiWWMxqV2B9rP6bstWL
    iNq67tIDSYtNQpjsTr0Z4kutwj1AjScmMCjFkfc8NJOfCmkvRYmlkCpFj8OYAA+j
    9t32AeSaBh+kx++7mkCbCKfMsyWL7Jc3++dWDzKL/XUJBmOY6GGw4apKUlRwXb99
    NoeiHckZj9U2jft0xPJbLTP+PbB+IPU627FS9U4ka2azrG7XcQrt2oeUG1k+peIS
    CPlBX+fV1UDanHI=
    -----END CERTIFICATE-----
    
  3. Set secure port 
    sw0(config)# logging syslog-server 10.26.138.86 use-vrf mgmt-vrf secure port 1514
    
  4. On syslog server, verify you see connections on 1514
    [root@hcmRh5 ~]# tcpdump -nnei eth1 port 1514
    tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
    listening on eth1, link-type EN10MB (Ethernet), capture size 96 bytes
    
    20:10:28.456655 50:eb:1a:2c:4a:5a > 00:1a:64:25:12:be, ethertype IPv4 (0x0800), length 74: 10.26.136.60.57192 > 10.26.138.86.1514: S 2705377573:2705377573(0) win 5840 <mss 1460,sackOK,timestamp 4293996188 0,nop,wscale 7>
    20:10:28.456872 00:1a:64:25:12:be > 50:eb:1a:2c:4a:5a, ethertype IPv4 (0x0800), length 54: 10.26.138.86.1514 > 10.26.136.60.57192: R 0:0(0) ack 2705377574 win 0
    20:10:38.467076 50:eb:1a:2c:4a:5a > 00:1a:64:25:12:be, ethertype IPv4 (0x0800), length 74: 10.26.136.60.37307 > 10.26.138.86.1514: S 2851087985:2851087985(0) win 5840 <mss 1460,sackOK,timestamp 4293997189 0,nop,wscale 7>
    20:10:38.467093 00:1a:64:25:12:be > 50:eb:1a:2c:4a:5a, ethertype IPv4 (0x0800), length 54: 10.26.138.86.1514 > 10.26.136.60.37307: R 0:0(0) ack 2851087986 win 0
    
    4 packets captured
    4 packets received by filter
    0 packets dropped by kernel
    

     
 

 

 
Additional notes

Feedback

 

Was this article helpful?


   

Feedback

Please tell us how we can make this article more useful.

Characters Remaining: 255