Top 20 Linux system monitoring tools for every admin

ref: http://www.cyberciti.biz/tips/top-linux-monitoring-tools.html

Advertisements

Linux mounting an NFS .ISO to a directory

#step 1:
# mount -t nfs 192.168.255.15:/mnt/vol1/store4/iso1 /mnt/iso1

Ok, this way you’ll have all your ISO files at /mnt/iso1. Now, imagine you want to mount one of these ISOs in loopback:

#step 2:
# mount -o loop /mnt/isos/[isofilename].iso /tmp/blah
/mnt/isos/blah.iso: Permission denied

Permission denied??? Hmmm.. I got stuck with this problem for a bit the first time. Tried changing permissions and exporting parameters, Google, but no answer at all… then… fortunately…. I found it: -o loop,ro!

#step 2 (for real this itme):
# mount -o loop,ro /mnt/iso1/[isofilename].iso /tmp/blah

virtualbox opensuse

Update 4 April 2013 Tested & working in openSUSE 12.3

Introduction You can install the fully open source version or the Sun/Oracle version. The latter (Sun/Oracle) is significantly better IMHO. I only talk about the Sun/Oracle version here.

Install the Oracle VirtualBox RPM Add this repo, it contains the Oracle VirtualBox RPM and it will supply updates over time. It is currently the correct repo for openSUSE 11.4, 12.1, 12,2, 12.3 and Tumbleweed
Code:

Oracle VirtualBox openSUSE http://download.virtualbox.org/virtualbox/rpm/opensuse/11.4/

Important, read carefully: You will have a series of possible RPMs available in the package management GUI in Yast. Be very sure to install only the Oracle VirtualBox RPM, not the oss virtualbox RPM. GoTo Yast –> Software –> Software management and select the Oracle RPM. If dependency linkages attempt to install additional packages beginning virtualbox-guest or virtualbox-host kernel modules, then you have made a mistake. Install only the single RPM “VirtualBox”. Make sure you choose the latest version in the repo.

Additional RPMs You will also need these RPMs: kernel-devel, gcc, make. Install them in yast or run this zypper command (as root)
Code:

zypper in gcc make kernel-devel

Add your username to the vboxusers group VirtualBox permissions will not work properly until you do this. GoTo Yast –> Security and Users –> User and group management. Highlight and Edit you username. Select the Details tab and tick the box to add yourself to “vboxusers”. Then reboot to activate the changes.

Next: the Extension Pack This pack provides additiopnal functionality like USB and RDP support. GoTo the VirtualBox dot org download site https://www.virtualbox.org/wiki/Downloads and click the link for the Extension Pack. NB be sure to select the extension pack with the same version as your installed version of VirtualBox! Download the pack, a file with a name like Oracle_VM_VirtualBox_Extension_Pack-4.0.14-74382.vbox-extpack. Download the pack, then browse to it and click it with the mouse. That will cause it to be installed (provided the VirtualBox RPM has been installed first).

Each time you upgrade the VirtualBox RPM, you will have to go back to the Extension Pack download page and acquire and install the new Extension Pack to match the version number of the upgraded RPM.

Where’s the GUI? In KDE GoTo Kicker –> Applications –> System –> Virtual Machine (Oracle VM VirtualBox).

After a Kernel Upgrade in the openSUSE Host This is arguably a part of the installation of VirtualBox. When you have a kernel upgrade, after you reboot, you must run this command as root to recompile the kernel modules:
Code:

/etc/init.d/vboxdrv setup

If USB support fails: If the Guest VM does not detect USB devices, or if they are detected but “grayed” out in the menu bar, check that you added your username to the vboxusers group. Check that the file xx-vboxdrv.rules exists in the directory /etc/udev/rules.d/

That’s all folks. I only wanted to talk about the installation, which can be a bit tricky in the detail.

[PS: Tumbleweed only: if you’re a Tumbleweeder you might occasionally install an upgrade of the VirtualBox RPM with “zypper dup”. Just check that the earlier version of the RPM has uninstalled. Run “rpm -qa | grep VirtualBox” and make sure the earlier one has gone.]

Whatabout VM Tools??… try VirtualBox guest additions in the device menu of the machine itself. Link follows, will translate to CLI when time permits, link.

ref:
http://forums.opensuse.org/content/59-how-install-virtualbox-opensuse-11-4-12-1-tumbleweed.html

crafting MITM (Man-in-the-middle) redirects — via arp poisoning

