Configuration information

how to install snmp for weblogic?

Read the official docs
The weblogic snmp agent will not work as a subagent for the OS master agent. The workaround is to reverse the order. i.e. make weblogic act as master (on port 161) and delegate to the native OS agent.
To do that: 
a) modify winnt\system32\drivers\etc\services file from:
....
snmp 161/udp 
.....
to:   
snmp 1161/udp (any free port will do here) 

b) modify the startsnmpagent.cmd file in the weblogic root, e.g. 
%JAVA% weblogic.SNMPAgent -password mypassword -serverURLs t3://localhost:7001 -snmpPort 161 -trapDestinations localhost:162 -otherAgents 1161:.1.3.6.1.2.1.

the -snmpPort 161 makes weblogic the master agent
the -otherAgents 1161:.1.3.6.1.2.1.  tells this agent to delegate the 1.3.6.1.2.1 subtree to port 1161 (where the native agent is running).
Run this  file and make sure the  agent is restarted on the 1161 port
Use system command netstat -a -n -p udp to view the active udp ports. both udp 161 and udp 1161 should appear in the resulting list
the weblogic appserver should be running or nothing meaningful comes back from the agent (the delegated parts work anyway.

Installing for oracle

This uses a similar process. except that:

the oracle snmp is based on two services (an agent and an encapsulator for delegation)

the configuration is based on modifying the ENCAPS.CFG file in oracle/network/admin  folder.