Quantcast
Channel: Teguh Triharto Learning Center
Viewing all 413 articles
Browse latest View live

.::: Cacti Template Alcatel Memory Usage Utilization On % Persen 7750, 7705, 7450, 7210 :::.

$
0
0
Alcatel Memory Usage Utilization 7750, 7705, 7450, 7210

== OID Memory ==
1.3.6.1.4.1.6527.3.1.2.1.1.1 sgiCpuUsage LEAF Unsigned32
1.3.6.1.4.1.6527.3.1.2.1.1.2 sgiMemoryUsed LEAF Unsigned32
1.3.6.1.4.1.6527.3.1.2.1.1.3 sgiMemoryAvailable LEAF Unsigned32
1.3.6.1.4.1.6527.3.1.2.1.1.4 sgiMemoryPoolAllocated LEAF Unsigned32
1.3.6.1.4.1.6527.3.1.2.2.3.4.1.18          tmnxCpmCardMemorySize                                LEAF  Unsigned32
== SNMPWalk ==
[root@TEGUH-SERVER ~]# snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.4.1.6527.3.1.2.1.1.1
SNMPv2-SMI::enterprises.6527.3.1.2.1.1.1.0 = Gauge32: 6
[root@TEGUH-SERVER ~]# snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.4.1.6527.3.1.2.1.1.2
SNMPv2-SMI::enterprises.6527.3.1.2.1.1.2.0 = Gauge32: 674258592
[root@TEGUH-SERVER ~]# snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.4.1.6527.3.1.2.1.1.3
SNMPv2-SMI::enterprises.6527.3.1.2.1.1.3.0 = Gauge32: 2785017856
[root@TEGUH-SERVER ~]# snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.4.1.6527.3.1.2.1.1.4
SNMPv2-SMI::enterprises.6527.3.1.2.1.1.4.0 = Gauge32: 756023296
[root@TEGUH-SERVER ~]#
[root@TEGUH-SERVER ~]# snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.4.1.6527.3.1.2.2.3.4.1.18
SNMPv2-SMI::enterprises.6527.3.1.2.2.3.4.1.18.1.6.1 = Gauge32: 4096
SNMPv2-SMI::enterprises.6527.3.1.2.2.3.4.1.18.1.7.1 = Gauge32: 0
[root@TEGUH-SERVER ~]#

== Formula ==
Total Memory = 4096 * 1024 * 1024 = 4294967296 = 4.294.967.296
or
Total Memory = sgiMemoryUsed + sgiMemoryAvailable + sgiMemoryPoolAllocated
                        = 674258592 + 2785017856 + 756023296
                        =  4215299744 = 4.215.299.744

Utilization Calculation (%)
sgiMemoryUsed (%) = sgiMemoryUsed / Total Memory * 100
                                  = 674258592 / 4215299744 * 100
                                  = 15,995507625756162596630755755812 % = 16%

sgiMemoryAvailable(%) = sgiMemoryAvailable / Total Memory * 100
                                         = 2785017856 / 4215299744 * 100
                                         = 66,0692720598139271967274837763 % = 66%

sgiMemoryPoolAllocated (%) = sgiMemoryPoolAllocated / Total Memory * 100
                                                 = 756023296 / 4215299744 * 100
                                                 = 17,935220314429910206641760467889 % = 17%          
== Create CDEF's ==
cdef=CURRENT_DATA_SOURCE,4214506288,/,100,*
 
 

== Installation ==
- uncompress the xml file
- import using 'Console/Import Templates'

== Import Result ==

== Result Graph sgiMemoryUsed/Memory Utilization ==


== Result Graph other memory ==





.::: How To Calculate Bandwidth Utilization Using SNMP :::.

$
0
0
Problem

It is sometimes necessary to calculate bandwidth use with SNMP.
Solution

Use this solution to solve this problem.

How you calculate use depends on how data is presented for what you want to measure. Interface use is the primary measure used for network use. Use this formulas, based on whether the connection you measure is half-duplex or full-duplex. Shared LAN connections tend to be half-duplex, mainly because contention detection requires that a device listen before it transmits. WAN connections are full-duplex because the connection is point-to-point; both devices can transmit and receive at the same time because they know there is only one other device that shares the connection. Because MIB-II variables are stored as counters, you must take two poll cycles and figure the difference between the two (hence, the delta used in the equation).

This explains the variables used in the formulas:



Note: ifSpeed does not accurately reflect the speed of a WAN interface.

For half-duplex media, use this formula for interface use:


It is more challenging to calculate for full-duplex media. For example, with a full T-1 serial connection, the line speed is 1.544 Mbps. Therefore, a T-1 interface can both receive and transmit 1.544 Mbps for a combined possible bandwidth of 3.088 Mbps!

When you calculate the interface bandwidth for full-duplex connections, you can use this formula, where you take the larger of the in and out values and generate a use percentage:


However, this method hides the use of the direction with the lesser value and provides less accurate results. A more accurate method is to measure the input use and output use separately, with this formula:


or



These formulas are simplified because they do not consider overhead associated with the protocol. For example, refer to RFC 1757 Ethernet-utilization formulas that consider packet overhead.

All of the MIB attributes listed are also in RFC1213 MIB.

Details of the MIB variables used in these formulas are:

    .1.3.6.1.2.1.2.2.1.10
    ifInOctets OBJECT-TYPE
    -- FROM RFC1213-MIB, IF-MIB
    SYNTAX          Counter
    MAX-ACCESS      read-only
    STATUS          Mandatory
    DESCRIPTION    "The total number of octets received on the interface, including framing characters."
    ::= { iso(1) org(3) dod(6) internet(1) mgmt(2) mib-2(1) interfaces(2) ifTable(2) ifEntry(1) 10 }

    .1.3.6.1.2.1.2.2.1.16
    ifOutOctets OBJECT-TYPE
    -- FROM RFC1213-MIB, IF-MIB
    SYNTAX          Counter
    MAX-ACCESS      read-only
    STATUS          Mandatory
    DESCRIPTION    "The total number of octets transmitted out of the interface, including framing characters."
    ::= { ISO(1) org(3) DOD(6) Internet(1) mgmt(2) mib-2(1) interfaces(2) ifTable(2) ifEntry(1) 16 }

    .1.3.6.1.2.1.2.2.1.5
    ifSpeed OBJECT-TYPE
    -- FROM RFC1213-MIB, IF-MIB
    SYNTAX          Gauge
    MAX-ACCESS      read-only
    STATUS          Mandatory
    DESCRIPTION    "An estimate of the interface's current bandwidth in bits per second. 
    For interfaces which do not vary in bandwidth or for those where no accurate estimation can be made,
    this object should contain the nominal bandwidth."
    ::= { ISO(1) org(3) DOD(6) Internet(1) mgmt(2) mib-2(1) interfaces(2) ifTable(2) ifEntry(1) 5 } 

go to .::: example Calculate interface bandwidth utilization % :::.

source http://www.cisco.com/c/en/us/support/docs/ip/simple-network-management-protocol-snmp/8141-calculate-bandwidth-snmp.html
https://forums.manageengine.com/topic/how-to-use-delta-for-continuos-counter-oid-for-net-util

.::: Sample Calculate interface bandwidth utilization % :::.

$
0
0
base on calculation bandwith utilization 32 bits and 64 bits.
http://teguhth.blogspot.co.id/2017/06/how-to-calculate-bandwidth-utilization.html
here as example calculation base on value snmpwalk/snmpget

Counter32 Bits
1.3.6.1.2.1.2.2.1                          ifEntry                                              NODE
1.3.6.1.2.1.2.2.1.1                        ifIndex                                              LEAF  InterfaceIndex
1.3.6.1.2.1.2.2.1.2                        ifDescr                                              LEAF  DisplayString
1.3.6.1.2.1.2.2.1.3                        ifType                                               LEAF  IANAifType
1.3.6.1.2.1.2.2.1.4                        ifMtu                                                LEAF  Integer32
1.3.6.1.2.1.2.2.1.5                        ifSpeed                                              LEAF  Gauge32
1.3.6.1.2.1.2.2.1.6                        ifPhysAddress                                        LEAF  PhysAddress
1.3.6.1.2.1.2.2.1.7                        ifAdminStatus                                        LEAF  INTEGER
1.3.6.1.2.1.2.2.1.8                        ifOperStatus                                         LEAF  INTEGER
1.3.6.1.2.1.2.2.1.9                        ifLastChange                                         LEAF  TimeTicks
1.3.6.1.2.1.2.2.1.10                       ifInOctets                                           LEAF  Counter32
1.3.6.1.2.1.2.2.1.11                       ifInUcastPkts                                        LEAF  Counter32
1.3.6.1.2.1.2.2.1.12                       ifInNUcastPkts                                       LEAF  Counter32
1.3.6.1.2.1.2.2.1.13                       ifInDiscards                                         LEAF  Counter32
1.3.6.1.2.1.2.2.1.14                       ifInErrors                                           LEAF  Counter32
1.3.6.1.2.1.2.2.1.15                       ifInUnknownProtos                                    LEAF  Counter32
1.3.6.1.2.1.2.2.1.16                       ifOutOctets                                          LEAF  Counter32
1.3.6.1.2.1.2.2.1.17                       ifOutUcastPkts                                       LEAF  Counter32
1.3.6.1.2.1.2.2.1.18                       ifOutNUcastPkts                                      LEAF  Counter32
1.3.6.1.2.1.2.2.1.19                       ifOutDiscards                                        LEAF  Counter32
1.3.6.1.2.1.2.2.1.20                       ifOutErrors                                          LEAF  Counter32
1.3.6.1.2.1.2.2.1.21                       ifOutQLen                                            LEAF  Gauge32
1.3.6.1.2.1.2.2.1.22                       ifSpecific                                           LEAF  OBJECT IDENTIFIER

Counter64 Bits
1.3.6.1.2.1.31.1.1.1                       ifXEntry                                             NODE
1.3.6.1.2.1.31.1.1.1.1                     ifName                                               LEAF  DisplayString
1.3.6.1.2.1.31.1.1.1.2                     ifInMulticastPkts                                    LEAF  Counter32
1.3.6.1.2.1.31.1.1.1.3                     ifInBroadcastPkts                                    LEAF  Counter32
1.3.6.1.2.1.31.1.1.1.4                     ifOutMulticastPkts                                   LEAF  Counter32
1.3.6.1.2.1.31.1.1.1.5                     ifOutBroadcastPkts                                   LEAF  Counter32
1.3.6.1.2.1.31.1.1.1.6                     ifHCInOctets                                         LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.7                     ifHCInUcastPkts                                      LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.8                     ifHCInMulticastPkts                                  LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.9                     ifHCInBroadcastPkts                                  LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.10                    ifHCOutOctets                                        LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.11                    ifHCOutUcastPkts                                     LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.12                    ifHCOutMulticastPkts                                 LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.13                    ifHCOutBroadcastPkts                                 LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.14                    ifLinkUpDownTrapEnable                               LEAF  INTEGER
1.3.6.1.2.1.31.1.1.1.15                    ifHighSpeed                                          LEAF  Gauge32
1.3.6.1.2.1.31.1.1.1.16                    ifPromiscuousMode                                    LEAF  TruthValue
1.3.6.1.2.1.31.1.1.1.17                    ifConnectorPresent                                   LEAF  TruthValue
1.3.6.1.2.1.31.1.1.1.18                    ifAlias                                              LEAF  DisplayString
1.3.6.1.2.1.31.1.1.1.19                    ifCounterDiscontinuityTime                           LEAF  TimeStamp

Example Calculation

1. First find the interface unique ID based on ifName (1.3.6.1.2.1.31.1.1.1.1), ex:
   IF-MIB::ifName.11 = STRING: ether11  , Use the .11 above when searching for the ifInOctets OIDs below
[root@TEGUHLab data]# snmpwalk -v 2c -c teguht 10.10.10.10 .1.3.6.1.2.1.2.2.1.1.11
IF-MIB::ifIndex.11 = INTEGER: 11
[root@TEGUHLab data]# snmpwalk -v 2c -c teguht 10.10.10.10 .1.3.6.1.2.1.2.2.1.2.11
IF-MIB::ifDescr.11 = STRING: ether11
[root@TEGUHLab data]# snmpwalk -v 2c -c teguht 10.10.10.10 .1.3.6.1.2.1.2.2.1.5.11
IF-MIB::ifSpeed.11 = Gauge32: 1000000000
[root@TEGUHLab data]# snmpwalk -v 2c -c teguht 10.10.10.10 .1.3.6.1.2.1.2.2.1.10.11
IF-MIB::ifInOctets.11 = Counter32: 1906417075
[root@TEGUHLab data]# snmpwalk -v 2c -c teguht 10.10.10.10 .1.3.6.1.2.1.2.2.1.16.11
IF-MIB::ifOutOctets.11 = Counter32: 2943830328
[root@TEGUHLab data]# snmpwalk -v 2c -c teguht 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.18.11
IF-MIB::ifAlias.11 = STRING: TO UNIVERSE
[root@TEGUHLab data]# snmpwalk -v 2c -c teguht 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.1.11
IF-MIB::ifName.11 = STRING: ether11
[root@TEGUHLab data]# snmpwalk -v 2c -c teguht 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.15.11
IF-MIB::ifHighSpeed.11 = Gauge32: 1000

2. snmpwalk 1 :
[root@TEGUHLab data]# echo " snmpwalk 1"
 snmpwalk 1
[root@TEGUHLab data]# sh interfacetest.sh
IF-MIB::ifIndex.11 = INTEGER: 11
IF-MIB::ifDescr.11 = STRING: ether11
IF-MIB::ifSpeed.11 = Gauge32: 1000000000
IF-MIB::ifInOctets.11 = Counter32: 4050383104
IF-MIB::ifOutOctets.11 = Counter32: 2711729319
IF-MIB::ifAlias.11 = STRING: TO UNIVERSE
IF-MIB::ifName.11 = STRING: ether11
IF-MIB::ifHighSpeed.11 = Gauge32: 1000

3. snmpwalk 2 :
[root@TEGUHLab data]# echo " snmpwalk 2"
 snmpwalk 2
[root@TEGUHLab data]# sh interfacetest.sh
IF-MIB::ifIndex.11 = INTEGER: 11
IF-MIB::ifDescr.11 = STRING: ether11
IF-MIB::ifSpeed.11 = Gauge32: 1000000000
IF-MIB::ifInOctets.11 = Counter32: 4103953434
IF-MIB::ifOutOctets.11 = Counter32: 2716440431
IF-MIB::ifAlias.11 = STRING: TO UNIVERSE
IF-MIB::ifName.11 = STRING: ether11
IF-MIB::ifHighSpeed.11 = Gauge32: 1000

4. snmpwalk 3 :
[root@TEGUHLab data]# echo " snmpwalk 3"
 snmpwalk 3
[root@TEGUHLab data]# sh interfacetest.sh
IF-MIB::ifIndex.11 = INTEGER: 11
IF-MIB::ifDescr.11 = STRING: ether11
IF-MIB::ifSpeed.11 = Gauge32: 1000000000
IF-MIB::ifInOctets.11 = Counter32: 4154317732
IF-MIB::ifOutOctets.11 = Counter32: 2721188883
IF-MIB::ifAlias.11 = STRING: TO UNIVERSE
IF-MIB::ifName.11 = STRING: ether11
IF-MIB::ifHighSpeed.11 = Gauge32: 1000
[root@TEGUHLab data]#

5. Calculation Bandwith Input Output Utilization

Interface <= 1Giga Ethernet using 32bit

Input Utilization(%) = ((4103953434 - 4050383104) * 8 * 100)/1000000000
                    = 42,856264 %
Output Utilization(%) = ((2716440431 - 2711729319) * 8 * 100)/1000000000
                    = 3,7688896 %

Interface >= 10Giga Ethernet using 64bit(minimal 1 Mb Ethernet)
               

Input Utilization(%) = ((4103953434 - 4050383104) * 8 * 100)/(1000 * 10^6)
                    = 42,856264
Output Utilization(%) = ((2716440431 - 2711729319) * 8 * 100)/(1000 * 10^6)
                    = 3,7688896 %

6. Note if ifInOctetsTn < ifInOctetsT1, not allowed and not calculated, ifInOctetsTn must be greater than ifInOctetsT1

7. Note if ifOutOctetsTn < ifOutOctetsTnT1, not allowed and not calculated, ifOutOctetsTn must be greater than ifOutOctetsT1

.::: How Settting & Install Package OS Redhat Linux Enterprise(Rhel) 7 Using Repolocal, ISO File & rpm file :::.

$
0
0

