Shorten that Long GoogleMaps URL with CozyURL!


  • Page 1 of 2
  • 1
  • 2
  • >

Debian Hack - How to Setup your Mirror!

Posted in A+Featured Hacks, Computer, Consumer, Cool, DoItYourself!, Educational, HOWTO, Hack, Linux, Operating System, Storage, Ubuntu by max on the October 1st, 2008 at 1:39 pm

This might not be for all of you but for those Linuxers out there, here’s an example of how to setup your mirror:

(Mirror is a way of replicating one server to another btw if you didn’t know.)

To download the mirrors I use this script:
<script sync_mirror.sh>

#!/bin/bash
OPTIONS="--nosource --progress --postcleanup --ignore-release-gpg --ignore-small-errors --pdiff=none";
MIRROR=`basename ${0} | cut -f2 -d "_"`
DEST="/home/debian-mirror"
case "${MIRROR}" in
        "debian" )
                METHOD="--method=http"
                HOST="--host=ftp.de.debian.org"
                ROOT="--root=debian"
                DIST="--dist=etch,etch-proposed-updates"
                ARCH="--arch=i386"
                SECTION="--section=main,contrib,non-free"
                DEST="${DEST}/debian/"
                ;;
       "security" )
               METHOD="--method=ftp"
               HOST="--host=security.debian.org"
               ROOT="--root=/debian-security/"
               DIST="--dist=etch/updates"
               ARCH="--arch=i386"
               SECTION="--section=main,contrib,non-free"
               DEST="${DEST}/debian-security/"
               ;;
        "volatile" )
                METHOD="--method=http"
                HOST="--host=volatile.debian.org"
                ROOT="--root=debian-volatile"
                DIST="--dist=etch/volatile"
                ARCH="--arch=i386"
                SECTION="--section=main,contrib,non-free"
                DEST="${DEST}/debian-volatile/"
                ;;
        "multimedia" )
                METHOD="--method=http"
                HOST="--host=www.debian-multimedia.org"
                ROOT="--root=/"
                DIST="--dist=etch"
                ARCH="--arch=i386"
                SECTION="--section=main"
                DEST="${DEST}/debian-multimedia/"
                ;;
        "backports" )
                METHOD="--method=http"
                HOST="--host=www.backports.org"
                ROOT="--root=debian"
                DIST="--dist=etch-backports"
                ARCH="--arch=i386"
                SECTION="--section=main,contrib,non-free"
                DEST="${DEST}/debian-backports/"
                ;;
        * )
                echo "${0} called incorrectly"
                exit
                ;;
esac
debmirror ${OPTIONS} ${METHOD} ${HOST} ${ROOT} ${DIST} ${ARCH} ${SECTION} ${DEST}

</script sync_mirror.sh>

To setup the permissions I use this script:
<script permissions.sh>

#!/bin/bash
MIRROR=`basename ${0} | cut -f2 -d "_"`
DEST="/home/debian-mirror"
case "${MIRROR}" in
        "debian" )
                DEST="${DEST}/debian/"
                ;;
        "security" )
                DEST="${DEST}/debian-security/"
                ;;
        "volatile" )
                DEST="${DEST}/debian-volatile/"
                ;;
        "multimedia" )
                DEST="${DEST}/debian-multimedia/"
                ;;
        "backports" )
                DEST="${DEST}/debian-backports/"
                ;;
        * )
                echo "${0} called incorrectly"
                exit
                ;;
esac
echo "Setting Ownership"
chown -R www-data:www-data ${DEST}
echo "Setting File Permissions"
chmod -R 660 ${DEST}
echo "Setting Folder Permissions"
find ${DEST} -type d -exec chmod 770 {} \;

</script permissions.sh>

And then to pull it all together I have thefollowing directory structure (mirrors left out as it’s a ling list of files)

