Lotta Linux Links

Top: lottalinuxlinks.com: The Weblog blog feed | podcast feed | ogg feed | forum


lottalinuxlinks

lottalinuxlinks cafepress store

lottalinuxlinks podcast

podcast in ogg format

latest 11 episodes

lottalinuxlinks forum

LLL podcast wallpapers

UCLUG podcast

UCLUG podcast in ogg format

Underground audio book

My Frappr Map

emelfm2 for Ubuntu

latest fluxbox for Ubuntu

translucent fvwm for Ubuntu

Linux Tips

Screenshots

Wallpapers

Live Desktop Screenshot

Church Podcast

Holy Bible

How can a man be born again?

daily devotional

MY WEBCAM

NERD CAM

me powered by blosxom

Mon, 14 Aug 2006

Convert a dos file foramtted text file to a unix file formatted text file
Step 1

vim dosfile.txt

Step 2

:set ff=unix

Step 3

:qw

posted 22:41 [/podcast/shownotes] permanent link

Discuss: 0 comments


Create a time stamped text file in vim
vim `date +%s`.txt

Easy as pie.

posted 22:39 [/podcast/shownotes] permanent link

Discuss: 0 comments


my simple backup script revisited
This is just a simple example of how to easily backup crucial directories from a webserver to two different hard drives on a remote backup computer

Assumptions made in this example: 2424 is the alternate port number, and public key has already generated and exchanged with remote computer. Substitute username with your username, substitute backup_computer_name with the name of the remote computer you are backing up to, and substitute /stuff/backup/ with the directory path on the remote computer where you will be storing the backups. Substitute /bigbox/backup/ with the directory path on the second hard drive on the remote computer where you will be copying the tarball that was created on the first hard drive.

#!/bin/bash

# example backup script

tar zcf - /etc/apache/ | ssh -p2424 backup_computer_name "cd /stuff/backup;cat > apache.tgz;cp apache.tgz /bigbox/backup/apache.tgz";

tar zcf - /home/username/bin/ | ssh -p2424 backup_computer_name "cd /stuff/backup;cat > home_username_bin.tgz;cp home_username_bin.tgz /bigbox/backup/home_username_bin.tgz";

tar zcf - /home/username/download/ | ssh -p2424 bakup_computer_name "cd /stuff/backup;cat > home_username_download.tgz;cp home_username_download.tgz /bigbox/backup/home_username_download.tgz"

tar zcf - /var/www/ | ssh -p2424 backup_computer_name "cd /stuff/backup;cat > www.tgz;cp www.tgz /bigbox/backup/www.tgz"

# exit cleanly

exit 0

This script is best run from a cron job as root.

posted 22:38 [/podcast/shownotes] permanent link

Discuss: 0 comments


200 linux tips added to tip database
I just added 200 more tips for a total of 750 to the linux tips database

750 linux tips

posted 22:25 [] permanent link

Discuss: 0 comments



Google
 

voice mail

or call 864-372-4028

August
S M T W T F S
   
14
   

2007 post

2006 post

2005 post

2004 post

2002-2004 archived

play ogg