A. Using Repolocal(DVD)
1. Make sure DVD mounting
[root@teguhlab yum.repos.d]# df -kh
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda3       261G  3.0G  258G   2% /
devtmpfs        9.8G     0  9.8G   0% /dev
tmpfs           9.8G   84K  9.8G   1% /dev/shm
tmpfs           9.8G  9.0M  9.8G   1% /run
tmpfs           9.8G     0  9.8G   0% /sys/fs/cgroup
/dev/sda1       187M  146M   42M  78% /boot
tmpfs           2.0G   20K  2.0G   1% /run/user/0
/dev/sr0        3.6G  3.6G     0 100% /run/media/root/RHEL-7.3 Server.x86_64
[root@teguhlab yum.repos.d]#

2. Setting Repolocal using dvd and save
[root@teguhlab ~]# cd /etc/yum.repos.d/
[root@teguhlab yum.repos.d]# ls
redhat.repo  rhel-dvd.repo
[root@teguhlab yum.repos.d]# more redhat.repo
#
# Certificate-Based Repositories
# Managed by (rhsm) subscription-manager
#
# *** This file is auto-generated.  Changes made here will be over-written. ***
# *** Use "subscription-manager repo-override --help" if you wish to make changes. ***
#
# If this file is empty and this system is subscribed consider
# a "yum repolist" to refresh available repos
#
[root@teguhlab yum.repos.d]# more rhel-dvd.repo
[rhel-dvd]
name=RHEL-7.2 Server.x86_64
baseurl=file:///run/media/root/"RHEL-7.2 Server.x86_64"/
#baseurl=file:///mnt
enabled=1
gpgcheck=0
#gpgkey=file:///run/media/root/"RHEL-7.2 Server.x86_64"/RPM-GPG-KEY-redhat-release
[root@teguhlab yum.repos.d]#

B. Using ISO File
1. Make sure Iso file copying on Disk
[root@teguhlab yum.repos.d]# cd /data/
[root@teguhlab data]# ls
rhel-server-7.3-x86_64-dvd.iso
[root@teguhlab data]# pwd
/data
[root@teguhlab data]# ls
rhel-server-7.3-x86_64-dvd.iso
[root@teguhlab data]#

2. mounting to /mnt
mount -o loop rhel-server-7.3-x86_64-dvd.iso /mnt

3. checking mounting mnt
[root@teguhlab data]# df -kh
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda3       280G  6.5G  274G   3% /
devtmpfs        9.8G     0  9.8G   0% /dev
tmpfs           9.8G   88K  9.8G   1% /dev/shm
tmpfs           9.8G  9.0M  9.8G   1% /run
tmpfs           9.8G     0  9.8G   0% /sys/fs/cgroup
/dev/sda1       197M  139M   59M  71% /boot
tmpfs           2.0G   20K  2.0G   1% /run/user/0
/dev/loop0      3.6G  3.6G     0 100% /mnt
/dev/loop1      3.6G  3.6G     0 100% /run/media/teguh
[root@teguhlab data]#

2. Setting Repolocal using iso and save
[root@teguhlab ~]# cd /etc/yum.repos.d/
[root@teguhlab yum.repos.d]# ls
redhat.repo  rhel-dvd.repo
[root@teguhlab yum.repos.d]# more redhat.repo
#
# Certificate-Based Repositories
# Managed by (rhsm) subscription-manager
#
# *** This file is auto-generated.  Changes made here will be over-written. ***
# *** Use "subscription-manager repo-override --help" if you wish to make changes. ***
#
# If this file is empty and this system is subscribed consider
# a "yum repolist" to refresh available repos
#
[root@teguhlab yum.repos.d]# more rhel-dvd.repo
[rhel-dvd]
name=RHEL-7.2 Server.x86_64
#baseurl=file:///run/media/root/"RHEL-7.2 Server.x86_64"/
baseurl=file:///mnt
enabled=1
gpgcheck=0
#gpgkey=file:///run/media/root/"RHEL-7.2 Server.x86_64"/RPM-GPG-KEY-redhat-release
[root@teguhlab yum.repos.d]#

C. Testing install package using DVD or Iso file
[root@teguhlab data]# rpm -q nmap
package nmap is not installed
[root@teguhlab data]# yum -y install nmap
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
file://mnt/repodata/repomd.xml: [Errno 14] curl#37 - "Couldn't open file /repodata/repomd.xml"
Trying other mirror.
Resolving Dependencies
--> Running transaction check
---> Package nmap.x86_64 2:6.40-7.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

===========================================================================================================================
 Package                  Arch                       Version                            Repository                    Size
===========================================================================================================================
Installing:
 nmap                     x86_64                     2:6.40-7.el7                       rhel-dvd                     3.9 M

Transaction Summary
===========================================================================================================================
Install  1 Package

Total download size: 3.9 M
Installed size: 16 M
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : 2:nmap-6.40-7.el7.x86_64                                                                                1/1
  Verifying  : 2:nmap-6.40-7.el7.x86_64                                                                                1/1

Installed:
  nmap.x86_64 2:6.40-7.el7                                                                                                

Complete!
[root@teguhlab data]# rpm -q nmap
nmap-6.40-7.el7.x86_64
[root@teguhlab data]#

[root@teguhlab data]# rpm -q tigervnc-server
package tigervnc-server is not installed
[root@teguhlab data]# yum install tigervnc-server
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
Resolving Dependencies
--> Running transaction check
---> Package tigervnc-server.x86_64 0:1.3.1-9.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

====================================================================================================================================================================================================================
 Package                                                 Arch                                           Version                                              Repository                                        Size
====================================================================================================================================================================================================================
Installing:
 tigervnc-server                                         x86_64                                         1.3.1-9.el7                                          rhel-dvd                                         203 k

Transaction Summary
====================================================================================================================================================================================================================
Install  1 Package

Total download size: 203 k
Installed size: 493 k
Is this ok [y/d/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : tigervnc-server-1.3.1-9.el7.x86_64                                                                                                                                                               1/1
  Verifying  : tigervnc-server-1.3.1-9.el7.x86_64                                                                                                                                                               1/1

Installed:
  tigervnc-server.x86_64 0:1.3.1-9.el7                                                                                                                                                                             

Complete!
[root@teguhlab data]# rpm -q tigervnc-server
tigervnc-server-1.3.1-9.el7.x86_64
[root@teguhlab data]#

D. Using RPM File
1. example download file and copy to disk
ftp://rpmfind.net/linux/centos/7.3.1611/os/x86_64/Packages/compat-libstdc++-33-3.2.3-72.el7.i686.rpm
ftp://rpmfind.net/linux/centos/7.3.1611/os/x86_64/Packages/compat-libstdc++-33-3.2.3-72.el7.x86_64.rpm

2. check status package
rpm -q compat-libstdc++-33.i686 compat-libstdc++-33.x86_64
[root@teguhlab data]# ls
compat-libstdc++-33-3.2.3-72.el7.i686.rpm  compat-libstdc++-33-3.2.3-72.el7.x86_64.rpm  rhel-server-7.3-x86_64-dvd.iso
[root@teguhlab data]# rpm -q compat-libstdc++-33.i686 compat-libstdc++-33.x86_64
package compat-libstdc++-33.i686 is not installed
package compat-libstdc++-33.x86_64 is not installed

3. Install package using rpm -ivh
[root@teguhlab data]# rpm -ivh compat-libstdc++-33-3.2.3-72.el7.i686.rpm compat-libstdc++-33-3.2.3-72.el7.x86_64.rpm
warning: compat-libstdc++-33-3.2.3-72.el7.i686.rpm: Header V3 RSA/SHA256 Signature, key ID f4a80eb5: NOKEY
Preparing...                          ################################# [100%]
Updating / installing...
   1:compat-libstdc++-33-3.2.3-72.el7 ################################# [ 50%]
   2:compat-libstdc++-33-3.2.3-72.el7 ################################# [100%]
[root@teguhlab data]# rpm -q compat-libstdc++-33.i686 compat-libstdc++-33.x86_64
compat-libstdc++-33-3.2.3-72.el7.i686
compat-libstdc++-33-3.2.3-72.el7.x86_64
[root@teguhlab data]#

::: How to Upgrade RHEL/Redhat Enterprise Linux 7 Using Repolocal, ISO & Online :::.

$
0
0

1. capture release version before upgrade
[root@teguhlab yum.repos.d]# cat /etc/redhat-release
Red Hat Enterprise Linux Server release 7.2 (Maipo)
[root@teguhlab yum.repos.d]#

2. Mounting Image Rhel 7.3/Latest Using ISO File or DVD Room/Repolocal
detail on http://teguhth.blogspot.co.id/2017/07/how-settting-install-package-os-redhat.html

3. Clean all
# yum clean all
# subscription-manager clean
All local data removed

4. Upgrade Rhel 7.2 to Rhel 7.3/Latest
# yum -y update

[root@teguhlab data]# cat /etc/redhat-release
Red Hat Enterprise Linux Server release 7.2 (Maipo)
[root@teguhlab data]#
[root@teguhlab data]# yum -y update
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscripti
on-manager to register.
Resolving Dependencies
--> Running transaction check
---> Package ModemManager.x86_64 0:1.1.0-8.git20130913.el7 will be updated
---> Package ModemManager.x86_64 0:1.6.0-2.el7 will be an update
--> Processing Dependency: libmbim-utils for package: ModemManager-1.6.0-2.el7.x86_64

..........................
  xfsprogs.x86_64 0:4.5.0-8.el7                                                        
  xorg-x11-drv-ati.x86_64 0:7.6.1-3.20160215gitd41fccc.el7                             
  xorg-x11-drv-intel.x86_64 0:2.99.917-22.20151206.el7                                 
  xorg-x11-drv-nouveau.x86_64 1:1.0.11-4.el7                                           
  xorg-x11-drv-vmmouse.x86_64 0:13.0.0-12.el7                                          
  xorg-x11-server-Xorg.x86_64 0:1.17.2-22.el7                                          
  xorg-x11-server-common.x86_64 0:1.17.2-22.el7                                        
  xorg-x11-utils.x86_64 0:7.5-14.el7                                                   
  xz.x86_64 0:5.2.2-1.el7                                                              
  xz-libs.x86_64 0:5.2.2-1.el7                                                         
  yum.noarch 0:3.4.3-150.el7                                                           
  yum-langpacks.noarch 0:0.4.2-7.el7                                                   
  yum-rhn-plugin.noarch 0:2.0.1-6.el7                                                  
  yum-utils.noarch 0:1.1.31-40.el7                                                     
Failed:
  filesystem.x86_64 0:3.2-20.el7             filesystem.x86_64 0:3.2-21.el7           
Complete!

[root@teguhlab data]# cat /etc/redhat-release
Red Hat Enterprise Linux Server release 7.3 (Maipo)
[root@teguhlab data]#

5. capture release version after upgrade
[root@teguhlab yum.repos.d]# cat /etc/redhat-release
Red Hat Enterprise Linux Server release 7.2 (Maipo)
[root@teguhlab yum.repos.d]#

.::: Enable Crontab on Linux/Unix Platform :::.

$
0
0
Crontab  is  the program used to install, remove or list the tables used to drive the cron(8) daemon.  Each user can have their own crontab, and though these are files in /var/spool/ , they are not intended to be edited directly. For SELinux in mls mode can be even more crontabs - for  each  range.  For  more  see selinux(8).

The  cron jobs could be allow or disallow for different users. For classical crontab there exists cron.allow and cron.deny files.  If cron.allow file exists, then you must be listed therein in order to be allowed to use this command.  If the cron.allow file does not exist but the cron.deny file  does  exist,  then you must not be listed in the cron.deny file in order to use this command.  If neither of these files exists, only the super user will be allowed to use this command.  The second option is using PAM authentication, where you set up users, which could  or  couldn’t  use  crontab  and  also  system  cron  jobs  from /etc/cron.d/.

The temporary directory could be set in enviroment variables. If it’s not set by user than /tmp is used.

Tips for writing crontab expressions:

Tip 1: If the day-of-month or day-of-week part starts with a *, they form an intersection. Otherwise they form a union. * * 3 * 1 runs on the 3rd day of the month and on Wednesday (union), whereas * * */2 * 1 runs on every second day of the month only if it's also a Monday (intersection). The manpage is incorrect about this detail. More info.

Tip 2: Cron jobs can break. Don't rely just on email to find out because the root cause can be outside of cron. Monitor each cronjob with a watchdog timer.

Tip 3: Run your servers including the cron process in UTC timezone. Why?

Tip 4: Some cron implementations allow to specify years and seconds. However, cron is not the best tool if you need to operate at those levels, which is also why crontab.guru doesn't support them.

Tip 5: Don't use @reboot because it has too many issues.

Tip 6: More difficult schedules can be realized by combining multiple cron expressions. For example, if you need to run X every 90 minutes, create one crontab entry that runs X every 3 hours on the hour (0 */3 * * *), and a second crontab entry that runs X every 3 hours with an offset (30 1/3 * * *).

Tip 7: Another alternative for complicated schedules is Mcron.

how to implementation crontab

1. Prepare command to be scheduled monthly by crontab
example
@monthly /opt/ManageEngine/OpManager/bin/backup/BackupDB.sh -mode configdata
@monthly /opt/ManageEngine/OpManager/bin/backup/BackupDB.sh -mode all

2. enable crontab (# crontab -e)
[root@TeguhLab ~]# crontab -e
crontab: installing new crontab
[root@TeguhLab ~]# crontab -l
@monthly /opt/ManageEngine/OpManager/bin/backup/BackupDB.sh -mode configdata
@monthly /opt/ManageEngine/OpManager/bin/backup/BackupDB.sh -mode all
[root@TeguhLab ~]#

4. remove crontab type
 # crontab -r

5. here example tutorial crontab
https://crontab.guru/examples.html

.::: How to display login banner before & After login(Prelogin, Postlogin) On Unix/Linux :::.

$
0
0
Pre login banner is use for sending a warning message before authentication may be relevant for getting legal protection or just give out information to users. The contents of the specified file are sent to the remote user before authentication is allowed. This option is only available for protocol version 2. By default, no banner is displayed (if you are using latest version of Linux/UNIX then you do not have to worry about version issue)

A. Display SSH Warning Message to Users Before Login

1) By default sshd server turns off this feature.

2) Login as the root user; create your login banner file:
# vi /etc/ssh/sshd-banner
###############################################################
#    .::: Welcome to Teguh Triharto Unix Login :::.           #
#    All connections are monitored and recorded               #
#  Display SSH Warning Message to Users Before Login          #
#  Disconnect IMMEDIATELY if you are not an authorized user!  #
###############################################################

[root@TeguhLab ~]# more /etc/ssh/sshd-banner
###############################################################
#    .::: Welcome to Teguh Triharto Unix Login :::.           #
#    All connections are monitored and recorded               #
#  Display SSH Warning Message to Users Before Login          #
#  Disconnect IMMEDIATELY if you are not an authorized user!  #
###############################################################
[root@TeguhLab ~]#

3) Open sshd configuration file /etc/sshd/sshd_config using a text editor:

# vi /etc/ssh/sshd_config

4) Add/edit the following line:

Banner /etc/ssh/sshd-banner
[root@TeguhLab ~]# cat /etc/ssh/sshd_config | grep banner
# no default banner path
#Banner none
Banner /etc/ssh/sshd-banner
[root@TeguhLab ~]#

5) Save file and restart the sshd server:

# /etc/init.d/sshd restart
service sshd restart

[root@TeguhLab ~]# service sshd restart
Stopping sshd:                                             [  OK  ]
Starting sshd:                                             [  OK  ]
[root@TeguhLab ~]#

6) Test your new banner (from Linux or UNIX workstation or use any other ssh client):

[root@TeguhLab ~]# ssh TeguhLab
###############################################################
#    .::: Welcome to Teguh Triharto Unix Login :::.           #
#    All connections are monitored and recorded               #
#  Display SSH Warning Message to Users Before Login          #
#  Disconnect IMMEDIATELY if you are not an authorized user!  #
###############################################################
root@TeguhLab's password:

https://www.cyberciti.biz/tips/change-openssh-sshd-server-login-banner.html

B. Display SSH Warning Message to Users After Login

1) By default sshd server turns off this feature.

2) Login as the root user; create your login banner file:
# vi /etc/motd
###############################################################
#    .::: Welcome to Teguh Triharto Unix Login :::.           #
#    All connections are monitored and recorded               #
#  Disconnect IMMEDIATELY if you are not an authorized user!  #
#  Display SSH Warning Message to Users After Login Success   #
###############################################################

[root@TeguhLab ~]# more /etc/motd
###############################################################
#    .::: Welcome to Teguh Triharto Unix Login :::.           #
#    All connections are monitored and recorded               #
#  Disconnect IMMEDIATELY if you are not an authorized user!  #
#  Display SSH Warning Message to Users After Login Success   #
###############################################################
[root@TeguhLab ~]#

3) Save file and restart the sshd server:

# /etc/init.d/sshd restart
service sshd restart