/home/debian-mirror/
|-- debian
|-- debian-backports
|-- debian-multimedia
|-- debian-security
|-- debian-volatile
|-- scripts
|   |-- permissions.sh
|   `-- sync_mirror.sh
`-- scripts.d
    |-- mirror_backports -> ../scripts/sync_mirror.sh
    |-- mirror_debian -> ../scripts/sync_mirror.sh
    |-- mirror_multimedia -> ../scripts/sync_mirror.sh
    |-- mirror_security -> ../scripts/sync_mirror.sh
    |-- mirror_volatile -> ../scripts/sync_mirror.sh
    |-- permissions_backports -> ../scripts/permissions.sh
    |-- permissions_debian -> ../scripts/permissions.sh
    |-- permissions_multimedia -> ../scripts/permissions.sh
    |-- permissions_security -> ../scripts/permissions.sh
    `-- permissions_volatile -> ../scripts/permissions.sh

And then I just setup a cronjob:

0 0     * * 0   root    /bin/run-parts --verbose /home/debian-mirror/scripts.d | /usr/bin/mailx -s "`uname -n` - Debian mirror sync completed" root

This was to disable the mirroring of one of the repositories I just need to remove the symlink from the scripts.d folder

via nighthawk

, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...


Sanyo XGA Projector with Ultra-short Projection Distance!

Posted in Business, Consumer, Cool, Gadgets by max on the August 1st, 2008 at 5:49 am

Sanyo XGA Projector with Ultra-short Projection Distance!

Sanyo is coming out with a new projector that will allow you to project an XGA screen about as short as 3 inches.

This might be a great time for us to buy a blank poster and one of these for monitor.

SEOUL, Korea (AVING) — <Visual News> Sanyo has presented its ultra-short throw XGA projector ‘PLC-XL50′ in Korea market, which is able to get a bright, vibrant 80-inch diagonal image from a projector placed only 3 inches from the screen.

Supporting 2,000 ANSI lumens, it is great for conference rooms, and for spaces like storefront display windows where a conventional projector will not fit.

via aving

, , , , , , , , , , , , , , , , , , , , , , , , , , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...


Linux Server Hack - How to setup a Shell Script to Auto Restart Apache Httpd Server!

Posted in Blog, Cool, HOWTO, Hack, Web, Wordpress by max on the July 28th, 2008 at 1:21 pm

Well, I have been struggling with one of my dedicated servers and just found this cool script that will auto-restart the Apache httpd server if it goes out.

Save the following as restart.sh:

#!/bin/bash
# Apache Process Monitor
# Restart Apache Web Server When It Goes Down
# -------------------------------------------------------------------------
# Copyright (c) 2003 nixCraft project <http://cyberciti.biz/fb/>
# This script is licensed under GNU GPL version 2.0 or above
# -------------------------------------------------------------------------
# This script is part of nixCraft shell script collection (NSSC)
# Visit http://bash.cyberciti.biz/ for more information.
# -------------------------------------------------------------------------
# RHEL / CentOS / Fedora Linux restart command
RESTART="/sbin/service httpd restart"

# uncomment if you are using Debian / Ubuntu Linux
#RESTART="/etc/init.d/apache2 restart"

#path to pgrep command
PGREP="/usr/bin/pgrep"

# Httpd daemon name,
# Under RHEL/CentOS/Fedora it is httpd
# Under Debian 4.x it is apache2
HTTPD="httpd"

# find httpd pid
$PGREP ${HTTPD}

if [ $? -ne 0 ] # if apache not running
then
 # restart apache
 $RESTART
fi

Then setup a cron job like this: (usually in your sa-update file under /etc/cron.d)

*/5 * * * * root /root/restart.sh  >/dev/null 2>&1

via cyberciti

There’s also a program called Monit that will do more automation.

, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...


Ultimate Gamer’s Portable PC with 3 foldable screens!

Posted in Computer, Computer Case, Consumer, Cool, Design, Entertainment, Gadgets, Games, LCD by max on the June 7th, 2008 at 3:53 am
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...


Timberjack IronClad Glove in Action!

Posted in Consumer, Cool, Entertainment, Funny, Gadgets by max on the May 26th, 2008 at 7:47 pm

Timberjack IronClad Glove in Action!

Click Here to View in Full Screen Mode

Check out these Ironclad gloves and the best part, these guys are cutting down wood at the show!

Well, maybe that’s not so eco-friendly but it is entertaining…

LAS VEGAS, USA (AVING Special Report on ‘2008 NATIONAL HARDWARE SHOW’) — <Visual News> Timberjack enterprises demonstrated wood cutting show with ‘ironclad’ performance gloves and apparel wear at the 2008 National Hardware Show, May 6 ~8, in Las Vegas.

via aving

, , , , , , , , , , , , , , , , , , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...


Samsung Flash SSD - World’s Fastest Storage Device!

Posted in Computer, Consumer, Gadgets, Hard Disk by max on the May 26th, 2008 at 5:23 pm

Samsung Flash SSD - World\'s Fastest Storage Device!

Samsung has just announced their new FlashSSD drives.

With a read speed of 200MB/s and write speed of 160MB/s, The 256GB SSD is supposedly 2.4 times faster than you regular ol’ hard drive.

SEOUL, Korea (AVING) — <Visual News> Samsung Electronics announced today that it has developed its 2.5-inch, 256 GB multi-level cell(MLC) based SSD using a SATA II interface at the fifth annual Samsung Mobile Solution Forum held at the Westin Taipei Hotel.

With a sequential read speed of 200MB/s and sequential write speed of 160MB/s, Samsung’s MLC-based 2.5-inch 256GB SSD is about 2.4 times faster than a typical HDD. Furthermore, it is only 9.5millimeters (mm) thick, and measures 100.3×69.85 mm.

Samsung is expected to begin mass producing the 2.5-inch, 256GB SSD by year end, with customer samples available in September. A 1.8-inch version of the 256GB SSD is expected to be available in the fourth quarter of 2008.

via aving

, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...


Viewsonic Korea Launches a Curved 19″ LCD in Korea

Posted in Computer, Consumer, Gadgets, LCD by max on the May 26th, 2008 at 12:17 pm

Viewsonic Korea Launches a Curved 19\" LCD in Korea

Korea is becoming more of a central location where companies are launching products to test out the market.

Recently, Viewsonic launches their new curved 19″ LCD in Korea.  It doesn’t look curved to me but it must be just so slightly.

SEOUL, Korea (AVING) — <Visual News> Viewsonic Korea(www.viewsonic.com) announced the launch of its 19-inch wide LCD monitor ‘VX1962WM’ in Korea market, which is available in June.

Supporting 1680*1050 resolution, 6000:1 contrast ratio and 2ms response speed, the VX1962WM is equipped with DVR and D-SUB ports.

No words on pricing yet.

via aving

, , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...


Automated Digital Grill - Blue Ember 650 iQue’ grill

Posted in Consumer, Cooking, Cool, Food, Gadgets, Household by max on the May 19th, 2008 at 1:58 am

Click Here to View in Full Screen Mode

This is the kind of grill I need, the one that lowers its temperature automatically after the steak is cooked.

I am gettin’ hungry…  THis thang is going to change how we eat…steak that is of course, my favorite dish.

LAS VEGAS, USA (AVING Special Report on ‘2008 NATIONAL HARDWARE SHOW’) — <Visual News> Fiesta(www.fiestrabbq.com) introduced its revolutionary touch-screen digital controller grill ‘Blue Ember 650 iQue’ at the 2008 National Hardware Show, May 6 ~8, in Las Vegas.

The Blue Ember 650 iQue features a digital temperature setting that allows optimum control management system including preprogrammed meat settings to cook steak, chicken and more. In addition, it even lowers the grill temperature when the meat is done to prevent overcooked food.

It is available nationwide through selected independent retailers and stores such as Lowe’s, Sears and the Home Depot.

via aving

, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...


Samsung’s 82 Inch 120Hz LCD TV!

Posted in Consumer, Cool, Gadgets, Household, TV by max on the May 18th, 2008 at 11:54 pm

Bzizzers…this 82 inch 120Hz TV will make your life very very lazy.  On the other hand, you can always use it as a substitute for paintings.

SEOUL, Korea (AVING) — <Visual News> Samsung Electronics showcases the industry’s first 82-inch UD(Ultra Definition) LCD TV panel during SDI(Society for Information Display) 2008 in Los Angeles, USA, from May 18 to 23.

Supporting 3,840 x 2,160 resolution, this UD TV panel features 120Hz motion technology and LED backlight for maximum brightness and reliability.

In addition, Samsung introduces its multi-touch e-Board equipped with the 82-inch UD LCD panel as well as presents future display technologies such as 52-inch 3D display and e-Paper.

via Aving

, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...


  • Page 1 of 2
  • 1
  • 2
  • >