#!/bin/sh

echo "============================= cat /etc/*release files"
for file in /etc/*release ; do
  echo "==== $file:"
  cat $file
done

echo "============================= cat /proc/cpuinfo"
cat /proc/cpuinfo 

echo "============================= cat /proc/meminfo"
cat /proc/meminfo 

echo "============================= ident mpirun and mpirun -version"
ident /opt/hpmpi/bin/mpirun 
/opt/hpmpi/bin/mpirun -version 

echo "============================= uname -a"
uname -a

echo "============================= cat /etc/ld.so.conf"
cat /etc/ld.so.conf
echo "============================= cat /etc/ld.so.conf.d/* files"
for file in /etc/ld.so.conf.d/* ; do
  echo "==== $file:"
  cat $file
done

echo "============================= /sbin/lsmod"
/sbin/lsmod

echo "============================= rpm -qa"
rpm -qa 

echo "============================= printenv"
printenv

echo "============================= dmesg"
dmesg 

echo "============================= /sbin/lspci"
/sbin/lspci

echo "============================= /sbin/lspci -v"
/sbin/lspci -v 

echo "============================= /sbin/ifconfig"
/sbin/ifconfig

echo "============================= cat /etc/hosts"
cat /etc/hosts

echo "============================= module list"
(/opt/modules/default/bin/modulecmd sh list | sh) 2>&1

echo "============================= module avail"
(/opt/modules/default/bin/modulecmd sh avail | sh) 2>&1

echo "============================= vstat(s)"
if [ -x /usr/mellanox/bin/vapi ] ; then /usr/mellanox/bin/vapi ; fi
if [ -x /usr/mellanox/bin/vstat ] ; then /usr/mellanox/bin/vstat  ; fi
if [ -x /usr/bin/vstat ] ; then /usr/bin/vstat ; fi

echo "================================ cat /proc/sys/kernel/shmmax"
cat /proc/sys/kernel/shmmax

echo "================================ cat /etc/security/limits.conf"
cat /etc/security/limits.conf