[root@TeguhLab ~]# service sshd restart
Stopping sshd:                                             [  OK  ]
Starting sshd:                                             [  OK  ]
[root@TeguhLab ~]#

4. Testing login
[root@TeguhLab ~]# ssh 127.0.0.1
The authenticity of host '127.0.0.1 (127.0.0.1)' can't be established.
RSA key fingerprint is fb:2c:1e:28:6d:8b:31:60:40:66:4c:b2:b9:0f:ee:f9.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '127.0.0.1' (RSA) to the list of known hosts.
###############################################################
#    .::: Welcome to Teguh Triharto Unix Login :::.           #
#    All connections are monitored and recorded               #
#  Display SSH Warning Message to Users Before Login          #
#  Disconnect IMMEDIATELY if you are not an authorized user!  #
###############################################################
root@127.0.0.1's password:
Last login: Tue Jul 18 15:02:52 2017 from 10.100.0.111
###############################################################
#    .::: Welcome to Teguh Triharto Unix Login :::.           #
#    All connections are monitored and recorded               #
#  Disconnect IMMEDIATELY if you are not an authorized user!  #
#  Display SSH Warning Message to Users After Login Success   #
###############################################################
[root@TeguhLab ~]#

http://www.tecmint.com/protect-ssh-logins-with-ssh-motd-banner-messages/

.::: How To Export Display on Linux/Unix Platform (Installer User Interface Mode Not Supported):::.

$
0
0


1. example running java on linux using CLI
[root@TeguhLab /]# su oracle
bash-4.1$ cd /
bash-4.1$ ./teguh.bin
Preparing to install...
Extracting the JRE from the installer archive...
Unpacking the JRE...
Extracting the installation resources from the installer archive...
Configuring the installer for this system's environment...

Launching installer...

Graphical installers are not supported by the VM. The console mode will be used instead...

Preparing CONSOLE Mode Installation...


=======================================================

Installer User Interface Mode Not Supported

The installer cannot run in this UI mode. To specify the interface mode, use the -i command-line option, followed by the UI mode identifier. The valid UI modes identifiers are GUI, Console, and Silent.

=======================================================

bash-4.1$

2. IP address PC to access
Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:\Users\teguh.triharto>ipconfig

Windows IP Configuration

Wireless LAN adapter Wireless Network Connection:

   Connection-specific DNS Suffix  . :
   Link-local IPv6 Address . . . . . : fe80::995d:c5d3:4163:a5b2%12
   IPv4 Address. . . . . . . . . . . : 10.10.10.10
   Subnet Mask . . . . . . . . . . . : 255.255.252.0
   Default Gateway . . . . . . . . . : 10.10.10.1

Ethernet adapter Local Area Connection:

   Media State . . . . . . . . . . . : Media disconnected
   Connection-specific DNS Suffix  . :

C:\Users\teguh.triharto>

3. Open terminal on Unix/solaris/Linux server and export display base on PC

export DISPLAY=10.10.10.10:0.0

bash-4.1$ export DISPLAY=10.10.10.10:0.0

4. Run aplication example java from pc using xshell then press button Yes
[root@TeguhLab /]# su oracle
bash-4.1$ export DISPLAY=10.10.10.10:0.0
bash-4.1$ ./ManageEngine_OpManager_64bit_11600.bin
InstallShield Wizard

Initializing InstallShield Wizard...

Searching for Java(tm) Virtual Machine...
.
Preparing Java(tm) Virtual Machine...
..........................................................................................................................................................................................................................................................................................................................
bash-4.1$

5. Application now running


.::: Sample output snmpwalk OID on MIB IF-MIB :::.

$
0
0

1. Definition IF-MIB
The MIB module to describe generic objects for network interface sub-layers. This MIB is an updated version of MIB-II's ifTable, and incorporates the extensions defined in RFC 1229.

2. OID on IF-MIB include calculate
ifTable
1.3.6.1.2.1.2                            interfaces                                           NODE
1.3.6.1.2.1.2.1                          ifNumber                                             LEAF  Integer32
1.3.6.1.2.1.2.2                          ifTable                                              NODE
1.3.6.1.2.1.2.2.1                        ifEntry                                              NODE
1.3.6.1.2.1.2.2.1.1                      ifIndex                                              LEAF  InterfaceIndex
1.3.6.1.2.1.2.2.1.2                      ifDescr                                              LEAF  DisplayString
1.3.6.1.2.1.2.2.1.3                      ifType                                               LEAF  IANAifType
1.3.6.1.2.1.2.2.1.4                      ifMtu                                                LEAF  Integer32
1.3.6.1.2.1.2.2.1.5                      ifSpeed                                              LEAF  Gauge32
1.3.6.1.2.1.2.2.1.6                      ifPhysAddress                                        LEAF  PhysAddress
1.3.6.1.2.1.2.2.1.7                      ifAdminStatus                                        LEAF  INTEGER
1.3.6.1.2.1.2.2.1.8                      ifOperStatus                                         LEAF  INTEGER
1.3.6.1.2.1.2.2.1.9                      ifLastChange                                         LEAF  TimeTicks
1.3.6.1.2.1.2.2.1.10                     ifInOctets                                           LEAF  Counter32
1.3.6.1.2.1.2.2.1.11                     ifInUcastPkts                                        LEAF  Counter32
1.3.6.1.2.1.2.2.1.12                     ifInNUcastPkts                                       LEAF  Counter32
1.3.6.1.2.1.2.2.1.13                     ifInDiscards                                         LEAF  Counter32
1.3.6.1.2.1.2.2.1.14                     ifInErrors                                           LEAF  Counter32
1.3.6.1.2.1.2.2.1.15                     ifInUnknownProtos                                    LEAF  Counter32
1.3.6.1.2.1.2.2.1.16                     ifOutOctets                                          LEAF  Counter32
1.3.6.1.2.1.2.2.1.17                     ifOutUcastPkts                                       LEAF  Counter32
1.3.6.1.2.1.2.2.1.18                     ifOutNUcastPkts                                      LEAF  Counter32
1.3.6.1.2.1.2.2.1.19                     ifOutDiscards                                        LEAF  Counter32
1.3.6.1.2.1.2.2.1.20                     ifOutErrors                                          LEAF  Counter32
1.3.6.1.2.1.2.2.1.21                     ifOutQLen                                            LEAF  Gauge32
1.3.6.1.2.1.2.2.1.22                     ifSpecific                                           LEAF  OBJECT IDENTIFIER

ifXTable
1.3.6.1.2.1.31                           ifMIB                                                NODE
1.3.6.1.2.1.31.1                         ifMIBObjects                                         NODE
1.3.6.1.2.1.31.1.1                       ifXTable                                             NODE
1.3.6.1.2.1.31.1.1.1                     ifXEntry                                             NODE
1.3.6.1.2.1.31.1.1.1.1                   ifName                                               LEAF  DisplayString
1.3.6.1.2.1.31.1.1.1.2                   ifInMulticastPkts                                    LEAF  Counter32
1.3.6.1.2.1.31.1.1.1.3                   ifInBroadcastPkts                                    LEAF  Counter32
1.3.6.1.2.1.31.1.1.1.4                   ifOutMulticastPkts                                   LEAF  Counter32
1.3.6.1.2.1.31.1.1.1.5                   ifOutBroadcastPkts                                   LEAF  Counter32
1.3.6.1.2.1.31.1.1.1.6                   ifHCInOctets                                         LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.7                   ifHCInUcastPkts                                      LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.8                   ifHCInMulticastPkts                                  LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.9                   ifHCInBroadcastPkts                                  LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.10                  ifHCOutOctets                                        LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.11                  ifHCOutUcastPkts                                     LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.12                  ifHCOutMulticastPkts                                 LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.13                  ifHCOutBroadcastPkts                                 LEAF  Counter64
1.3.6.1.2.1.31.1.1.1.14                  ifLinkUpDownTrapEnable                               LEAF  INTEGER
1.3.6.1.2.1.31.1.1.1.15                  ifHighSpeed                                          LEAF  Gauge32
1.3.6.1.2.1.31.1.1.1.16                  ifPromiscuousMode                                    LEAF  TruthValue
1.3.6.1.2.1.31.1.1.1.17                  ifConnectorPresent                                   LEAF  TruthValue
1.3.6.1.2.1.31.1.1.1.18                  ifAlias                                              LEAF  DisplayString
1.3.6.1.2.1.31.1.1.1.19                  ifCounterDiscontinuityTime                           LEAF  TimeStamp

3. Sample output by SnmpWalk
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.1.11
IF-MIB::ifIndex.11 = INTEGER: 11
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.2.11
IF-MIB::ifDescr.11 = STRING: ether11
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.3.11
IF-MIB::ifType.11 = INTEGER: ethernetCsmacd(6)
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.4.11
IF-MIB::ifMtu.11 = INTEGER: 1500
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.5.11
IF-MIB::ifSpeed.11 = Gauge32: 1000000000
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.6.11
IF-MIB::ifPhysAddress.11 = STRING: e4:8d:8c:2c:9c:c3
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.7.11
IF-MIB::ifAdminStatus.11 = INTEGER: up(1)
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.8.11
IF-MIB::ifOperStatus.11 = INTEGER: up(1)
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.9.11
IF-MIB::ifLastChange.11 = Timeticks: (0) 0:00:00.00
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.10.11
IF-MIB::ifInOctets.11 = Counter32: 3706009249
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.11.11
IF-MIB::ifInUcastPkts.11 = Counter32: 1239963861
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.12.11
IF-MIB::ifInNUcastPkts.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.13.11
IF-MIB::ifInDiscards.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.14.11
IF-MIB::ifInErrors.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.15.11
IF-MIB::ifInUnknownProtos.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.16.11
IF-MIB::ifOutOctets.11 = Counter32: 653051289
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.17.11
IF-MIB::ifOutUcastPkts.11 = Counter32: 3140684960
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.18.11
IF-MIB::ifOutNUcastPkts.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.19.11
IF-MIB::ifOutDiscards.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.20.11
IF-MIB::ifOutErrors.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.21.11
IF-MIB::ifOutQLen.11 = Gauge32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.22.11
IF-MIB::ifSpecific.11 = OID: SNMPv2-SMI::zeroDotZero
[root@TeguhLab data]#

