Posts

Showing posts from August, 2011

Viewing directory listing

In Linux/Unix, there are times when you might want to view only the directory listings, excluding files. You can achieve this with the following command: -bash-3.00# ls -l | egrep ^d

Blocking Mass Storage in Linux

Disabling Mass Storage in Linux-Based Distros Unmount the USB device if it is currently connected: [root@centos ~]# umount /dev/sdb Note: The device name may vary in your case. Remove the USB storage module: [root@centos ~]# modprobe -r usb_storage Edit /etc/modprobe.d/blacklist.conf and add the following line: blacklist usb_storage Save the file. Now, when a USB flash drive is connected, the hotplug scripts will not load it automatically.

IPS (Image Packaging system) in Solaris 10

In Standard Solaris, IPS is exclusively a feature of Oracle Solaris 11. While Oracle Solaris 10 provides some tools to achieve similar functionality, their use in production environments raises questions about reliability. Historically, package installation in Solaris has been challenging. Fortunately, some solutions now provide IPS-like functionality: 1. OpenCSW To utilize IPS functionality with OpenCSW in Oracle Solaris 10, follow these steps: Download the package from: http://mirror.opencsw.org/opencsw/current/i386/5.10/pkgutil-2.4%2CREV%3D2011.05.15-SunOS5.8-i386-CSW.pkg.gz Unzip the downloaded package: gunzip pkgutil-2.4,REV=2011.05.15-SunOS5.8-i386-CSW.pkg.gz Install the package: pkgadd -d pkgutil-2.4,REV=2011.05.15-SunOS5.8-i386-CSW.pkg Fetch the latest catalog: pkgutil --catalog Install any package with all dependencies: pkgutil -i vim 2. BlastWave To achieve IPS functionality ...

Playing with Solaris Zones

Solaris supports operating system-level virtualization, allowing you to run only Solaris in virtual hosts, utilizing the same kernel copy as the parent OS. This results in high performance, with overhead degradation typically between 1-3%. Zones There are two types of zones: Global/Parent Zone (Base OS) Non-Global Zones Key Points about Zones: A single machine can host up to 8192 zones. Zones do not support graphics. Zones are not installed from DVD or other media; they are created from the parent OS. It is common not to run services on the Global Zone, as its failure affects all Non-Global Zones. Types of Non-Global Zones: Whole Root Zone : This contains a complete Solaris OS. It's slower and generally not recommended for production as it acts as a full replica of the Global Zone. Spare Root Zone : This type shares parts of the Solaris OS with the parent zone, offering faster performance since only essential c...