Bookmark, share, and hop your favorite sites with SiteHoppin Toolbar for Firefox!



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 ...


Bottle Opener USB Flash Drive!

Posted in A+Featured Gadgets, Computer, Consumer, Cool, Design, Entertainment, Gadgets, Storage, USB by max on the September 9th, 2008 at 11:46 pm
Bottle Opener USB Flash Drive!

Bottle Opener USB Flash Drive!

Although I rather use a lighter to open a beer bottle, for those of you who don’t smoke, you can get the Bottle Opener USB Flash Drive.

Just make sure you don’t take this to a raving party with tons of people as you might regret lending it to the partier next to you with all that classified data inside the Flash Drive.

The TrekStor USB thumb drive doubles as a bottle opener. Yep, it can store between 1GB and 16GB of data, and it can open up your frosty brews as well. Make it your keychain and you’ll always have whatever data you want with you, be it documents or media files, and you’ll never be searching for a bottle opener again. It makes regular old thumb drives look downright featureless in comparison.

via dvice, Product Page

, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (1 votes, average: 5 out of 5)
Loading ... Loading ...


DIY Hacked USB Thumb Drive!

Posted in A+Featured DIYs, Computer, Consumer, Cool, Design, DoItYourself!, Educational, Entertainment, Funny, Gadgets, HOWTO, Hack, Hard Disk, Prank, Projects, Storage, USB by max on the September 9th, 2008 at 5:53 pm
DIY Hacked USB Thumb Drive!

DIY Hacked USB Thumb Drive!

For those of you who need a real USB Thumb drive, this might not be the right picture but for those of you who want to have some fun, just go and grab an old harddrive, USB ports, and couple USB Flash Drives for a real good Thumb Drive laughs.

This ordinary looking hard drive when plugged into a USB port will mount 4 USB thumbdrives onto your computer. Cool idea to make some use of some old computer parts. It would have been cool if the drive would spin up when one of the drives were being accessed.

via hackedgadgets, DIY Page

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


USB “Thumb” Flash Drive!

Posted in A+Featured Gadgets, Computer, Consumer, Cool, Design, Entertainment, Gadgets, Storage, USB by max on the September 9th, 2008 at 4:44 pm

It’s not that often that a manufacturer takes things literally and makes a USB “Thumb” Flash Drive, but you are glad that they did.

Features:

  • USB 2.0 High Speed
  • Plug and Play, Hot-Swapped capability
  • Mass storage compliant
  • Support: Windows Vista, XP, 2000 and Mac OS
  • Dimensions: 55 x 24 x 22mm (approx.)
  • Weight: 18g
  • via geekalerts, Product Page

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


    Mooncake USB Flash Drive!

    Posted in A+Featured Gadgets, Computer, Consumer, Cool, Entertainment, Food, Funny, Gadgets, Storage, USB by max on the September 2nd, 2008 at 7:10 am
    Mooncake USB Flash Drive!

    Mooncake USB Flash Drive!

    For all I know, there’s way too many “food” USB Flash Drives and here’s another Mooncake USB Flash Drive, which I suppose are targetting Chinese people.

    Mooncakes are Chinese pastry traditionally eaten during the Mid-Autumn Festival. These little geeky USB thumb drives look so real, don’t chew it, don’t ever put them in your mouth. Keep them away from your kids or they’ll swallow!

    via brando

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


    Machine Gun Bullet USB Flash Drive!

    Posted in Computer, Consumer, Cool, Design, Gadgets, Storage, USB by max on the September 1st, 2008 at 7:42 am

    Here’s an innovative idea for a USB Flash Drive, embed it in a machine gun bullet.

    via gearfuse, nebol, mojolabs

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


    Headless Teddy Bear USB Flash Drive!

    Posted in A+Featured Gadgets, Computer, Consumer, Cool, Design, Entertainment, Gadgets, Gifts, Storage, USB, kids by max on the August 26th, 2008 at 10:25 am

    Headless Teddy Bear USB Flash Drive!

    Check out this Teddy Bear USB Flash Drive that will lose it’s head just so you can stick it in your computer.

    Sorta cool until the head falls off, maybe they should market the product with the head on for better reception by consumers.

  • Hi-Speed USB 2.0 certified, backward compatible with USB 1.1
  • Plug and Play, Hot-Swapped capability
  • Mass Storage Device class compatible.
  • Support: Windows Vista, XP, 2000 and Mac OS
  • Dimensions: 8cm x 9.5cm tall (approx.)
  • Weight: 20g
  • via geekalerts, Product Page

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


    USB “Key” Flash Drives!

    Posted in A+Featured Gadgets, Computer, Consumer, Cool, Design, Gadgets, Storage, USB by max on the August 25th, 2008 at 3:25 pm

    Check out these new USB “Key”-shaped flash drives that you can link on your keychain.

    Aexea KeyXpress Flash Drive is a fashionable and stylish mass storage device. You can hook it on your mobile phone so that your data and information will be there wherever you go. Just plug it into the USB port, and the computer will automatically detect and configure without restarting.

    via techfresh, brando

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


    Wooden USB Flash Drive!

    Posted in A+Featured Gadgets, Consumer, Cool, Design, Gadgets, Storage, USB by max on the August 20th, 2008 at 11:06 pm

    Wooden USB Flash Drive!

    I do prefer wooden USBs over plastic ones simply due to the fact that they are more shock-absorbent upon dropping them from high floors.

    This one is from Japan and does indeed look pretty cool.

    I like this Wooden Thumb Drive. Its casing is made of cedar wood and provides 1GB of storage capacity. The Wooden Thumb Drive retails for approx. $62 in Japan.

    via techfresh, Product Page, Product Press Release

    Related:

    wooden flash drive

    Wooden USB Flash Drive

    DIY - How to Make a USB Wooden Drive out of a Cruzer USB!

    How to convert your USB drive into a wooden USB

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