[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.1.11
IF-MIB::ifName.11 = STRING: ether11
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.2.11
IF-MIB::ifInMulticastPkts.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.3.11
IF-MIB::ifInBroadcastPkts.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.4.11
IF-MIB::ifOutMulticastPkts.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.5.11
IF-MIB::ifOutBroadcastPkts.11 = Counter32: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.6.11
IF-MIB::ifHCInOctets.11 = Counter64: 115165116948198
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.7.11
IF-MIB::ifHCInUcastPkts.11 = Counter64: 95729601299
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.8.11
IF-MIB::ifHCInMulticastPkts.11 = Counter64: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.9.11
IF-MIB::ifHCInBroadcastPkts.11 = Counter64: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.10.11
IF-MIB::ifHCOutOctets.11 = Counter64: 33290985497085
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.11.11
IF-MIB::ifHCOutUcastPkts.11 = Counter64: 71860438708
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.12.11
IF-MIB::ifHCOutMulticastPkts.11 = Counter64: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.13.11
IF-MIB::ifHCOutBroadcastPkts.11 = Counter64: 0
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.14.11
IF-MIB::ifLinkUpDownTrapEnable.11 = No Such Instance currently exists at this OID
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.15.11
IF-MIB::ifHighSpeed.11 = Gauge32: 1000
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.16.11
IF-MIB::ifPromiscuousMode.11 = No Such Instance currently exists at this OID
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.17.11
IF-MIB::ifConnectorPresent.11 = No Such Instance currently exists at this OID
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.18.11
IF-MIB::ifAlias.11 = STRING: TO UNIVERSE
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.19.11
IF-MIB::ifCounterDiscontinuityTime.11 = No more variables left in this MIB View (It is past the end of the MIB tree)
[root@TeguhLab data]#

4. Create bash script to runing sample output OID
[root@TeguhLab data]# cat allinterface.sh
echo ""
echo ".::: ifEntry counter 32 bit :::."
echo ""
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.1.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.2.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.3.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.4.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.5.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.6.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.7.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.8.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.9.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.10.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.11.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.12.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.13.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.14.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.15.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.16.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.17.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.18.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.19.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.20.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.21.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.2.2.1.22.11
echo ""
echo ".::: ifXEntry counter 64 bit :::."
echo ""
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.1.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.2.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.3.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.4.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.5.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.6.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.7.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.8.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.9.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.10.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.11.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.12.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.13.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.14.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.15.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.16.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.17.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.18.11
snmpwalk -v 2c -c public 10.10.10.10 .1.3.6.1.2.1.31.1.1.1.19.11
[root@TeguhLab data]#


5. Running bash script to show output snmpwalk
[root@TeguhLab data]# ./allinterface.sh

.::: ifEntry counter 32 bit :::.

IF-MIB::ifIndex.11 = INTEGER: 11
IF-MIB::ifDescr.11 = STRING: ether11
IF-MIB::ifType.11 = INTEGER: ethernetCsmacd(6)
IF-MIB::ifMtu.11 = INTEGER: 1500
IF-MIB::ifSpeed.11 = Gauge32: 1000000000
IF-MIB::ifPhysAddress.11 = STRING: e4:8d:8c:2c:9c:c3
IF-MIB::ifAdminStatus.11 = INTEGER: up(1)
IF-MIB::ifOperStatus.11 = INTEGER: up(1)
IF-MIB::ifLastChange.11 = Timeticks: (0) 0:00:00.00
IF-MIB::ifInOctets.11 = Counter32: 2584645437
IF-MIB::ifInUcastPkts.11 = Counter32: 1239091521
IF-MIB::ifInNUcastPkts.11 = Counter32: 0
IF-MIB::ifInDiscards.11 = Counter32: 0
IF-MIB::ifInErrors.11 = Counter32: 0
IF-MIB::ifInUnknownProtos.11 = Counter32: 0
IF-MIB::ifOutOctets.11 = Counter32: 570732626
IF-MIB::ifOutUcastPkts.11 = Counter32: 3140008380
IF-MIB::ifOutNUcastPkts.11 = Counter32: 0
IF-MIB::ifOutDiscards.11 = Counter32: 0
IF-MIB::ifOutErrors.11 = Counter32: 0
IF-MIB::ifOutQLen.11 = Gauge32: 0
IF-MIB::ifSpecific.11 = OID: SNMPv2-SMI::zeroDotZero

.::: ifXEntry counter 64 bit :::.

IF-MIB::ifName.11 = STRING: ether11
IF-MIB::ifInMulticastPkts.11 = Counter32: 0
IF-MIB::ifInBroadcastPkts.11 = Counter32: 0
IF-MIB::ifOutMulticastPkts.11 = Counter32: 0
IF-MIB::ifOutBroadcastPkts.11 = Counter32: 0
IF-MIB::ifHCInOctets.11 = Counter64: 115163549587375
IF-MIB::ifHCInUcastPkts.11 = Counter64: 95728377200
IF-MIB::ifHCInMulticastPkts.11 = Counter64: 0
IF-MIB::ifHCInBroadcastPkts.11 = Counter64: 0
IF-MIB::ifHCOutOctets.11 = Counter64: 33290862619295
IF-MIB::ifHCOutUcastPkts.11 = Counter64: 71859489278
IF-MIB::ifHCOutMulticastPkts.11 = Counter64: 0
IF-MIB::ifHCOutBroadcastPkts.11 = Counter64: 0
IF-MIB::ifLinkUpDownTrapEnable.11 = No Such Instance currently exists at this OID
IF-MIB::ifHighSpeed.11 = Gauge32: 1000
IF-MIB::ifPromiscuousMode.11 = No Such Instance currently exists at this OID
IF-MIB::ifConnectorPresent.11 = No Such Instance currently exists at this OID
IF-MIB::ifAlias.11 = STRING: TO UNIVERSE
IF-MIB::ifCounterDiscontinuityTime.11 = No more variables left in this MIB View (It is past the end of the MIB tree)
[root@TeguhLab data]#

.::: Different Output OID ifDescr & ifAlias :::.

$
0
0
1. Different ifDescr, ifName & ifAlias
ifDescr OBJECT-TYPE
    SYNTAX      DisplayString (SIZE (0..255))
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "A textual string containing information about the
            interface.  This string should include the name of the
            manufacturer, the product name and the version of the
            interface hardware/software."
    ::= { ifEntry 2 }

ifAlias   OBJECT-TYPE
    SYNTAX      DisplayString (SIZE(0..64))
    MAX-ACCESS  read-write
    STATUS      current
    DESCRIPTION
            "This object is an 'alias' name for the interface as
            specified by a network manager, and provides a non-volatile
            'handle' for the interface.

            On the first instantiation of an interface, the value of
            ifAlias associated with that interface is the zero-length
            string.  As and when a value is written into an instance of
            ifAlias through a network management set operation, then the
            agent must retain the supplied value in the ifAlias instance
            associated with the same interface for as long as that
            interface remains instantiated, including across all re-
            initializations/reboots of the network management system,
            including those which result in a change of the interface's
            ifIndex value.

            An example of the value which a network manager might store
            in this object for a WAN interface is the (Telco's) circuit
            number/identifier of the interface.

            Some agents may support write-access only for interfaces
            having particular values of ifType.  An agent which supports
            write access to this object is required to keep the value in
            non-volatile storage, but it may limit the length of new
            values depending on how much storage is already occupied by
            the current values for other interfaces."
    ::= { ifXEntry 18 }

ifName OBJECT-TYPE
    SYNTAX      DisplayString
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
            "The textual name of the interface.  The value of this
            object should be the name of the interface as assigned by
            the local device and should be suitable for use in commands
            entered at the device's `console'.  This might be a text
            name, such as `le0' or a simple port number, such as `1',
            depending on the interface naming syntax of the device.  If
            several entries in the ifTable together represent a single
            interface as named by the device, then each will have the
            same value of ifName.  Note that for an agent which responds
            to SNMP queries concerning an interface on some other
            (proxied) device, then the value of ifName for such an
            interface is the proxied device's local name for it.

            If there is no local name, or this object is otherwise not
            applicable, then this object contains a zero-length string."
    ::= { ifXEntry 1 }


2. OID ifDescr & ifAlias
1.3.6.1.2.1.2.2.1.2     ifDescr LEAF  DisplayString
1.3.6.1.2.1.31.1.1.1.18 ifAlias LEAF  DisplayString
1.3.6.1.2.1.31.1.1.1.1  ifName  LEAF  DisplayString

3. Sample Run snmpwalk
[root@TeguhLab data]# echo ".::: Sample Server1 :::."
.::: Sample Server1 :::.
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.2.1.2.2.1.2.12
IF-MIB::ifDescr.12 = STRING: to_SAM, IP interface
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.2.1.31.1.1.1.18.12
IF-MIB::ifAlias.12 = STRING: IP interface
[root@TeguhLab data]# snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.2.1.31.1.1.1.1.12
IF-MIB::ifName.12 = STRING: to_SAM
[root@TeguhLab data]# echo ""

[root@TeguhLab data]# echo ".::: Sample Server2 :::."
.::: Sample Server2 :::.
[root@TeguhLab data]# snmpwalk -v 2c -c teguht 10.10.10.20 1.3.6.1.2.1.2.2.1.2.11
IF-MIB::ifDescr.11 = STRING: ether11
[root@TeguhLab data]# snmpwalk -v 2c -c teguht 10.10.10.20 1.3.6.1.2.1.31.1.1.1.18.11
IF-MIB::ifAlias.11 = STRING: TO FW INTERNET
[root@TeguhLab data]# snmpwalk -v 2c -c teguht 10.10.10.20 1.3.6.1.2.1.31.1.1.1.1.11
IF-MIB::ifName.11 = STRING: ether11
[root@TeguhLab data]#

4. Sample Run script snmpwalk
[root@TeguhLab data]# cat diff.sh
echo ".::: Sample Server1 :::."
snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.2.1.2.2.1.2.12
snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.2.1.31.1.1.1.18.12
snmpwalk -v 2c -c public 10.10.10.10 1.3.6.1.2.1.31.1.1.1.1.12
echo ""
echo ".::: Sample Server2 :::."
snmpwalk -v 2c -c teguht 10.10.10.20 1.3.6.1.2.1.2.2.1.2.11
snmpwalk -v 2c -c teguht 10.10.10.20 1.3.6.1.2.1.31.1.1.1.18.11
snmpwalk -v 2c -c teguht 10.10.10.20 1.3.6.1.2.1.31.1.1.1.1.11

[root@TeguhLab data]# ./diff.sh
.::: Sample Server1 :::.
IF-MIB::ifDescr.12 = STRING: to_SAM, IP interface
IF-MIB::ifAlias.12 = STRING: IP interface
IF-MIB::ifName.12 = STRING: to_SAM

.::: Sample Server2 :::.
IF-MIB::ifDescr.11 = STRING: ether11
IF-MIB::ifAlias.11 = STRING: TO FW INTERNET
IF-MIB::ifName.11 = STRING: ether11
[root@TeguhLab data]#

.::: How To Install Cacti On Linux :::.

$
0
0
Cacti is a complete frontend to RRDTool, it stores all of the necessary information to create graphs and populate them with data in a MySQL database. The frontend is completely PHP driven. Along with being able to maintain Graphs, Data Sources, and Round Robin Archives in a database, cacti handles the data gathering. There is also SNMP support for those used to creating traffic graphs with MRTG.

Note : using mysql 5.1.73 & cacti 0.8.8.b

1. Disable SE Linux
[root@TeguhLab ~]# cat /etc/selinux/config

# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#     enforcing - SELinux security policy is enforced.
#     permissive - SELinux prints warnings instead of enforcing.
#     disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
#     targeted - Targeted processes are protected,
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted

[root@TeguhLab ~]#

2. Disable firewall
[root@TeguhLab /]# service iptables stop
iptables: Setting chains to policy ACCEPT: filter          [  OK  ]
iptables: Flushing firewall rules:                         [  OK  ]
iptables: Unloading modules:                               [  OK  ]
[root@TeguhLab /]# chkconfig iptables off
[root@TeguhLab ~]# service iptables status
iptables: Firewall is not running.
[root@TeguhLab ~]#
3. Configure hosts
[root@TeguhLab /]# cat /etc/hosts
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
10.10.10.10 TeguhLab
[root@TeguhLab /]#

4. Install Package patch & wget
[root@TeguhLab data]# rpm -q a wget
wget-1.12-10.el6.x86_64
[root@TeguhLab data]# rpm -q  patch
patch-2.6-6.el6.x86_64
[root@TeguhLab data]#

5. Install package cacti & snmp
yum -y install mysql-server mysql php-mysql php-pear php-common php-gd php-devel php php-mbstring php-cli php-snmp php-pear-Net-SMTP php-mysql httpd
yum -y install net-snmp-utils php-snmp net-snmp-libs
rpm -q  mysql-server mysql php-mysql php-pear php-common php-gd php-devel php php-mbstring php-cli php-snmp php-pear-Net-SMTP php-mysql httpd
rpm -q  install net-snmp-utils php-snmp net-snmp-libs

[root@TeguhLab data]# rpm -q  mysql-server mysql php-mysql php-pear php-common php-gd php-devel php php-mbstring php-cli php-snmp php-pear-Net-SMTP php-mysql httpd
mysql-server-5.1.73-8.el6_8.x86_64
mysql-5.1.73-8.el6_8.x86_64
php-mysql-5.3.3-49.el6.x86_64
php-pear-1.9.4-5.el6.noarch
php-common-5.3.3-49.el6.x86_64
php-gd-5.3.3-49.el6.x86_64
php-devel-5.3.3-49.el6.x86_64
php-5.3.3-49.el6.x86_64
php-mbstring-5.3.3-49.el6.x86_64
php-cli-5.3.3-49.el6.x86_64
php-snmp-5.3.3-49.el6.x86_64
package php-pear-Net-SMTP is not installed
php-mysql-5.3.3-49.el6.x86_64
httpd-2.2.15-60.el6.centos.4.x86_64
[root@TeguhLab data]# rpm -q  install net-snmp-utils php-snmp net-snmp-libs
package install is not installed
net-snmp-utils-5.5-60.el6.x86_64
php-snmp-5.3.3-49.el6.x86_64
net-snmp-libs-5.5-60.el6.x86_64
[root@TeguhLab data]#

6. Download rpm cacti

https://centos.pkgs.org/6/repoforge-x86_64/rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm.html

wget http://ftp.tu-chemnitz.de/pub/linux/dag/redhat/el6/en/x86_64/rpmforge/RPMS/rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm

[root@TeguhLab data]# ls
[root@TeguhLab data]# wget http://ftp.tu-chemnitz.de/pub/linux/dag/redhat/el6/en/x86_64/rpmforge/RPMS/rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm
--2017-08-01 15:30:23--  http://ftp.tu-chemnitz.de/pub/linux/dag/redhat/el6/en/x86_64/rpmforge/RPMS/rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm
Resolving ftp.tu-chemnitz.de... 134.109.228.1, 2001:638:911:b0e:134:109:228:1
Connecting to ftp.tu-chemnitz.de|134.109.228.1|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 12640 (12K) [application/octet-stream]
Saving to: “rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm”

100%[========================================================================================>] 12,640      2.86K/s   in 4.3s  

2017-08-01 15:30:31 (2.86 KB/s) - “rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm” saved [12640/12640]

[root@TeguhLab data]# ls
rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm
[root@TeguhLab data]#

7. Install cacti
rpm -ivh rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm

yum -y install cacti
rpm -ql cacti | grep cacti.sql

[root@TeguhLab data]# rpm -ivh rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm
[root@TeguhLab data]# yum -y install  cacti
cacti-0.8.8b-1.el6.rf.noarch
[root@TeguhLab data]# rpm -ql cacti | grep cacti.sql
 [root@TeguhLab data]#

8. Konfigurasi MySQL server
[root@TeguhLab data]# chkconfig mysqld on
[root@TeguhLab data]# service mysqld status
mysqld is stopped
[root@TeguhLab data]# service mysqld start
Initializing MySQL database:  Installing MySQL system tables...
OK
Filling help tables...
OK

To start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:

/usr/bin/mysqladmin -u root password 'new-password'
/usr/bin/mysqladmin -u root -h TeguhLab password 'new-password'

Alternatively you can run:
/usr/bin/mysql_secure_installation

which will also give you the option of removing the test
databases and anonymous user created by default.  This is
strongly recommended for production servers.

See the manual for more instructions.

You can start the MySQL daemon with:
cd /usr ; /usr/bin/mysqld_safe &

You can test the MySQL daemon with mysql-test-run.pl
cd /usr/mysql-test ; perl mysql-test-run.pl

Please report any problems with the /usr/bin/mysqlbug script!

                                                           [  OK  ]
Starting mysqld:                                           [  OK  ]
[root@TeguhLab data]#

mysqladmin -u root password 'root'
[root@TeguhLab data]# mysqladmin -u root password 'root'
[root@TeguhLab data]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 3
Server version: 5.1.73 Source distribution

Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql>

9. Create user database for cacti
create user 'cactiuser' identified by 'cactipwd';
create database cacti;
grant all privileges on cacti.* to 'cactiuser'@'%' identified by 'cactipwd' with grant option;
FLUSH PRIVILEGES;
create user 'cactiuser' identified by 'cactipwd';
create database cacti;
GRANT ALL ON cacti.* TO cactiuser@localhost IDENTIFIED BY 'cactipwd';
FLUSH PRIVILEGES;

[root@TeguhLab data]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 3
Server version: 5.1.73 Source distribution

Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> create user 'cactiuser' identified by 'cactipwd';
Query OK, 0 rows affected (0.01 sec)

mysql> create database cacti;
Query OK, 1 row affected (0.00 sec)

mysql> grant all privileges on cacti.* to 'cactiuser'@'%' identified by 'cactipwd' with grant option;
Query OK, 0 rows affected (0.00 sec)

mysql> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.00 sec)

mysql> create user 'cactiuser' identified by 'cactipwd';
ERROR 1396 (HY000): Operation CREATE USER failed for 'cactiuser'@'%'
mysql> create database cacti;
ERROR 1007 (HY000): Can't create database 'cacti'; database exists
mysql> GRANT ALL ON cacti.* TO cactiuser@localhost IDENTIFIED BY 'cactipwd';
Query OK, 0 rows affected (0.00 sec)

mysql> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.00 sec)

mysql> exit
Bye
[root@TeguhLab data]#


10. Konfigurasi snmpd
[root@TeguhLab data]# chkconfig snmpd on
[root@TeguhLab data]# vi /etc/snmp/snmpd.conf
[root@TeguhLab data]# cat /etc/snmp/snmpd.conf | grep systemview
view    systemview    included   .1.3.6.1.2.1.1
view    systemview    included   .1.3.6.1.2.1.25.1.1
view    systemview    included   .1
# Finally, grant the group read-only access to the systemview view.
access  notConfigGroup ""      any       noauth    exact  systemview none none
# Finally, grant the group read-only access to the systemview view.
[root@TeguhLab data]# service snmpd restart
Stopping snmpd:                                            [FAILED]
Starting snmpd:                                            [  OK  ]
[root@TeguhLab data]#

11. Konfigurasi database Cacti
[root@TeguhLab data]# rpm -ql cacti | grep cacti.sql
/var/www/cacti/cacti.sql
[root@TeguhLab data]# mysql -u cactiuser -p cacti < /var/www/cacti/cacti.sql
Enter password:
[root@TeguhLab data]#

12. Konfigurasi Cacti
[root@TeguhLab data]# vi /var/www/cacti/include/config.php
[root@TeguhLab data]#
[root@TeguhLab data]# cat /var/www/cacti/include/config.php | grep database
/* make sure these values refect your actual database/host/user/password */
$database_type = "mysql";
$database_default = "cacti";
$database_hostname = "localhost";
$database_username = "cactiuser";
$database_password = "cactipwd";
$database_port = "3306";
$database_ssl = false;
[root@TeguhLab data]#

13. Konfigurasi httpd
[root@TeguhLab data]# vi /etc/httpd/conf.d/cacti.conf
[root@TeguhLab data]# cat /etc/httpd/conf.d/cacti.conf
Alias /cacti/ /var/www/cacti/
<Directory /var/www/cacti/>
    DirectoryIndex index.php
    Options -Indexes
    AllowOverride all
    order deny,allow
    deny from all
    allow from 10.0.0.0/8
    allow from all
    AddType application/x-httpd-php .php
    php_flag magic_quotes_gpc on
    php_flag track_vars on
</Directory>

if you not sertting, will error as
Forbidden

You don't have permission to access /cacti/ on this server.
Apache/2.2.15 (CentOS) Server at 10.10.10.10 Port 80

[root@TeguhLab data]#
[root@TeguhLab data]# vi /etc/httpd/conf/httpd.conf
[root@TeguhLab data]# cat /etc/httpd/conf/httpd.conf | grep ServerName
# ServerName gives the name and port that the server uses to identify itself.
#ServerName www.example.com:80
ServerName 127.0.0.1:80
# ServerName directive.
#    ServerName dummy-host.example.com
[root@TeguhLab data]#

if you not setting, will show error
[root@TeguhLab ~]# service httpd restart
Stopping httpd:                                            [  OK  ]
Starting httpd: httpd: Could not reliably determine the server's fully qualified domain name, using 10.10.10.10 for ServerName
                                                           [  OK  ]
[root@TeguhLab ~]#

14 . Start httpd
[root@TeguhLab data]#
[root@TeguhLab data]# chkconfig httpd on
[root@TeguhLab data]# service httpd status
httpd is stopped
[root@TeguhLab data]# service httpd restart
Stopping httpd:                                            [  OK  ]
Starting httpd:                                            [  OK  ]
[root@TeguhLab data]# service httpd status
httpd (pid  7584) is running...
[root@TeguhLab data]#

15 . Konfigurasi cronjob untuk Cacti
[root@TeguhLab data]# vi /etc/cron.d/cacti
[root@TeguhLab data]# cat /etc/cron.d/cacti
#*/5 * * * *    cacti    php /var/www/cacti/poller.php &>/dev/null
*/5 * * * * cacti /usr/bin/php /var/www/cacti/poller.php > /dev/null 2>&1
[root@TeguhLab data]#

18. Running cacti.
Open browser and type using url
http://IP_cacti/cacti/
example
http://10.10.10.10/cacti/

if you fresh install or upgrade. firts run as below then next next, choose fresh install or upgrade
http://IP_cacti/cacti/install/
example
http://10.10.10.10/cacti/install/
19. Login to web browser default user : admin, password: admin

.::: How To Upgrade Cacti on Linux :::.

$
0
0
note: this cace, upgrade cacti 0.8.8.b to 0.8.8.h
1. Backup the old Cacti database
mysqldump -l --add-drop-table <db_name> -u <user> -p  > mysql.cacti
[root@TeguhLab data]# mysqldump -l --add-drop-table cacti -u root -p > mysql.cacti
Enter password:
[root@TeguhLab data]# ls
mysql.cacti  rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm
[root@TeguhLab data]# ls -lh
total 156K
-rw-r--r-- 1 root root 138K Aug  3 14:45 mysql.cacti
-rw-r--r-- 1 root root  13K Mar 20  2013 rpmforge-release-0.5.3-1.el6.rf.x86_64.rpm
[root@TeguhLab data]#


