Featured »

March 2, 2022 – 2:00 pm

Books have been written on the subject of awk and sed. Here’s a small sample of commands I put together over the years that are useful for everyday system administration tasks. Most of these tasks …

Read the full story »
Networking

Unix and Linux network configuration. Multiple network interfaces. Bridged NICs. High-availability network configurations.

Applications

Reviews of latest Unix and Linux software. Helpful tips for application support admins. Automating application support.

Data

Disk partitioning, filesystems, directories, and files. Volume management, logical volumes, HA filesystems. Backups and disaster recovery.

Monitoring

Distributed server monitoring. Server performance and capacity planning. Monitoring applications, network status and user activity.

Commands & Shells

Cool Unix shell commands and options. Command-line tools and application. Things every Unix sysadmin needs to know.

Home » Archive by Category

Articles in SysAdmin

Using GNUPlot to chart MySQL data

November 20, 2005 – 12:17 pm
shell_0005

The following Korn shell function connects to a MySQL database and extracts specified data, which is then plotted as a function of time using GNUPlot.  Using correct syntax is critical. Note the use of single- …

Database operations with SQL and Korn shell

November 20, 2005 – 11:46 am
logo_mysql

The following Korn shell function will read the a directory containing CSV data files named server_sysstat.20051119.csv with format:

Solaris boot disk copy

November 20, 2005 – 2:24 am
di-logo-solaris-orange

A sample procedure for installing PHP, MySQL and Apache2 on Solaris 8.

FTP script with nested function

November 20, 2005 – 2:14 am
968780_94091618

An example of an FTP script with Korn shell.

Resetting Root Password under Solaris

November 20, 2005 – 2:02 am
HP-Greets-IBM-2

The following document explains how to change an unknown root password on a Solaris system. Use this only for disaster recovery purposes. Please be sure to read the Notes section below if you run into …

Resetting Admin Passwords on Windows

November 20, 2005 – 2:01 am
windows keyboard

Resetting Local Administrator/User Passwords on Windows NT/2000/XP/2003
The following document explains how to change an unknown password for any local account (including Administrator) on a Windows NT/2000/XP/2003 system. Use this only for disaster recovery purposes.
Requirements:
1.Physical access …

Unix Commands Summary

November 19, 2005 – 11:24 pm
shell_001

 
awk/nawk [options] file scan for patterns in a file and process the results
cat [options] file concatenate (list) a file
cd [directory] change directory
chgrp [options] group file change the group of the file
chmod [options] file change file …

Moving filesystems with ufsdump

November 19, 2005 – 11:22 pm
di-logo-solaris-orange

to move /opt on new partition (disk or file system)
1) from system prompt: format –> partition –> label
2) newfs -v /dev/dsk/c0t1d0s1 (target location)
3) mkdir /new_dir
4) mount /dev/dsk/c0t1d0s1 /new_dir
5) cd /new_dir
6) ufsdump 0f – /opt | …

Copying directories using tar and rsync

November 19, 2005 – 11:20 pm
shell_002

Best Diets Overall 2023

If your goal is to manage your weight long term and eat healthfully, try one of these science-backed diets that work. Each earns top marks from our panel of leading medical and nutriton …

Using more on multiple outputs

November 19, 2005 – 11:19 pm

Here’s the correct way to page four commands so they’re all controlled by “more”:

Find largest files

November 19, 2005 – 11:17 pm
shell

How to find the largest files in the directory tree on Solaris.

Increase swap space

November 19, 2005 – 11:15 pm
hard_disk_drive_hdd_0005

Best Diets Overall 2023

If your goal is to manage your weight long term and eat healthfully, try one of these science-backed diets that work. Each earns top marks from our panel of leading medical and nutriton …

Count users with “last”

November 19, 2005 – 11:15 pm

Here is a quick example showing how to count users logged in on a particular date using the “last” command on Linux.

To display file’s modification, last access, etc

November 19, 2005 – 11:14 pm
shell_0005

Display a file’s modification, last access and other attributes on Solaris.

Using NetBackup to restore boot disk

November 19, 2005 – 11:13 pm
dump truck

enable “Rename hard links”
disable “Rename soft links”
if root of destination drive is mounted as /destination/ then select “Restore to alternate path: from / to /destination/ , Restore search path
This is the alternate path for everything: …

Create tarball

November 19, 2005 – 10:42 pm
shell_002

The Unix tar command creates an archive of files and directories while preserving directory structure, file permissions and ownership information. This command is ideally suited for creating backups of most types of data. Many open-source …

Move USER to new primary group

November 19, 2005 – 10:41 pm
shell_0001

A sample process for moving a user to a new primary home group on Solaris.

Check if Solaris supports 64-bit applications

November 19, 2005 – 10:41 pm
solaris-logo

How to determine if your installation of Solaris supports 64-bit applications.

Unix Files Transferred To CD

November 19, 2005 – 10:40 pm
cd_dvd_001

In our example we were requested to archive a 741 mb directory to CD. The source data resided on a Unix data server.

How to exercise during Ramadan: ‘I’m a Muay Thai champion and PT, here are my tips’

November 19, 2005 – 10:39 pm

Here’s an example of how to mount a cdrom on Solaris from a remote ISO image via NFS.

Tips To A Healthier Dog

November 19, 2005 – 10:38 pm

Useful awk code snippets for your sysadmin tasks.

Copy directory structure and files with cpio

November 19, 2005 – 10:38 pm
shell_003

A basic command to copy directory structure and contents using cpio.