Disabling undesired TCP/IP services in AIX
http://www-03.ibm.com/support/techdocs/atsmastr.nsf/WebIndex/TD100942
Articles hints,tips&tricks,howtos and guides related to UNIX System Administration
Showing posts with label Networking. Show all posts
Showing posts with label Networking. Show all posts
Saturday, March 26, 2011
Thursday, July 1, 2010
Solaris 10 IPMP Link Based Failure Detection in Virtualbox
Configuring Solaris 10 IPMP Link Based Failure Detection in Virtualbox for just testing purpose
Define 2 NIC in a Solarisx86 vm
1-view configuration
# ifconfig -a
lo0: flags=2001000849mtu 8232 index 1
inet 127.0.0.1 netmask ff000000
e1000g0: flags=201000843mtu 1500 index 2
inet 192.168.1.14 netmask ffffff00 broadcast 192.168.1.255
groupname grp1
ether 8:0:27:3e:5b:87
e1000g1: flags=201000843mtu 1500 index 3
inet 0.0.0.0 netmask ff000000 broadcast 0.255.255.255
groupname grp1
ether 8:0:27:41:a1:63
2- check files mapping to your nic's under /etc/
# more /etc/hostname*
::::::::::::::
/etc/hostname.e1000g0
::::::::::::::
solsrvr2 netmask + broadcast + group grp1 up
::::::::::::::
/etc/hostname.e1000g1
::::::::::::::
group grp1 up
3-check if mpathd is running or not
# ps -ef | grep mpathd
root 158 1 0 16:48:03 ? 0:01 /usr/lib/inet/in.mpathd -a
4- mpathd configuration under /etc/default/
# ls -l /etc/default/mpathd
5-testing you can disconnect network cable to simulate disconnecting cable
Wednesday, June 30, 2010
multihomed host e.g muliple ips on same NIC
1-under
enter an entry as follows
2-under
add an entry as follows
3-create a file point to your NIC for example
add hostname for example
4-type the following command
5- assign ips
/etc/hosts
enter an entry as follows
192.168.10.10 myhost
2-under
/etc/netmasks
add an entry as follows
192.168.10.0 255.255.255.0
3-create a file point to your NIC for example
#touch /etc/hostname.e1000g0:1
add hostname for example
myhost
4-type the following command
#ifconfig e1000g0:1 plumb
5- assign ips
#ifconfig e1000g0:1 192.168.10.10 netmask 255.255.255.0 up
Add default route to sun solaris
You can add default route
by issuing the following command
you can verify by viewing entries
by issuing the following command
#route add default 192.168.0.1
you can verify by viewing entries
$netstat -rn
Tuesday, June 22, 2010
Configure ipfilter on Solaris10 as a host based firewall
1- Start by check ipfilter status if it's running you can go ahead and configure rules
if it's disabled enable it
2- Display rules
3- Edit rules
under
-bash-3.00$ svcs -a|grep -i ipfil
online 10:29:37 svc:/network/ipfilter:default
if it's disabled enable it
#svcadm enable ipfilter
2- Display rules
#bash-3.00ipfstat -io
block out all
pass out quick on lo0 all
pass out quick on eri0 proto tcp/udp from eri0/32 to any port = domain with keep state
pass out quick on eri0 proto tcp from eri0/32 to any port = http keep state
pass out quick on eri0 proto icmp from 192.168.1.0/24 to 192.168.1.0/24
block in all
pass in quick on lo0 all
pass in quick on eri0 proto icmp from 192.168.1.0/24 to 192.168.1.0/24
pass in quick on eri0 proto tcp from any to eri0/32 port = http keep state
pass in quick on eri0 proto tcp/udp from any to eri0/32 port = domain with keep state
3- Edit rules
under
/etc/ipf/ipf.conf
#vi /etc/ipf/ipf.conf
#
# ipf.conf
#
# IP Filter rules to be loaded during startup
#
# See ipf(4) manpage for more information on
# IP Filter rules syntax.
####
set intercept_loopback true;
block in all
block out all
### inbound traffic ###
pass in quick on lo0 all
pass in quick on eri0 proto icmp from 192.168.1.0/24 to 192.168.1.0/24
pass in quick on eri0 proto tcp from any to eri0/32 port = http keep state
pass in quick on eri0 proto tcp/udp from any to eri0/32 port = domain keep state
pass out quick on lo0 all
pass out quick on eri0 proto tcp/udp from eri0/32 to any port = 53 keep state
pass out quick on eri0 proto tcp from eri0/32 to any port = http keep state
pass out quick on eri0 proto icmp from 192.168.1.0/24 to 192.168.1.0/24
Monday, June 21, 2010
Add a route to sun Solaris
Add a route to sun Solaris
#route add -net 192.168.1.0 -netmask 255.255.255.0 192.168.1.1
Activate/Deactivate all interfaces ( NIC ) at once in solaris
Activate/Deactivate all interfaces ( NIC ) at once in solaris
Deactivating all at once
Activating all at once
Deactivating all at once
for i in `ifconfig -a|egrep -v '(inet|ether|lo0)'|cut -d: -f1`
do ifconfig $i down
done
Activating all at once
for i in `ifconfig -a|egrep -v '(inet|ether|lo0)'|cut -d: -f1`
do ifconfig $i up
done
Display stats and listening ports netstat
Display stats and listening ports netstat
You can Display stats and listening ports netstat for an iterface
$netstat -an -f inet -P tcp | egrep -i '(list|est|syn|time)'
You can Display stats and listening ports netstat for an iterface
$netstat -an -f inet -P tcp | egrep -i '(list|est|syn|time)'
Clear DNS cache
You can clear DNS cache in Solaris by doing the following
#/etc/init.d/nscd stop
#/etc/init.d/nscd start
#/etc/init.d/nscd stop
#/etc/init.d/nscd start
List PID's for processes listening on ports
To list PID's for processes listening on ports
#pfiles `ptree | awk '{print $1}'` | egrep '^[0-9]|port:'
#pfiles `ptree | awk '{print $1}'` | egrep '^[0-9]|port:'
Subscribe to:
Posts (Atom)