2. Backup the old Cacti directory
mv cacti cacti_old
[root@TeguhLab data]# cat /etc/httpd/conf.d/cacti.conf
Alias /cacti/ /var/www/cacti/
<Directory /var/www/cacti/>
    DirectoryIndex index.php
    Options -Indexes
    AllowOverride all
    order deny,allow
    deny from all
    allow from 10.0.0.0/8
    AddType application/x-httpd-php .php
    php_flag magic_quotes_gpc on
    php_flag track_vars on
</Directory>
[root@TeguhLab data]# cd /var/www/
[root@TeguhLab www]# ls
cacti  cgi-bin  error  html  icons
[root@TeguhLab www]# mv cacti cacti_old/
[root@TeguhLab www]# ls
cacti_old  cgi-bin  error  html  icons
[root@TeguhLab www]#


3. Download & Extract the distribution tarball.
wget https://www.cacti.net/downloads/cacti-0.8.8h.tar.gz

[root@TeguhLab www]# ls
cacti_old  cgi-bin  error  html  icons
[root@TeguhLab www]# wget https://www.cacti.net/downloads/cacti-0.8.8h.tar.gz
--2017-08-03 14:55:29--  https://www.cacti.net/downloads/cacti-0.8.8h.tar.gz
Resolving www.cacti.net... 104.28.9.127, 104.28.8.127, 2400:cb00:2048:1::681c:87f, ...
Connecting to www.cacti.net|104.28.9.127|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2585226 (2.5M) [application/x-gzip]
Saving to: “cacti-0.8.8h.tar.gz”

100%[========================================================================================>] 2,585,226    603K/s   in 4.5s   

2017-08-03 14:55:35 (561 KB/s) - “cacti-0.8.8h.tar.gz” saved [2585226/2585226]

[root@TeguhLab www]# ls
cacti-0.8.8h.tar.gz  cacti_old  cgi-bin  error  html  icons
[root@TeguhLab www]# tar -xvf cacti-0.8.8h.tar.gz
cacti-0.8.8h/
............
[root@TeguhLab www]# ls
cacti-0.8.8h  cacti-0.8.8h.tar.gz  cacti_old  cgi-bin  error  html  icons
[root@TeguhLab www]#


4. Rename the new Cacti directory to match the old one.
mv cacti-version cacti
[root@TeguhLab www]# ls
cacti-0.8.8h  cacti-0.8.8h.tar.gz  cacti_old  cgi-bin  error  html  icons
[root@TeguhLab www]# mv cacti-0.8.8h cacti
[root@TeguhLab www]# ls
cacti  cacti-0.8.8h.tar.gz  cacti_old  cgi-bin  error  html  icons
[root@TeguhLab www]#

5.  Edit include/config.php and specify the MySQL user, password and database for your Cacti configuration.
[root@TeguhLab www]# more cacti/include/config.php
<?php
/*
 +-------------------------------------------------------------------------+
 | Copyright (C) 2004-2016 The Cacti Group                                 |
 |                                                                         |
 | This program is free software; you can redistribute it and/or           |
 | modify it under the terms of the GNU General Public License             |
 | as published by the Free Software Foundation; either version 2          |
 | of the License, or (at your option) any later version.                  |
 |                                                                         |
 | This program is distributed in the hope that it will be useful,         |
 | but WITHOUT ANY WARRANTY; without even the implied warranty of          |
 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the           |
 | GNU General Public License for more details.                            |
 +-------------------------------------------------------------------------+
 | Cacti: The Complete RRDTool-based Graphing Solution                     |
 +-------------------------------------------------------------------------+
 | This code is designed, written, and maintained by the Cacti Group. See  |
 | about.php and/or the AUTHORS file for specific developer information.   |
 +-------------------------------------------------------------------------+
 | http://www.cacti.net/                                                   |
 +-------------------------------------------------------------------------+
*/

/* make sure these values refect your actual database/host/user/password */
$database_type = "mysql";
$database_default = "cacti";
$database_hostname = "localhost";
$database_username = "cactiuser";
$database_password = "cactipwd";

$database_port = "3306";
$database_ssl = false;

/*
   Edit this to point to the default URL of your Cacti install
   ex: if your cacti install as at http://serverip/cacti/ this
   would be set to /cacti/
*/
//$url_path = "/cacti/";

/* Default session name - Session name must contain alpha characters */
//$cacti_session_name = "Cacti";

?>
[root@TeguhLab www]#

