perl script

This may come handy, from the project page: Mk-boot-usb is a perl script to create multiple-bootable usb sticks (usb keys / usb flash drives). It wipes out an entire usb stick, partitions it, creates file systems on it, installs grub, and installs a minimal linux on it. Mk-boot-usb is meant to speed up and lower […]

{ 2 comments }

When invoked without arguments, the date command displays the current date and time. Depending on the options specified, date will set the date and time or print it in a user defined way. I’ve seen many sysadmin writing perl scripts for calculating relative date such as yesterdays or tomorrows day. You can use GNU date command, which is designed to handle relative date calculation such as:

  • 1 Year
  • 2 Days
  • 2 Days ago
  • 5 Years

{ 66 comments }

Recently updated/posted Linux and UNIX FAQ: Lighttpd checking for GTHREAD… configure: error: Package requirements (gthread-2.0 >= 2.4.0) were not met error and solution How do I install and search FreeBSD ports or a package? Finding a File containing a particular text string in Linux server Perl display and pass command ling arguments with @argv Redhat […]

{ 0 comments }

You may have noticed that most shell and perl script starts with the following line: #!/bin/bash OR #!/usr/bin/perl It is called a shebang. It consists of a number sign and an exclamation point character (#!), followed by the full path to the interpreter such as /bin/bash. All scripts under UNIX and Linux execute using the […]

{ 18 comments }

Here is a quick question by one of our regular reader : How to write a perl script that can monitor my disk space under UNIX or Linux and send me an email alert? There is a nice perl system routine called Perl df or Filesys::DiskSpace. This routine displays information on a file system such […]

{ 36 comments }