Basic Linux bridging examples w/ iptables adjustments:
brctl addbr br0
brctl addif br0 eth0
brctl addif br0 eth1
ifconfig eth0 0.0.0.0 promisc up
ifconfig eth1 0.0.0.0 promisc up
ifconfig br0 netmask broadcast
iptables -A FORWARD -p all -i br0 -j ACCEPT
iptables -t mangle -A FORWARD -m physdev –physdev-in eth0 -j NFQUEUE –queue-num 0
iptables -t mangle -A FORWARD -m physdev –physdev-in eth1 -j NFQUEUE –queue-num 1

======
Tutorial #1 here:

Linux software (CLI) installations — via add repository — Google-chrome

64 bit:
zypper ar http://dl.google.com/linux/chrome/rpm/stable/x86_64 Google-Chrome

-OR-

32 bit:
zypper ar http://dl.google.com/linux/chrome/rpm/stable/i386 Google-Chrome

zypper ref
zypper in google-chrome-stable

+++++++++++

Chromium install (Gui:Yast) will rewrite into CLI later:
1- Open YaST, goto software repositories, click add button, choose community repositories from the choices, and click next. Now select Contrib repo and click OK.

2- Now open software management from YaST, and search for ‘chromium’ without quotes and mark it for installation, click Accept button and you are done.

Linux (LPIC1) skills – How-To get your WiFi runnin’ on Open Suse, Red Hat, Et Al

Tags: Linux, OpenSuse, RedHat, WiFi, Wireless, KDE, Dell, Studio, 1737, 1735
Hardware: Dell studio 1737; however this works in general on other hardware for the aforementioned OS’s by changing the grep statement to your hardware
OS: Opensuse
Issue resolved: WiFi driver
#
#summary of commands to resolve these issues
#lspci;dmesg | grep Broadcom;sudo /usr/instal_bm43xx_firmware
!
!
#step 1:
#find who your wifi manufacturer is, (hint: run the following command then look for wifi references):
!
!
suse253:~ # lspci
00:00.0 Host bridge: Intel Corporation Mobile 4 Series Chipset Memory Controller Hub (rev 07)
00:02.0 VGA compatible controller: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller (rev 07)
00:02.1 Display controller: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller (rev 07)
…snipped output…
04:00.0 Network controller: Broadcom Corporation BCM4322 802.11a/b/g/n Wireless LAN Controller (rev 01)
!
!
#step 2:
# grep for references to your wifi manufacturer (Broadcom in my case) in dmesg
!
!
suse253:~ # dmesg | grep Broadcom
[ 5.438335] b43-phy0: Broadcom 4322 WLAN found (core revision 16)
[ 5.461254] Broadcom 43xx driver loaded [ Features: PMNLS ]
[ 5.465063] b43-phy0 ERROR: Please open a terminal and enter the command “sudo /usr/sbin/install_bcm43xx_firmware” to download the correct firmware for this driver version. For an off-line installation, go to http://en.opensuse.org/HCL/Network_Adapters_(Wireless)/Broadcom_BCM43xx and follow the instructions in the “Installing firmware from RPM packages” section.
!
#step 3:
# now follow the instructions that the dmesg so conveniently output above (install wifi microcode)
!
suse253:~ # sudo /usr/sbin/install_bcm43xx_firmware
Downloading b43 firmware
######################################################################## 100.0%
Extracting b43 firmware
This file is recognised as:
filename : wl_apsta.o
version : 666.2
MD5 : e1b05e268bcdbfef3560c28fc161f30e
Extracting b43/lp0initvals14.fw
Extracting b43/lcn0bsinitvals25.fw
…snipped output…
Extracting b43/ht0bsinitvals29.fw

Downloading b43legacy firmware
######################################################################## 100.0%
Extracting b43legacy firmware
This file is recognised as:
filename : wl_apsta.o
version : 295.14
MD5 : e08665c5c5b66beb9c3b2dd54aa80cb3
Extracting b43legacy/ucode2.fw
…snipped output…
Extracting b43legacy/a0g0bsinitvals5.fw

b43 firmware successfully installed.
b43legacy firmware successfully installed.
!
#congrats it should be working : now connect to a wifi ssid
!

Cisco Switch security

Upgrade your standards:
The case for changing your tagging standards to tag your native VLANs… The blatant weakness to having untagged native VLANs.

Vulnerability testing tools:
Yersinia hacking tool for testing Cisco vulnerabilities.

Scapy the packet crafter…