6. Copy the *.rrd files from the old Cacti directory.
 cp cacti_old/rra/* cacti/rra/
 [root@TeguhLab www]# cp cacti_old/rra/* cacti/rra
[root@TeguhLab www]#

7.  cp cacti_old/rra/* cacti/rra/
Copy any relevant custom scripts from the old Cacti directory. Some script are updated between versions. Therefore, make sure you only over write if the scripts either don't exist or are newer than the distribution's.
cp -u cacti_old/scripts/* cacti/scripts/
[root@TeguhLab www]# cp -u cacti_old/script/* cacti/script/
cp: cannot stat `cacti_old/script/*': No such file or directory
[root@TeguhLab www]#

8.  Copy any relevant custom resource XML files from the old Cacti directory. Some resource XML files are updated between versions. Therefore, make sure you only over write if the XML files either don't exist or are newer than the distribution's.

shell> cp -u -R cacti_old/resource/* cacti/resource/
[root@TeguhLab www]# cp -u -Rf cacti_old/resource/* cacti/resource/
cp: overwrite `cacti/resource/script_queries/unix_disk.xml'? y
cp: overwrite `cacti/resource/script_queries/host_cpu.xml'? y
cp: overwrite `cacti/resource/script_server/host_disk.xml'? y
cp: overwrite `cacti/resource/script_server/host_cpu.xml'? y
cp: overwrite `cacti/resource/snmp_queries/netware_disk.xml'? y
cp: overwrite `cacti/resource/snmp_queries/net-snmp_disk.xml'? y
cp: overwrite `cacti/resource/snmp_queries/netware_cpu.xml'? y
cp: overwrite `cacti/resource/snmp_queries/kbridge.xml'? y
cp: overwrite `cacti/resource/snmp_queries/interface.xml'? y
cp: overwrite `cacti/resource/snmp_queries/host_disk.xml'? y
[root@TeguhLab www]#

9.  Set the appropriate permissions on Cacti's directories for graph/log generation. You should execute these commands from inside Cacti's directory to change the permissions.

shell> chown -R cactiuser rra/ log
[root@TeguhLab www]# chmod -R 777 cacti/rra cacti/log
[root@TeguhLab www]#

10.  Point your web browser to: & select upgrade

    http://your-server/cacti/  or http://your-server/cacti/install/
http://10.10.10.10/cacti/  or http://10.10.10.10/cacti/install/ and next next

11.then login

    12. Cacti version upgrade

.::: Troubleshoot MySQL is not running, but lock file (/var/lock/subsys/mysql[FAILED] :::.

$
0
0
1. Problem MySQL cannot start & tried restart
[root@TeguhLab ~]# service mysql status
MySQL is not running, but lock file (/var/lock/subsys/mysql[FAILED]
[root@TeguhLab ~]# service mysql restart
MySQL server PID file could not be found!                  [FAILED]
Starting MySQL.The server quit without updating PID file (/[FAILED]mysql/TeguhLab.pid).
[root@TeguhLab ~]#

result "MySQL is not running, but lock file (/var/lock/subsys/mysql[FAILED]"

2. Cek log MySQL on MyDonain.err

[root@TeguhLab ~]# cd /var/lib/mysql
[root@TeguhLab mysql]# ls
cacti  ibdata1  ib_logfile0  ib_logfile1  mysql  RPM_UPGRADE_HISTORY  RPM_UPGRADE_MARKER-LAST  TeguhLab.err  test
[root@TeguhLab mysql]# cat /var/lib/mysql/TeguhLab.err

170809 15:30:31 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
2017-08-09 15:30:31 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp
server option (see documentation for more details).
2017-08-09 15:30:31 0 [Note] /usr/sbin/mysqld (mysqld 5.6.34) starting as process 5289 ...
2017-08-09 15:30:31 5289 [Note] Plugin 'FEDERATED' is disabled.
2017-08-09 15:30:31 5289 [Note] InnoDB: Using atomics to ref count buffer pool pages
2017-08-09 15:30:31 5289 [Note] InnoDB: The InnoDB memory heap is disabled
2017-08-09 15:30:31 5289 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-08-09 15:30:31 5289 [Note] InnoDB: Memory barrier is not used
2017-08-09 15:30:31 5289 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-08-09 15:30:31 5289 [Note] InnoDB: Using Linux native AIO
2017-08-09 15:30:31 5289 [Note] InnoDB: Using CPU crc32 instructions
2017-08-09 15:30:31 5289 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2017-08-09 15:30:31 5289 [Note] InnoDB: Completed initialization of buffer pool
2017-08-09 15:30:31 5289 [ERROR] InnoDB: auto-extending data file ./ibdata1 is of a different size 640 pages (rounded down to MB)
than specified in the .cnf file: initial 768 pages, max 0 (relevant if non-zero) pages!
2017-08-09 15:30:31 5289 [ERROR] InnoDB: Could not open or create the system tablespace. If you tried to add new data files to the
 system tablespace, and it failed here, you should now edit innodb_data_file_path in my.cnf back to what it was, and remove the ne
w ibdata files InnoDB created in this failed attempt. InnoDB only wrote those files full of zeros, but did not yet use them in any
 way. But be careful: do not remove old data files which contain your precious data!
2017-08-09 15:30:31 5289 [ERROR] Plugin 'InnoDB' init function returned error.
2017-08-09 15:30:31 5289 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2017-08-09 15:30:31 5289 [ERROR] Unknown/unsupported storage engine: InnoDB
2017-08-09 15:30:31 5289 [ERROR] Aborting

2017-08-09 15:30:31 5289 [Note] Binlog end
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'partition'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'ARCHIVE'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_SYS_FIELDS'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_SYS_INDEXES'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_SYS_TABLES'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_FT_CONFIG'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_FT_DELETED'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_METRICS'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_CMPMEM'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_CMP_RESET'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_CMP'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_LOCK_WAITS'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_LOCKS'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'INNODB_TRX'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'BLACKHOLE'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'MEMORY'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'MRG_MYISAM'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'CSV'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'MyISAM'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'sha256_password'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'mysql_old_password'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'mysql_native_password'
2017-08-09 15:30:31 5289 [Note] Shutting down plugin 'binlog'
2017-08-09 15:30:31 5289 [Note] /usr/sbin/mysqld: Shutdown complete

170809 15:30:31 mysqld_safe mysqld from pid file /var/lib/mysql/TeguhLab.pid ended


3. Focuse on problem
2017-08-09 15:30:31 5289 [ERROR] InnoDB: auto-extending data file ./ibdata1 is of a different size 640 pages (rounded down to MB)
than specified in the .cnf file: initial 768 pages, max 0 (relevant if non-zero) pages!
2017-08-09 15:30:31 5289 [ERROR] InnoDB: Could not open or create the system tablespace. If you tried to add new data files to the
 system tablespace, and it failed here, you should now edit innodb_data_file_path in my.cnf back to what it was, and remove the ne
w ibdata files InnoDB created in this failed attempt. InnoDB only wrote those files full of zeros, but did not yet use them in any
 way. But be careful: do not remove old data files which contain your precious data!

4. Delete all ib_logfile's & Delete the ibdata1 file
[root@TeguhLab ~]# cd /var/lib/mysql
[root@TeguhLab mysql]# ls
cacti  ibdata1  ib_logfile0  ib_logfile1  mysql  RPM_UPGRADE_HISTORY  RPM_UPGRADE_MARKER-LAST  TeguhLab.err  test
[root@TeguhLab mysql]# rm -rf ibdata1 ib_logfile*
[root@TeguhLab mysql]# ls
cacti  mysql  RPM_UPGRADE_HISTORY  RPM_UPGRADE_MARKER-LAST  TeguhLab.err  test
[root@TeguhLab mysql]#

5. Restart MySQL Status
[root@TeguhLab mysql]# service mysql restart
MySQL server PID file could not be found!                  [FAILED]
Starting MySQL....                                         [  OK  ]
[root@TeguhLab mysql]#

6. Login to MySQL
[root@TeguhLab mysql]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.6.34 MySQL Community Server (GPL)

Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| cacti              |
| mysql              |
| test               |
+--------------------+
4 rows in set (0.21 sec)

mysql> connect cacti;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Connection id:    2
Current database: cacti

mysql> show tables;
+---------------------------+
| Tables_in_cacti           |
+---------------------------+
| cdef                      |
| cdef_items                |
| colors                    |
| data_input                |
| data_input_data           |
| data_input_fields         |
| data_local                |
| data_template             |
| data_template_data        |
| data_template_data_rra    |
| data_template_rrd         |
| graph_local               |
| graph_template_input      |
| graph_template_input_defs |
| graph_templates           |
| graph_templates_gprint    |
| graph_templates_graph     |
| graph_templates_item      |
| graph_tree                |
| graph_tree_items          |
| host                      |
| host_graph                |
| host_snmp_cache           |
| host_snmp_query           |
| host_template             |
| host_template_graph       |
| host_template_snmp_query  |
| manage_admin_link         |
| manage_alerts             |
| manage_groups             |
| manage_host               |
| manage_poller_output      |
| manage_process            |
| manage_services           |
| manage_sites              |
| manage_tcp                |
| manage_templates          |
| manage_uptime_method      |
| plugin_config             |
| plugin_db_changes         |
| plugin_docs               |
| plugin_hooks              |
| plugin_realms             |
| poller                    |
| poller_command            |
| poller_item               |
| poller_output             |
| poller_reindex            |
| poller_time               |
| rra                       |
| rra_cf                    |
| settings                  |
| settings_graphs           |
| settings_tree             |
| snmp_query                |
| snmp_query_graph          |
| snmp_query_graph_rrd      |
| snmp_query_graph_rrd_sv   |
| snmp_query_graph_sv       |
| user_auth                 |
| user_auth_perms           |
| user_auth_realm           |
| user_log                  |
| version                   |
| weathermap_auth           |
| weathermap_data           |
| weathermap_groups         |
| weathermap_maps           |
| weathermap_settings       |
+---------------------------+
69 rows in set (0.00 sec)

mysql> exit
Bye
[root@TeguhLab mysql]#

.::: How to Check License subscription-manager RHEL(Red Hat Enterprise Linux :::.

$
0
0
Red Hat Enterprise Linux Server subscription is available at no cost for development purposes. Developers need to register for the Red Hat Developer Program and agree to licensing terms forbidding production use. This free developer subscription was announced on March 31, 2016.

There are also "Academic" editions of the Desktop and Server variants. They are offered to schools and students, are less expensive, and are provided with Red Hat technical support as an optional extra. Web support based on number of customer contacts can be purchased separately.

1. Sample command
# subscription-manager orgs
# subscription-manager refresh
# subscription-manager status
# subscription-manager list
# subscription-manager list --consume

2. command subscription-manager orgs
[root@TeguhLab ~]# subscription-manager orgs
Username: teguh.triharto@microsoft.com
Password:
+-------------------------------------------+
          teguh.triharto@microsoft.com Organizations
+-------------------------------------------+

Name: 11141234
Key:  11141234

[root@TeguhLab ~]#

3. command subscription-manager refresh
[root@TeguhLab ~]# subscription-manager refresh
Network error, unable to connect to server. Please see /var/log/rhsm/rhsm.log for more information.
[root@TeguhLab ~]#

4. command subscription-manager status
[root@TeguhLab ~]# subscription-manager status
+-------------------------------------------+
   System Status Details
+-------------------------------------------+
Overall Status: Current

[root@TeguhLab ~]#

5. command subscription-manager list
[root@TeguhLab ~]# subscription-manager list

+-------------------------------------------+
    Installed Product Status
+-------------------------------------------+
Product Name:   Red Hat Developer Toolset (for RHEL Server)
Product ID:     022
Version:        2.1
Arch:           x86_64
Status:         Subscribed
Status Details:
Starts:         03/22/2017
Ends:           03/22/2018

Product Name:   Red Hat Enterprise Linux Server
Product ID:     22
Version:        6.8
Arch:           x86_64
Status:         Subscribed
Status Details:
Starts:         03/22/2017
Ends:           03/22/2018

[root@TeguhLab ~]#

6. command subscription-manager list --consume
[root@TeguhLab ~]# subscription-manager list --consume
+-------------------------------------------+
   Consumed Subscriptions
+-------------------------------------------+
Subscription Name:   Red Hat Enterprise Linux Server, Premium (Physical or Virtual Nodes)
Provides:            Red Hat Enterprise Linux High Performance Networking (for RHEL Server) - Extended Update
                     Support
                     Oracle Java (for RHEL Server)
                     Red Hat Enterprise Linux Server - Extended Update Support
                     Red Hat Enterprise Linux Server
                     Red Hat Enterprise Linux Atomic Host
                     Red Hat EUCJP Support (for RHEL Server) - Extended Update Support
                     Oracle Java (for RHEL Server) - Extended Update Support
                     Red Hat Enterprise Linux Resilient Storage (for RHEL Server) - Extended Update Support
                     Red Hat Software Collections (for RHEL Server)
                     dotNET on RHEL Beta (for RHEL Server)
                     Red Hat Beta
                     dotNET on RHEL (for RHEL Server)
                     Red Hat Enterprise Linux Atomic Host Beta
                     Red Hat Developer Toolset (for RHEL Server)
                     Red Hat Enterprise Linux High Availability (for RHEL Server) - Extended Update Support
                     Red Hat Enterprise Linux Scalable File System (for RHEL Server) - Extended Update Support
                     Red Hat Software Collections Beta (for RHEL Server)
                     Red Hat Enterprise Linux Load Balancer (for RHEL Server) - Extended Update Support
                     Red Hat Container Images
                     Red Hat Container Images Beta
                     Red Hat S-JIS Support (for RHEL Server) - Extended Update Support
SKU:                 RH00003
Contract:            11341234
Account:             1221234
Serial:              7633643226412345678
Pool ID:             8a85f9815ad1b729015ad1e012345678
Provides Management: No
Active:              True
Quantity Used:       2
Service Level:       Premium
Service Type:        L1-L3
Status Details:      Subscription is current
Subscription Type:  
Starts:              03/22/2017
Ends:                03/22/2018
System Type:         Physical

[root@TeguhLab ~]#

7. command check rhel version
[root@TeguhLab ~]# cat /etc/redhat-release
Red Hat Enterprise Linux Server release 6.8 (Santiago)
[root@TeguhLab ~]#

.::: How To Commission & Enable SNMP an OmniSwitch Alcatel Lucent for NMS :::.

$
0
0
Before you begin. See the appropriate OmniSwitch documentation for more information about the CLI command syntax and SNMP.
Note: The NMS cannot discover an OmniSwitch that is configured with the factory default settings.
Note: You must use a direct console port connection to access an OmniSwitch for the first time. All other management methods such as SNMP, Telnet, FTP, and HTTP, are disabled until you enable them.

1. Open a console window using a direct console port connection to the OmniSwitch.
2. Create a Loopback0 interface and assign an IP address to the interface by entering
the following:
ip interface Loopback0 address xxx.xxx.xxx.xxx
where
xxx.xxx.xxx.xxx is the IP address of the interface

Note: Loopback0 is the name assigned to an IP interface to identify an address
that is used for network management purposes. The Loopback0 interface is not bound to any VLAN, therefore it always remains operationally active.
The Loopback0 interface name is case-sensitive. Ensure that you enter the name exactly as shown.
3. Enable SNMP sessions on the switch by entering the following:
aaa authentication snmp local
4. Enable FTP, Telnet, HTTP, or SSH sessions, if required, by entering the following:
aaa authentication ftp local
aaa authentication telnet local
aaa authentication http local
aaa authentication ssh local
5. Perform one of the following to configure the required version of SNMP on the switch and the NMS:
Note: The OmniSwitch default user, admin, does not have SNMP access.
Before the NMS can discover an OmniSwitch, you must create at least one user on the switch with SNMP access.
a. For SNMP v2c:
1. Configure an SNMP v2 user by entering the following:
user user_name password password no auth
user_name is a username that corresponds to an SNMP v2 user who the NMS can identify; Nokia recommends that you use the name sam, which is the NMS default name
password is a password associated with the username; the password is between 8 and 47 characters
Note:
If you need to use a different SNMPv2 default user name, create an SNMPv2 default user name on the NMS. See “To create a default SNMPv2 OmniSwitch user on a NMS system” in the NMS System Administrator Guide for information about creating an SNMPv2 default user name.

2. Configure SNMP v2 trap forwarding to the NMS by entering the following:
snmp station xxx.xxx.xxx.xxx v2 user_name
where
xxx.xxx.xxx.xxx is the IP address of the NMS main server user_name is the username that you created in 1
Note:
Trap forwarding configuration occurs automatically when the NMS discovers a switch and uses the default SNMP v2 user name sam or the user name configured, if any.
3. Configure an SNMP security level that allows the switch to accept all SNMP queries by entering the following:
snmp security no security
4. Configure an SNMP v2 community string by entering the following:
snmp community map community_string user user_name
where
community_string is the name of an SNMP v2 community string that the 5620 SAM can identify user_name is the SNMP v2 username created in 1

A. Example configuration Omni Switch
IP Loopback= 10.10.10.10
IP Management = 10.10.10.100
Hostname   = TeguhRouter
IP NMS        = 10.10.10.20
SNMP= public
User Password Local = teguh / teguh-keren

TeguhRouter# show configuration snapshot ip 
! IP :
ip service all
ip interface "Management_IP" address 10.10.10.100 mask 255.255.255.240 vlan 22 ifindex 1
ip interface "Loopback0" address 10.10.10.10
ip managed-interface "Management_IP" application tacacs
ip managed-interface "Management_IP" application syslog
ip managed-interface "Management_IP" application radius
TeguhRouter#

TeguhRouter# show user teguh
User name = teguh,
  Password expiration     = None,
  Password allow to be modified date     = None,
  Account lockout     = None,
  Password bad attempts     = 0,
  Read Only for domains   = None,
  Read/Write for domains  = All ,
  Snmp allowed     = YES,
  Snmp authentication     = NONE,
  Snmp encryption     = NONE,
  Console-Only    = Disabled
TeguhRouter#
TeguhRouter# show configuration snapshot snmp
! SNMP :
snmp security no security
snmp authentication trap enable
snmp community map "public" user "teguh" on
snmp station 10.10.10.20 "teguh" v2 enable
user teguh password teguh-keren no auth

TeguhRouter# show configuration snapshot aaa
! AAA :
aaa authentication console "local"
aaa authentication telnet "local"
aaa authentication ftp "local"
aaa authentication http "local"
aaa authentication snmp "local"
aaa authentication ssh "local"
! PARTM :
! AVLAN :
! 802.1x :
TeguhRouter# exit

B. Example snmpwalk
1. Check IP Server

[root@TeguhLab ~]# ifconfig -a
eth0      Link encap:Ethernet  HWaddr 00:0C:29:8B:BC:49 
          inet addr:10.10.10.20  Bcast:10.10.10.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fe8b:bc49/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:3629526 errors:0 dropped:0 overruns:0 frame:0
          TX packets:18684 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:257358978 (245.4 MiB)  TX bytes:4953130 (4.7 MiB)

lo        Link encap:Local Loopback 
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:1606 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1606 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:110778 (108.1 KiB)  TX bytes:110778 (108.1 KiB)

[root@TeguhLab ~]#

2. Running snmpwalk
example
snmpwalk -v2c -c public 10.10.10.10 sysDescr
snmpwalk -v2c -c public 10.10.10.10 1.3.6.1.2.1.1

result
[root@TeguhLab ~]# snmpwalk -v2c -c public 10.10.10.10 sysDescr
SNMPv2-MIB::sysDescr.0 = STRING: Alcatel-Lucent Enterprise OS6860-24 8.3.1.314.R01 GA, September 07, 2016.
[root@TeguhLab ~]#
[root@TeguhLab ~]# snmpwalk -v2c -c public 10.10.10.10 1.3.6.1.2.1.1
SNMPv2-MIB::sysDescr.0 = STRING: Alcatel-Lucent Enterprise OS6860-24 8.3.1.314.R01 GA, September 07, 2016.
SNMPv2-MIB::sysObjectID.0 = OID: SNMPv2-SMI::enterprises.6486.801.1.1.2.1.11.1.1
DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (2644111034) 306 days, 0:45:10.34
SNMPv2-MIB::sysContact.0 = STRING: Alcatel-Lucent, http://enterprise.alcatel-lucent.com
SNMPv2-MIB::sysName.0 = STRING: OS6860
SNMPv2-MIB::sysLocation.0 = STRING: Unknown
SNMPv2-MIB::sysServices.0 = INTEGER: 78
SNMPv2-MIB::sysORID.1 = OID: SNMP-VIEW-BASED-ACM-MIB::vacmBasicGroup
SNMPv2-MIB::sysORID.2 = OID: SNMP-FRAMEWORK-MIB::snmpFrameworkMIBCompliance
SNMPv2-MIB::sysORID.3 = OID: SNMP-MPD-MIB::snmpMPDCompliance
SNMPv2-MIB::sysORID.4 = OID: SNMP-USER-BASED-SM-MIB::usmMIBCompliance
SNMPv2-MIB::sysORID.5 = OID: SNMP-VIEW-BASED-ACM-MIB::vacmBasicGroup
SNMPv2-MIB::sysORDescr.1 = STRING: View-based Access Control Model for SNMP.
SNMPv2-MIB::sysORDescr.2 = STRING: The SNMP Management Architecture MIB.
SNMPv2-MIB::sysORDescr.3 = STRING: The MIB for Message Processing and Dispatching.
SNMPv2-MIB::sysORDescr.4 = STRING: The management information definitions for the SNMP User-based Security Model.
SNMPv2-MIB::sysORDescr.5 = STRING: View-based Access Control Model for SNMP.
SNMPv2-MIB::sysORUpTime.1 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.2 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.3 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.4 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.5 = Timeticks: (0) 0:00:00.00
[root@TeguhLab ~]#


.::: How To Enable SNMP on Alcatel Lucent Router(7750, 7710, 7705,7750) :::.

$
0
0

1. Check snmpwalk router
# snmpwalk -v2c -c teguht 10.10.10.10 sysDescr
# snmpwalk -v2c -c teguht 10.10.10.10 1.3.6.1.2.1.1

[root@TeguhLab ~]# snmpwalk -v2c -c teguht 10.10.10.10 sysDescr
Timeout: No Response from 10.10.10.10
[root@TeguhLab ~]# snmpwalk -v2c -c teguht 10.10.10.10 1.3.6.1.2.1.1
Timeout: No Response from 10.10.10.10
[root@TeguhLab ~]#

2. Check configurasi SNMP router
# show system information
# show system information | match SNMP
# show system security snmp community

*A:TeguhRouter# show system information | match SNMP
SNMP Port              : 161
SNMP Engine ID         : 0000197f000000233e909999
SNMP Engine Boots      : 414
SNMP Max Message Size  : 9216
SNMP Admin State       : Disabled
SNMP Oper State        : Disabled
SNMP Index Boot Status : Persistent
SNMP Sync State        : N/A
*A:TeguhRouter#

*A:TeguhRouter# show system security snmp community

==============================================================================
Communities
==============================================================================
community           access  view                version   group name
------------------------------------------------------------------------------
cli-li-readwrite    n/a     li-view             v2c       cli-li-readwrite
cli-readonly        r       iso                 v2c       cli-readonly
cli-readwrite       rw      iso                 v2c       cli-readwrite
public              r       no-security         v1 v2c    snmp-ro
publictrap98        n/a     n/a                 v2c       snmp-trap
------------------------------------------------------------------------------
No. of Communities: 7
==============================================================================
*A:TeguhRouter#

3. configuration snmp community
*A:TeguhRouter# configure system security snmp
*A:TeguhRouter>config>system>security>snmp# community teguht rwa version v2c
*A:TeguhRouter>config>system>security>snmp# info
----------------------------------------------
                community "Lla.RtAyRW2" hash2 r version both
                community "ZqKPmovL8ik" hash2 rwa version v2c
----------------------------------------------
*A:TeguhRouter>config>system>security>snmp#
*A:TeguhRouter>config>system>security>snmp# exit all
*A:TeguhRouter#

4. Enable snmp community
*A:TeguhRouter# configure system snmp no shutdown
*A:TeguhRouter# show system information | match SNMP
SNMP Port              : 161
SNMP Engine ID         : 0000197f000000233e909999
SNMP Engine Boots      : 414
SNMP Max Message Size  : 9216
SNMP Admin State       : Enabled
SNMP Oper State        : Enabled
SNMP Index Boot Status : Persistent
SNMP Sync State        : N/A
*A:TeguhRouter#

5. check snmp community
# show system information
# show system information | match SNMP
# show system security snmp community
*A:TeguhRouter# show system security snmp community

==============================================================================
Communities
==============================================================================
community           access  view                version   group name
------------------------------------------------------------------------------
cli-li-readwrite    n/a     li-view             v2c       cli-li-readwrite
cli-readonly        r       iso                 v2c       cli-readonly
cli-readwrite       rw      iso                 v2c       cli-readwrite
public              r       no-security         v1 v2c    snmp-ro
publictrap98        n/a     n/a                 v2c       snmp-trap
teguht              rwa     iso                 v2c       snmp-rwa
------------------------------------------------------------------------------
No. of Communities: 8
==============================================================================
*A:TeguhRouter#

6. snmpwalk from server NMS or other snmp tool
# snmpwalk -v2c -c teguht 10.10.10.10 sysDescr
# snmpwalk -v2c -c teguht 10.10.10.10 1.3.6.1.2.1.1

[root@TeguhLab data]# snmpwalk -v2c -c teguht 10.10.10.10 sysDescr
SNMPv2-MIB::sysDescr.0 = STRING: TiMOS-C-14.0.R7 cpm/hops64 Nokia 7750 SR Copyright (c) 2000-2017 Nokia.
All rights reserved. All use subject to applicable license agreements.
Built on Thu Jan 12 12:38:16 PST 2017 by builder in /rel14.0/b1/R7/panos/main

[root@TeguhLab data]# snmpwalk -v2c -c teguht 10.10.10.10 1.3.6.1.2.1.1
SNMPv2-MIB::sysDescr.0 = STRING: TiMOS-C-14.0.R7 cpm/hops64 Nokia 7750 SR Copyright (c) 2000-2017 Nokia.
All rights reserved. All use subject to applicable license agreements.
Built on Thu Jan 12 12:38:16 PST 2017 by builder in /rel14.0/b1/R7/panos/main

SNMPv2-MIB::sysObjectID.0 = OID: SNMPv2-SMI::enterprises.6527.1.3.4
DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (25653168) 2 days, 23:15:31.68
SNMPv2-MIB::sysContact.0 = STRING:
SNMPv2-MIB::sysName.0 = STRING: TeguhRouter
SNMPv2-MIB::sysLocation.0 = STRING:
SNMPv2-MIB::sysServices.0 = INTEGER: 79
[root@TeguhLab data]#

.::: How To Install Demo DigitalRoute Mediationzone on Linux Rhel :::.

$
0
0
DigitalRoute has been providing new approaches to data integration and management since 1999. Its technology offers high throughput and provides a unique degree of user configurability, processing all usage and statistical data extracted from the networks, including both billable and non-billable events. This means customers gain greater cost efficiencies, improved times-to-market for new service offerings, the ability to monetize any data, and the means to enhance end-customer satisfaction. DigitalRoute makes network events available to the right systems in the right formats in the most appropriate volumes at the required times, without losing a single bit. This is the foundation from which multiple, mission-critical use-cases can be addressed in the areas of Billing Mediation, OSS Mediation, Online Control and Enterprise Data Processing.

Study case Plan Configuration example
IP Server = 10.10.10.10
Hostname  = TeguhLab
Company   = Teguh Triharto Corporation
mz.container = platform1
install.str.config-script = scripts/str-templates/basic.sh
install.security = false
mz.home = /opt/mz80

Environment :
export MZ_HOME=/opt/mz80
export JAVA_HOME=/usr/java/jdk1.8.0_144
export PATH=$JAVA_HOME/bin:$MZ_HOME/bin:$PATH

Install Demo DigitalRoute Mediationzone on Linux Rhel 6 for example

1. Disable SE Linux and them reboot
[root@TeguhLab ~]# cat /etc/selinux/config | grep SELINUX
# SELINUX= can take one of these three values:
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
SELINUXTYPE=targeted

[root@TeguhLab ~]#

2. Disable firewall
[root@TeguhLab /]# service iptables stop
iptables: Setting chains to policy ACCEPT: filter          [  OK  ]
iptables: Flushing firewall rules:                         [  OK  ]
iptables: Unloading modules:                               [  OK  ]
[root@TeguhLab /]# chkconfig iptables off
[root@TeguhLab ~]# service iptables status
iptables: Firewall is not running.
[root@TeguhLab ~]#
3. Configure hosts
[root@TeguhLab /]# cat /etc/hosts
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
10.10.10.10 TeguhLab
[root@TeguhLab /]#

4. Download java SDK
go to http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html and download example Linux x64    162.1 MB      jdk-8u144-linux-x64.rpm
wget http://download.oracle.com/otn-pub/java/jdk/8u144-b01/090f390dda5b47b9b721c7dfaa008135/jdk-8u144-linux-x64.rpm?AuthParam=1503303064_901b67a6dcd3c59329114d2bf10f39db

5. Make sure Server connet to Internet or you can using repolocal or iso file

6. install jdk-8u144-linux-x64.rpm
 # rpm -ivh jdk-8u144-linux-x64.rpm
 or
 # yum -y install jdk-8u144-linux-x64.rpm

7. create user mzadmin and directory /opt/mz80
# useradd mzadmin
# cd /opt/
# mkdir mz80
# chown mzadmin:mzadmin mz80/
# ls -lh
chown mzadmin:mzadmin mz80/
[root@trial data]# cd /opt/
[root@trial opt]# mkdir mz80
[root@trial opt]# chown mzadmin:mzadmin mz80/
[root@trial opt]# ls -lh
total 8.0K
drwxr-xr-x  2 mzadmin mzadmin 4.0K Aug 28 13:40 mz80
drwxr-xr-x. 2 root    root    4.0K Mar 11  2015 rh
[root@trial opt]#

8. Extract the contents of the *.tgz file:
# su mzadmin
# tar -xvf PT_Teguh_Triharto_Corporation.tgz
# ls -lh
# chown mzadmin:mzadmin PT_Teguh_Triharto_Corporation.tgz
[root@trial opt]# cd /data/
[root@trial data]# ls
jdk-8u144-linux-x64.rpm  PT_Teguh_Triharto_Corporation.tgz
[root@trial data]# ls -lh
total 593M
-rw-r--r--. 1 root root 163M Aug 21 15:25 jdk-8u144-linux-x64.rpm
-rw-r--r--  1 root root 431M Aug 28 13:36 PT_Teguh_Triharto_Corporation.tgz
[root@trial data]# chown mzadmin:mzadmin PT_Teguh_Triharto_Corporation.tgz
[root@trial data]# su mzadmin
[mzadmin@trial data]$ ls -lh
total 593M
-rw-r--r--. 1 root    root    163M Aug 21 15:25 jdk-8u144-linux-x64.rpm
-rw-r--r--  1 mzadmin mzadmin 431M Aug 28 13:36 PT_Teguh_Triharto_Corporation.tgz
[mzadmin@trial data]$
[mzadmin@trial data]$ ls -lh
total 593M
-rw-r--r--.  1 root    root    163M Aug 21 15:25 jdk-8u144-linux-x64.rpm
drwxrwxr-x  13 mzadmin mzadmin 4.0K Aug 15 15:19 PT_Teguh_Triharto_Corporation
-rw-r--r--   1 mzadmin mzadmin 431M Aug 28 13:36 PT_Teguh_Triharto_Corporation.tgz
[mzadmin@trial data]$

9. as user mzadmin, open Terminal and setting Environment Example - Setting Environment Variables
$ export MZ_HOME=/opt/mz80
$ export JAVA_HOME=/usr/java/jdk1.8.0_144
$ export PATH=$JAVA_HOME/bin:$MZ_HOME/bin:$PATH

10. Extracting the Software
# cd /data/PT_Teguh_Triharto_Corporation
# ./setup.sh prepare
[mzadmin@trial data]$ cd /data/PT_Teguh_Triharto_Corporation
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ ls
database  doc  extensions  license  readme.txt  release  samples  scripts  settings.gradle  setup.gradle  setup.sh  tmp_gradle  tools  upgrader  version
[mzadmin@trial PT_Teguh_Triharto_Corporation]$

[mzadmin@trial PT_Teguh_Triharto_Corporation]$ ./setup.sh prepare
Selecting /data/PT_Teguh_Triharto_Corporation as MZINST_HOME based on path
export MZ_INSTALL_XML_FILE=/data/PT_Teguh_Triharto_Corporation/install.xml
export MZ_LICENSE_FILE=/data/PT_Teguh_Triharto_Corporation/license/mz.license
export MZ_INSTALLATION_SOURCE=/data/PT_Teguh_Triharto_Corporation
export MZ_HOME_TO_PATCH=/opt/mz80
export MZ_HOME=/opt/mz80
export MZ_AUTO_PSC=0
Picked up _JAVA_OPTIONS: -Djava.io.tmpdir=/data/PT_Teguh_Triharto_Corporation/tmp_gradle


# *********  setup.sh prepare

# *********  installation log: /data/PT_Teguh_Triharto_Corporation/setup-8.0.1.2.log

:prepare
=========== PREPARING INSTALLATION: Extracting all MZP ===========
 =========== Extract: core_8.0.1.0.mzp
License: DB-type*: multi
License: DB-type : derby
/data/PT_Teguh_Triharto_Corporation/install.xml: Wrote configuration file.
 =========== Extract: sftp_base_8.0.1.0.mzp
 =========== Extract: sftp_collection_8.0.1.0.mzp
 ...................
 =========== Extract: jcommander_8.0.1.0.mzp
 =========== Extract: docweb_8.0.1.2.mzp
=========== INSTALLATION PREPARED ===========
Follow the installation instructions (doc/documentation.pdf) to configure install.xml for your environment
When done, execute ./setup.sh create

Output is saved to /data/PT_Teguh_Triharto_Corporation/setup-8.0.1.2.log
[mzadmin@trial PT_Teguh_Triharto_Corporation]$

11. Extract any additional files from the packages using the following command session.
# ./setup.sh create

[mzadmin@trial PT_Teguh_Triharto_Corporation]$ ./setup.sh create
Selecting /data/PT_Teguh_Triharto_Corporation as MZINST_HOME based on path
export MZ_INSTALL_XML_FILE=/data/PT_Teguh_Triharto_Corporation/install.xml
export MZ_LICENSE_FILE=/data/PT_Teguh_Triharto_Corporation/license/mz.license
export MZ_INSTALLATION_SOURCE=/data/PT_Teguh_Triharto_Corporation
export MZ_HOME_TO_PATCH=/opt/mz80
export MZ_HOME=/opt/mz80
export MZ_AUTO_PSC=0
Picked up _JAVA_OPTIONS: -Djava.io.tmpdir=/data/PT_Teguh_Triharto_Corporation/tmp_gradle


# *********  setup.sh create

# *********  installation log: /data/PT_Teguh_Triharto_Corporation/setup-8.0.1.2.log

:create
=========== CREATING FILES ===========
Create: core_8.0.1.0.mzp
License: DB-type*: multi
License: DB-type : derby
Create: sftp_base_8.0.1.0.mzp
..............................
Create: docweb_8.0.1.2.mzp
Nothing to create for docweb
=========== FILES CREATED ===========
Follow installation instructions (doc/documentation.pdf) to configure install.xml for your environment
When done, execute ./setup.sh install

Output is saved to /data/PT_Teguh_Triharto_Corporation/setup-8.0.1.2.log
[mzadmin@trial PT_Teguh_Triharto_Corporation]$

12. Updating the Installation Properties
mz.container = platform1
install.str.config-script = scripts/str-templates/basic.sh
install.security = false
mz.home = /opt/mz80
example
# chmod 777 install.xml
# cat install.xml | grep mz.container
# cat install.xml | grep install.str.config-script
# cat install.xml | grep install.security
# cat install.xml | grep mz.home

[mzadmin@trial PT_Teguh_Triharto_Corporation]$ chmod 777 install.xml
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ vi install.xml
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ cat install.xml | grep mz.container
  <property name="mz.container" value="platform1"/>
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ cat install.xml | grep install.str.config-script
  <property name="install.str.config-script"   value="scripts/str-templates/basic.sh"/>
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ cat install.xml | grep install.security
         NOTE: If install.security is set to true remember use https as protocol in the URL.
  <property name="install.security" value="false"/>
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ cat install.xml | grep mz.home
  <property name="mz.home" value="/opt/mz80"/>
[mzadmin@trial PT_Teguh_Triharto_Corporation]$

complete
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ cat install.xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<config>
  <!--  Identifier for this MZ System -->
  <property name="mz.name"        value="MZ"/>

  <!--
  container-type:      Determines which type of installation to perform

     platform  - install the platform container
                 the platform container may host any type of pico process
                 A MZ System has one platform container
     execution - install an execution container
                 an execution container may host any type of pico process *except* the platform
                 A MZ System may have zero or more execution container
    -->
  <property name="install.str.container-type"    value="platform"/>

  <!--
  config-script:
        By specifying a config-script and invoking './setup.sh configure' after performing
         the actual installation ('./setup.sh install'), the desired setup of initial
         EC/ECSA/SC can be created. Changes to default parameters for platform may also be specified
         in the config-script

         In the str-templates directory of the distribution, a number of
         examples can be found. They can either be used directly or
         modified as needed to match your intended configuration

         To create ec1/ecsa1 and sc:s zk1-3 and sc1-3, specify: "scripts/str-templates/basic.sh"

         "-" means no picos (except for platform/psc1 in the case of a platform installation)
         will be created during the installation
    -->
  <property name="install.str.config-script"   value="scripts/str-templates/basic.sh"/>

  <!--
  install.str.mz_platform:

         Specifies a http/s url which is used to establish default connectivity (http and rcp)
         between execution and platform containers

         The same value should be used for platform and execution containers
         part of the same system

         For the platform container:

            - The property must be set to an address/hostname which is reachable by your execution containers.
              The platform web interface will be accessible from this URL.

         For execution containers:

           - Make sure this url points to the platform, i.e. re-use the value from the platform container installation.
             This value will be used to fetch other settings from the STR, including rcp connectivity parameters.

         NOTE: If install.security is set to true remember use https as protocol in the URL.

         For more information, see the user documentation.
   -->

  <property name="install.str.mz_platform"   value="http://localhost:9000"/>

  <!--
      Install to this directory
   -->
  <property name="mz.home" value="/opt/mz80"/>

  <!--
      Each individual installation within a MediationZone system must be
      assigned with a symbolic and unique (within the system) identifier.

      Typical values for this container identifier will be the hostname,
      or a descriptive value for the purpose of the container,
      such as: batch1 or platform1

      If you have several installations of MediationZone on the same host
      (different MZ_HOME directories), they must be given different
      container identifiers

      The identifier must use no spaces and "." and must be lowercase
      (Allowed characters: [a-z,0-9,-,_])

 -->
 <property name="mz.container" value="platform1"/>


  <!--
     MediationZone can be installed with security features enabled by
     default meaning that:
      - Enhanced User Security will be enabled on the Platform, see the
        documentation for more details on this feature.
      - Changing the password of the Administrator account at the end
        of the Platform installation is mandatory.
      - HTTPS will be enabled using a self-signed keystore generated
        during the installation. To change keystore after installation
        see the 'mzsh keytool' command.
  -->

  <property name="install.security" value="false"/>


  <!--
   Set up this container for REMOTE execution. This is needed in order for the 'system' commmand
   to work. The 'system' command allows the control (starting/stopping) of Execution Contexts and other
   picos on remote hosts.

    This is only applicable for container-type "execution" installations.
    By default, this will perform the following steps:

    * Add the platform's public key to ~/.ssh/authorized_keys
    ** NOTE: This allows the holder of the platform key to log in to this host via SSH

    * It will insert into the STR the following SSH connection info for this host:
    ** ssh-address: The hostname of this host (e.g. $(hostname))
    ** ssh-port: 22
    ** hostkeys: It will try to discover the sshd public keys for this host in known file locations

    If this is not desired, or the default values are not suitable for your setup (e.g. this host does not run sshd),
    set this value to false. It's still possible to set this up post-install by using the 'mzsh topo setupremote' command.

  -->
  <property name="install.str.remote.enabled" value="true"/>

  <!--
  The following property can be used to work around environment conditions that prevent MZ from performing the
  installation with the default platform port.

  It should only be set if absolutely necessary.
  -->
  <!--property name="pico.rcp.platform.port" value="6790"/-->
</config>
[mzadmin@trial PT_Teguh_Triharto_Corporation]$

13. Software Installation
# id
# export MZ_HOME=/opt/mz80
# export JAVA_HOME=/usr/java/jdk1.8.0_144
# export PATH=$JAVA_HOME/bin:$MZ_HOME/bin:$PATH
# ./setup.sh install

[mzadmin@trial PT_Teguh_Triharto_Corporation]$ id
uid=500(mzadmin) gid=500(mzadmin) groups=500(mzadmin)
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ ./setup.sh install
Selecting /data/PT_Teguh_Triharto_Corporation as MZINST_HOME based on path
export MZ_INSTALL_XML_FILE=/data/PT_Teguh_Triharto_Corporation/install.xml
export MZ_LICENSE_FILE=/data/PT_Teguh_Triharto_Corporation/license/mz.license
export MZ_INSTALLATION_SOURCE=/data/PT_Teguh_Triharto_Corporation
export MZ_HOME_TO_PATCH=/opt/mz80
export MZ_HOME=
export MZ_AUTO_PSC=0
Picked up _JAVA_OPTIONS: -Djava.io.tmpdir=/data/PT_Teguh_Triharto_Corporation/tmp_gradle


# *********  setup.sh install

# *********  installation log: /data/PT_Teguh_Triharto_Corporation/setup-8.0.1.2.log

:install
Installation type: - / platform
STR will be configured using: scripts/str-templates/basic.sh
Installation type: - / platform
=========== INSTALLING ===========
=========== Install: core_8.0.1.0.mzp
Unpacking /opt/mz80/tmp/.install/common/lib/Agrona-0.9.0.jar...done
Unpacking /opt/mz80/tmp/.install/common/lib/akka-actor_2.11-2.4.12.jar...done
..................................................
=========== Install: jcommander_8.0.1.0.mzp
Commit using copy: /data/PT_Teguh_Triharto_Corporation/release/complete/packages/jcommander_8.0.1.0.mzp
=========== Install: docweb_8.0.1.2.mzp
Unpacking directory /opt/mz80/web/documentation...done
Unpacking directory /opt/mz80/solr...done
Commit using copy: /data/PT_Teguh_Triharto_Corporation/release/complete/packages/docweb_8.0.1.2.mzp
Copy desktop launcher jar file to /opt/mz80/desktop/launcher/binaries
Copy desktop launcher bundles to /opt/mz80/desktop/launcher/bundles
Copy rebranding jar to /opt/mz80/desktop/rebranding
Restarting platform: MZ_HOME=/opt/mz80 ([-e, str.migrate=true, -e, mz.container=platform1])
Picked up _JAVA_OPTIONS: -Djava.io.tmpdir=/data/PT_Teguh_Triharto_Corporation/tmp_gradle
Shutting down Platform....done.
Starting Platform...done.
Installation type: - / platform
Installation type: - / platform
Configuring Platform SC: psc1
................................................
Shutting down platform: MZ_HOME=/opt/mz80
Picked up _JAVA_OPTIONS: -Djava.io.tmpdir=/data/PT_Teguh_Triharto_Corporation/tmp_gradle
Shutting down platform........done.
=========== INSTALLATION COMPLETE ===========
For post installation configuration execute ./setup.sh configure

Output is saved to /opt/mz80/log/setup-8.0.1.2.log
(Copied setup log to MZ_HOME: /data/PT_Teguh_Triharto_Corporation/setup-8.0.1.2.log -> /opt/mz80/log/setup-8.0.1.2.log)
[mzadmin@trial PT_Teguh_Triharto_Corporation]$

14. Post Installation Configuration
# ./setup.sh configure
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ echo "For post installation configuration execute ./setup.sh configure "
For post installation configuration execute ./setup.sh configure
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ ./setup.sh configure
Selecting /data/PT_Teguh_Triharto_Corporation as MZINST_HOME based on path
export MZ_INSTALL_XML_FILE=/data/PT_Teguh_Triharto_Corporation/install.xml
export MZ_LICENSE_FILE=/data/PT_Teguh_Triharto_Corporation/license/mz.license
export MZ_INSTALLATION_SOURCE=/data/PT_Teguh_Triharto_Corporation
export MZ_HOME_TO_PATCH=/opt/mz80
export MZ_HOME=/opt/mz80
export MZ_AUTO_PSC=0
Picked up _JAVA_OPTIONS: -Djava.io.tmpdir=/data/PT_Teguh_Triharto_Corporation/tmp_gradle


# *********  setup.sh configure

# *********  installation log: /opt/mz80/log/setup-8.0.1.2.log

:configure
Starting platform: MZ_HOME=/opt/mz80
Picked up _JAVA_OPTIONS: -Djava.io.tmpdir=/data/PT_Teguh_Triharto_Corporation/tmp_gradle
Starting platform...done.
=========== CONFIGURING ===========
STR will be configured using: scripts/str-templates/basic.sh
Configuring STR using script: scripts/str-templates/basic.sh
Container: platform1
Picked up _JAVA_OPTIONS: -Djava.io.tmpdir=/data/PT_Teguh_Triharto_Corporation/tmp_gradle
[ set: topo://container:platform1/pico:ec1 => {
                        template:mz.standard-ec
.....................................
=========== CONFIGURATION COMPLETE ===========

Output is saved to /opt/mz80/log/setup-8.0.1.2.log
[mzadmin@trial PT_Teguh_Triharto_Corporation]$ cd /opt/mz80/bin/
[mzadmin@trial bin]$

15. startup mzsh status
# mzsh status
# mzsh startup sc1 sc2 sc3 ec1 zk1 zk2 zk3 psc1 ecsa1
# mzsh status
[mzadmin@trial bin]$ pwd
/opt/mz80/bin
[mzadmin@trial bin]$ id
uid=500(mzadmin) gid=500(mzadmin) groups=500(mzadmin)
[mzadmin@trial bin]$ mzsh status
zk2 is not running
sc1 is not running
zk1 is not running
ec1 is not running
sc3 is not running
sc2 is not running
zk3 is not running
psc1 is not running
ecsa1 is not running
platform is running
[mzadmin@trial bin]$ mzsh startup sc1 sc2 sc3 ec1 zk1 zk2 zk3 psc1 ecsa1
Starting sc1...done.
Starting sc2...done.
Starting sc3...done.
Starting ec1...done.
Starting zk1...done.
Starting zk2...done.
Starting zk3...done.
Starting psc1...done.
Starting ecsa1...done.
[mzadmin@trial bin]$ mzsh status platform
platform is running
[mzadmin@trial bin]$ mzsh status
zk2 is running
sc1 is running
zk1 is running
ec1 is running
sc3 is running
zk3 is running
sc2 is running
psc1 is running
ecsa1 is running
platform is running
[mzadmin@trial bin]$ pwd

16. Login to web GUI
user: mzadmin
passwd: dr


17. Installation and Configuration of Desktop Launcher & open
for linux using
Launch with:
    java -jar mediationzone-launcher-1.0.1.jar
Using a custom data folder:
    java -Dlauncher.home=/path/to/folder -jar mediationzone-launcher-1.0.1.jar

18. add instance & login
19. capture version via dekstop
21. open documentation


.::: Install/Upgrade Minimal to Desktop Environment on Centos/RHEL(Redhat Enterprise Linux ) :::.

$
0
0
1. List Installed and Available Groups
[root@TeguhLab ~]# yum grouplist
Loaded plugins: fastestmirror
There is no installed groups file.
Maybe run: yum groups mark convert (see man yum)
Loading mirror speeds from cached hostfile
 * base: sumberterbuka.beritagar.id
 * extras: sumberterbuka.beritagar.id
 * updates: sumberterbuka.beritagar.id
Available environment groups:
   Minimal Install
   Compute Node
   Infrastructure Server
   File and Print Server
   Basic Web Server
   Virtualization Host
   Server with GUI
   GNOME Desktop
   KDE Plasma Workspaces
   Development and Creative Workstation
Available Groups:
   Compatibility Libraries
   Console Internet Tools
   Development Tools
   Graphical Administration Tools
   Legacy UNIX Compatibility
   Scientific Support
   Security Tools
   Smart Card Support
   System Administration Tools
   System Management
Done
[root@TeguhLab ~]# cat /etc/redhat-release
CentOS Linux release 7.1.1503 (Core)
[root@TeguhLab ~]#
[root@TeguhLab ~]# startx
-bash: startx: command not found
[root@TeguhLab ~]#

2. List Packages in a Group
 # yum groupinfo "GNOME Desktop"
[root@TeguhLab ~]# yum groupinfo "GNOME Desktop"
Loaded plugins: fastestmirror
There is no installed groups file.
Maybe run: yum groups mark convert (see man yum)
Loading mirror speeds from cached hostfile
 * base: sumberterbuka.beritagar.id
 * extras: sumberterbuka.beritagar.id
 * updates: sumberterbuka.beritagar.id

Environment Group: GNOME Desktop
 Environment-Id: gnome-desktop-environment
 Description: GNOME is a highly intuitive and user friendly desktop environment.
 Mandatory Groups:
   +base
   +core
   +desktop-debugging
   +dial-up
   +directory-client
   +fonts
   +gnome-desktop
   +guest-agents
   +guest-desktop-agents
   +input-methods
   +internet-browser
   +java-platform
   +multimedia
   +network-file-system-client
   +networkmanager-submodules
   +print-client
   +x11
 Optional Groups:
   +backup-client
   +gnome-apps
   +internet-applications
   +legacy-x
   +office-suite
   +remote-desktop-clients
   +smart-card
[root@TeguhLab ~]#

3. Upgrade from Minimal installation to GNOME Desktop:
 # yum -y groupinstall "GNOME Desktop"

[root@TeguhLab ~]# yum -y groupinstall "GNOME Desktop"
Loaded plugins: fastestmirror
There is no installed groups file.
Maybe run: yum groups mark convert (see man yum)
Loading mirror speeds from cached hostfile
 * base: sumberterbuka.beritagar.id
 * extras: sumberterbuka.beritagar.id
 * updates: sumberterbuka.beritagar.id
Resolving Dependencies
--> Running transaction check
---> Package ModemManager.x86_64 0:1.6.0-2.el7 will be installed
--> Processing Dependency: ModemManager-glib(x86-64) = 1.6.0-2.el7 for package: ModemManager-1.6.0-2.el7.x86_64
--> Processing Dependency: libqmi-utils for package: ModemManager-1.6.0-2.el7.x86_64
..............................................................
 Replaced:
  NetworkManager.x86_64 1:1.0.0-14.git20150121.b4ea599c.el7               pygobject3-base.x86_64 0:3.8.2-6.el7            
  rdma.noarch 0:7.1_3.17-5.el7                                         

Complete!
[root@TeguhLab ~]#

4. Starting GNOME

$ startx
or
$ /sbin/telinit 5

To have CentOS boot into runlevel 5 “X11” instead of runlevel 3 “Full multiuser mode”, modify the /etc/inittab file to change start up level from
id:3:initdefault:
to
id:5:initdefault:

[root@TeguhLab ~]# startx
hostname: Name or service not known
xauth:  file /root/.serverauth.5364 does not exist
xauth:  file /root/.Xauthority does not exist
xauth:  file /root/.Xauthority does not exist


X.Org X Server 1.19.3
Release Date: 2017-03-15
X Protocol Version 11, Revision 0
Build Operating System:  3.10.0-514.16.1.el7.x86_64
Current Operating System: Linux TeguhLab 3.10.0-229.el7.x86_64 #1 SMP Fri Mar 6 11:36:42 UTC 2015 x86_64
Kernel command line: BOOT_IMAGE=/vmlinuz-3.10.0-229.el7.x86_64 root=UUID=fa73217f-e158-471b-bea0-ab9538335ae3 ro crashkernel=auto rhgb quiet LANG=en_US.UTF-8
Build Date: 05 August 2017  06:19:43AM
Build ID: xorg-x11-server 1.19.3-11.el7
Current version of pixman: 0.34.0
    Before reporting problems, check http://wiki.x.org
    to make sure that you have the latest version.
Markers: (--) probed, (**) from config file, (==) default setting,
    (++) from command line, (!!) notice, (II) informational,
    (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.0.log", Time: Mon Sep 25 16:12:10 2017
(==) Using config directory: "/etc/X11/xorg.conf.d"
(==) Using system config directory "/usr/share/X11/xorg.conf.d"
VMware: No 3D enabled (0, Success).
touch: cannot touch ‘/root/.cache/imsettings/log’: No such file or directory

5. Now you can login Server using Desktop
[root@TeguhLab ~]# ifconfig -a
ens160: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 10.10.10.10  netmask 255.255.255.0  broadcast 10.10.10.255
        inet6 fe80::20c:29ff:fe98:95ed  prefixlen 64  scopeid 0x20<link>
        ether 00:0c:29:98:95:ed  txqueuelen 1000  (Ethernet)
        RX packets 735920  bytes 1066519730 (1017.1 MiB)
        RX errors 0  dropped 60  overruns 0  frame 0
        TX packets 405306  bytes 32564163 (31.0 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 0  (Local Loopback)
        RX packets 16  bytes 960 (960.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 16  bytes 960 (960.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

[root@TeguhLab ~]#

6. Install vncserver if needed
[root@TeguhLab ~]# yum -y install tigervnc-server
 go to Enable VNC server on linux

.:: Generate Triger Alarm Alcatel Lucent/Nokia 7750, 7450, 7210, 7705 :::.

$
0
0

1. Check snmp & snmptrap community
A:TeguhRouter# show system security snmp community

==============================================================================
Communities
==============================================================================
community           access  view                version   group name
------------------------------------------------------------------------------
cli-li-readwrite    n/a     li-view             v2c       cli-li-readwrite
cli-readonly        r       iso                 v2c       cli-readonly
cli-readwrite       rw      iso                 v2c       cli-readwrite
public              r       no-security         v1 v2c    snmp-ro
public              n/a     n/a                 v2c       snmp-trap
teguht              rwa     iso                 v2c       snmp-rwa
------------------------------------------------------------------------------
No. of Communities: 9
==============================================================================
A:TeguhRouter# show log snmp-trap-group       


===============================================================================
SNMP Trap Groups
===============================================================================
id        name
  port      address
-------------------------------------------------------------------------------
98        nms-all
  162       10.10.10.10
===============================================================================
A:TeguhRouter#


2. create router interface for isis
# configure router interface "loopback_Teguh_Triharto"
# info

A:TeguhRouter# configure router interface "loopback_Teguh_Triharto"
*A:TeguhRouter>config>router>if$ info
----------------------------------------------
            no shutdown
----------------------------------------------
*A:TeguhRouter>config>router>if$ address 1.2.3.4/24
*A:TeguhRouter>config>router>if$ loopback
*A:TeguhRouter>config>router>if$ info
----------------------------------------------
            address 1.2.3.4/24
            loopback
            no shutdown
----------------------------------------------
*A:TeguhRouter>config>router>if$ exit
*A:TeguhRouter#
*A:TeguhRouter# show router interface "loopback_Teguh_Triharto"

===============================================================================
Interface Table (Router: Base)
===============================================================================
Interface-Name                   Adm       Opr(v4/v6)  Mode    Port/SapId
   IP-Address                                                  PfxState
-------------------------------------------------------------------------------
loopback_Teguh_Triharto          Up        Up/Down     Network loopback
   1.2.3.4/24                                                  n/a
-------------------------------------------------------------------------------
Interfaces : 1
===============================================================================
*A:TeguhRouter#


3. configure isis interface
# configure router isis interface "loopback_Teguh_Triharto"

*A:TeguhRouter# configure router isis interface "loopback_Teguh_Triharto"
*A:TeguhRouter>config>router>isis>if# info
----------------------------------------------
                    no shutdown
----------------------------------------------
*A:TeguhRouter>config>router>isis>if# info
----------------------------------------------
                    no shutdown
----------------------------------------------
*A:TeguhRouter>config>router>isis>if# exit
*A:TeguhRouter#

*A:TeguhRouter# show router isis interface "loopback_Teguh_Triharto"

===============================================================================
Rtr Base ISIS Instance 0 Interfaces
===============================================================================
Interface                        Level CircID  Oper State   L1/L2 Metric
-------------------------------------------------------------------------------
loopback_Teguh_Triharto          L1L2  107     Up           0/0
-------------------------------------------------------------------------------
Interfaces : 1
===============================================================================
*A:TeguhRouter#

4. test shutdown router interface "loopback_Teguh_Triharto"

# configure router interface "loopback_Teguh_Triharto"
*A:TeguhRouter# configure router interface "loopback_Teguh_Triharto"
*A:TeguhRouter>config>router>if# info
----------------------------------------------
            address 1.2.3.4/24
            loopback
            no shutdown
----------------------------------------------
*A:TeguhRouter>config>router>if#


5. create router interface for ospf

A:TeguhRouter# configure router interface loopback_Teguh_Triharto-ospf
*A:TeguhRouter>config>router>if$ address 4.3.2.1/24
*A:TeguhRouter>config>router>if$ loopback
*A:TeguhRouter>config>router>if$ info
----------------------------------------------
            address 4.3.2.1/24
            loopback
            no shutdown
----------------------------------------------
*A:TeguhRouter>config>router>if$
*A:TeguhRouter# show router interface "loopback_Teguh_Triharto-ospf"

===============================================================================
Interface Table (Router: Base)
===============================================================================
Interface-Name                   Adm       Opr(v4/v6)  Mode    Port/SapId
   IP-Address                                                  PfxState
-------------------------------------------------------------------------------
loopback_Teguh_Triharto-ospf     Up        Up/Down     Network loopback
   4.3.2.1/24                                                  n/a
-------------------------------------------------------------------------------
Interfaces : 1
===============================================================================
*A:TeguhRouter#

6. configure ospf area
*A:TeguhRouter# configure router ospf area 0.0.2.2 interface "loopback_Teguh_Triharto-ospf"
*A:TeguhRouter>config>router>ospf>area>if$ info
----------------------------------------------
                    no shutdown
----------------------------------------------
*A:TeguhRouter>config>router>ospf>area>if$ no shutdown
*A:TeguhRouter>config>router>ospf>area>if$ exit all
A:TeguhRouter#
A:TeguhRouter# show router ospf area

==================================================================
Rtr Base OSPFv2 Instance 0 Areas
==================================================================
Area Id         Type        SPF Runs    LSA Count   LSA Cksum Sum
------------------------------------------------------------------
0.0.0.0         Standard    4           5           0x25d85
0.0.0.11        Standard    0           1           0xe23
0.0.2.2         Standard    1           5           0x141f5
------------------------------------------------------------------
No. of OSPF Areas: 5
==================================================================
A:TeguhRouter# show router ospf area 0.0.2.2

==================================================================
Rtr Base OSPFv2 Instance 0 Area 0.0.2.2
==================================================================
Area Id         Type        SPF Runs    LSA Count   LSA Cksum Sum
------------------------------------------------------------------
0.0.2.2         Standard    1           5           0x141f5
==================================================================

A:TeguhRouter# show router ospf area 0.0.2.2 detail

===============================================================================
Rtr Base OSPFv2 Instance 0 Area 0.0.2.2 (detail)
===============================================================================
-------------------------------------------------------------------------------
Configuration
-------------------------------------------------------------------------------
Area Id          : 0.0.2.2              Type             : Standard
LFA              : Include            
-------------------------------------------------------------------------------
Statistics
-------------------------------------------------------------------------------
Virtual Links    : 0                    Total Nbrs       : 0
Active IFs       : 1                    Total IFs        : 1
Area Bdr Rtrs    : 1                    AS Bdr Rtrs      : 1
SPF Runs         : 1                    Last SPF Run     : 08/30/2017 16:34:20
Router LSAs      : 1                    Network LSAs     : 0
Summary LSAs     : 3                    Asbr-summ LSAs   : 0
Nssa ext LSAs    : 0                    Area opaque LSAs : 1
Total LSAs       : 5                    LSA Cksum Sum    : 0x141f5
Blackhole Range  : True                 Unknown LSAs     : 0
Export database  : False              
Export Policies  : None               
Export Fltrd LSAs: 0                  
Import Policies  : None               
Import Fltrd LSAs: 0                  
===============================================================================
A:TeguhRouter#   

7. test shutdown router interface "loopback_Teguh_Triharto-ospf"
A:TeguhRouter# configure router interface "loopback_Teguh_Triharto-ospf"
A:TeguhRouter>config>router>if# info
----------------------------------------------
            address 4.3.2.1/24
            loopback
            no shutdown
----------------------------------------------
A:TeguhRouter>config>router>if# shutdown
*A:TeguhRouter>config>router>if# info
----------------------------------------------
            shutdown
            address 4.3.2.1/24
            loopback
----------------------------------------------
*A:TeguhRouter>config>router>if#


8. Capture snmptrap ISIS 


9. Capture snmptrap OSPF

.::: Troubleshoot Error 'X-Frame-Options' to 'sameorigin'or Load denied by X-Frame-Options does not permit cross-origin framing :::.

$
0
0
some application. You can't change the web security setting in Application. The only way to add or remove header options would be to proxy it, e.g with haproxy. Troubleshoot Error 'X-Frame-Options' to 'sameorigin'or Load denied by X-Frame-Options does not permit cross-origin framing

1. Log Error
Error 'X-Frame-Options' to 'sameorigin'or Load denied by X-Frame-Options does not permit cross-origin framing
Refused to display 'https://10.10.10.10:443/TopN-Teguh.html' in a frame because it set 'X-Frame-Options' to 'sameorigin'.
Failed to load resource: net::ERR_BLOCKED_BY_RESPONSE

Load denied by X-Frame-Options: https://10.10.10.10:443/TopN-Teguh.html does not permit cross-origin framing.  (unknown)

2. Additional Ads ons "Ignore X-Frame-Options" on Firefox or Extensions Ignore X-Frame headers on Chrome

3. Access web using Firefox or Chrome

Viewing all 413 articles
Browse latest View live