Monday, October 29, 2012

Linux: Cool your CPU temperature with frequency throttling

Last night I went to sleep while running a heavy program that used 100% of my Intel i7 multicore processor. When I woke up in the morning, I found my laptop powered off. A look through the /var/log/syslog confirmed that it had shut off due to over heating.

So to control temperature, I wrote a script to throttle cpu frequency. This script must be run with root privileges (sudo) to work. For a desired max temperature of 80 degrees Celsius, use a command like this:
sudo ./temp_throttle.sh 80

This can also result in longer battery life on laptops and portable devices.


Download link: temperature throttling script for Linux - temp_throttle.sh
New User Resources:

Download link: temperature throttling script for Linux - temp_throttle.sh

Project source page: https://github.com/Sepero/temp-throttle



NOTICE: This script may not be effective if your system over heating is due to factors other than your CPU (ie. graphics, harddrive, etc.). This script will only throttle your CPU frequency based on your systems reported temperature. Opening and cleaning dust from a computer can often dramatically help cool it also.

If this script helps you in any way, please pay me with a message of thanks, and share this page with others.


Comment or leave feedback sepero 111 @ gmx . com

Keywords:
overheating cpu scaling temperature control Linux

Wednesday, October 17, 2012

Solved - 4shared desktop crashes on Linux (desktop4shared)

4shared currently offers a massive 15GB of storage for free on their servers, and they offer a Java client program for Ubuntu/Debian Linux named 'desktop4shared'.

When trying to run this program with Ubuntu 12.04 (or perhaps Ubuntu 12.10), the following error can occur:
$ desktop4shared 
Guessing JAVA_HOME...
Assuming JAVA_HOME=/usr/lib/jvm/java-6-openjdk-amd64
Starting desktop4shared...
19:59:43 [AWT-EventQueue-0] INFO  Initialize - UI Initialized in 215
19:59:49 [main] ERROR common.GlobalExceptionHandler - Uncaught exception in thread [main] : the number of constructors during runtime and compile time for groovy.util.FactoryBuilderSupport do not match. Expected 3 but got 2
java.lang.IncompatibleClassChangeError: the number of constructors during runtime and compile time for groovy.util.FactoryBuilderSupport do not match. Expected 3 but got 2
        at griffon.app.ApplicationBuilder.<init>(ApplicationBuilder.groovy:26) ~[griffon-rt-0.9.jar:0.9]
        at griffon.app.ApplicationBuilder.<init>(ApplicationBuilder.groovy) ~[griffon-rt-0.9.jar:0.9]
        at griffon.builder.UberBuilder.uberInit(UberBuilder.groovy:73) ~[griffon-rt-0.9.jar:0.9]
        at org.codehaus.griffon.runtime.util.CompositeBuilderHelper.handleLocalBuilder(CompositeBuilderHelper.groovy:86) ~[griffon-rt-0.9.jar:0.9]
        at org.codehaus.griffon.runtime.util.CompositeBuilderHelper$handleLocalBuilder.callStatic(Unknown Source) ~[na:na]
        at org.codehaus.griffon.runtime.util.CompositeBuilderHelper$_createBuilder_closure1.doCall(CompositeBuilderHelper.groovy:51) ~[griffon-rt-0.9.jar:0.9]
        at org.codehaus.griffon.runtime.util.CompositeBuilderHelper.createBuilder(CompositeBuilderHelper.groovy:50) ~[griffon-rt-0.9.jar:0.9]
        at org.codehaus.griffon.runtime.util.CompositeBuilderHelper$createBuilder.call(Unknown Source) ~[na:na]
        at org.codehaus.griffon.runtime.util.GriffonApplicationHelper.buildMVCGroup(GriffonApplicationHelper.groovy:233) ~[griffon-rt-0.9.jar:0.9]
        at org.codehaus.griffon.runtime.util.GriffonApplicationHelper$buildMVCGroup.callStatic(Unknown Source) ~[na:na]
        at org.codehaus.griffon.runtime.util.GriffonApplicationHelper.createMVCGroup(GriffonApplicationHelper.groovy:191) ~[griffon-rt-0.9.jar:0.9]
        at org.codehaus.griffon.runtime.util.GriffonApplicationHelper$createMVCGroup$0.callStatic(Unknown Source) ~[na:na]
        at org.codehaus.griffon.runtime.util.GriffonApplicationHelper.createMVCGroup(GriffonApplicationHelper.groovy:171) ~[griffon-rt-0.9.jar:0.9]
        at org.codehaus.griffon.runtime.util.GriffonApplicationHelper$createMVCGroup.call(Unknown Source) ~[na:na]
        at griffon.core.BaseGriffonApplication$_startup_closure2.doCall(BaseGriffonApplication.groovy:178) ~[griffon-rt-0.9.jar:0.9]
        at griffon.core.BaseGriffonApplication.startup(BaseGriffonApplication.groovy:177) ~[griffon-rt-0.9.jar:0.9]
        at griffon.core.GriffonApplication$startup.call(Unknown Source) ~[na:na]
        at griffon.swing.SwingApplication.startup(SwingApplication.groovy) ~[griffon-rt-0.9.jar:0.9]
        at griffon.core.GriffonApplication$startup.callCurrent(Unknown Source) ~[na:na]
        at griffon.swing.SwingApplication.realize(SwingApplication.groovy:61) ~[griffon-rt-0.9.jar:0.9]
        at griffon.application.StandaloneGriffonApplication$realize.call(Unknown Source) ~[na:na]
        at griffon.swing.SwingApplication.main(SwingApplication.groovy:107) ~[griffon-rt-0.9.jar:0.9]

Credit for figuring this problem out goes to a user by the handle Zorael over at UbuntuForums.org  http://ubuntuforums.org/showpost.php?p=12104449&postcount=4

The problem is that desktop4shared is using an outdated library reference in the library named "groovy". To fix this, an older version of groovy needs to be installed on the system.

Download the older library version here:
http://old-releases.ubuntu.com/ubuntu/pool/universe/g/groovy/groovy_1.7.10-2_all.deb

You should be able to click to install the library, but if that doesn't work, you may use this command in a terminal (correct the path location for your system):
sudo dpkg -i /path/to/groovy_1.7.10-2_all.deb

To prevent the library from accidentally upgrading, copy/paste these two commands into the terminal:
printf 'Package: groovy\nPin: version 1.7*\nPin-Priority: 1001\n' | sudo tee /etc/apt/preferences.d/groovy
echo groovy hold | sudo dpkg --set-selections


Comment or leave feedback sepero 111 @ gmx . com

Wednesday, September 26, 2012

How to download Hulu videos on Linux

UPDATE:

2013-08-29
The instructions on this page no longer seem to work properly with some or all videos. I'm leaving it posted for reference purposes. The php Huleech project may work for you, if you have a server setup.


 Intro

Downloading Hulu, bbc, pbs, and other videos on Linux is remarkably simple- once you know how. It took me quite a bit of digging to figure it out though.

These websites use a type of video transmission called rtmp, and this prevents them from being downloaded more easily, like good and trust worthy youtube videos.

Install

To download rtmp videos, you will first need to have installed the latest version of rtmpdump. (As of the time of this writing the latest version is rtmpdump 2.4) You may be able to easily install this package using your distributions software center.

After installing rtmpdump you should have access to 3 commandline programs: rtmpdump, rtmpsrv, and rtmpsuck.

Local Script

Create a folder named "rtmp" (or whatever you like) to download your videos to.

In that folder, save this as a file named "riprtmp.sh"
#!/bin/bash
# riprtmp.sh

# Redirect rtmp internet signals locally.
sudo iptables -t nat -A OUTPUT -p tcp --dport 1935 -j REDIRECT

# load video into browser and run rtmpsrv
exec 2> /dev/null # Comment out this line if having problems.
rtmpsrv | grep "rtmpdump" | tee ripinfo.txt &
echo "Press enter after trying to load video"
read i
killall rtmpsrv
echo "Output sent to ripinfo.txt"

# Undo previous redirect for rtmp signals.
sudo iptables -t nat -D OUTPUT -p tcp --dport 1935 -j REDIRECT


After saving the file, be sure to set executable permissions so that you can run it as a script: chmod +x riprtmp.sh. This script will be used to collect the info we need for rtmpdump to download the video locally.

How To Run It

At this point everything should be ready! Here are the steps to get the video you want to download.
  • Open a commandline and navigate to your "rtmp" directory.
  • Begin running the script ./riprtmp.sh. It will prompt for administrator access, and you need to enter your password.
  • Try to load the video in Firefox (the video should fail to load because it is being redirected to rtmpsrv in the script).
  • After the video fails to load, go back to the script and press Enter.
  • A new file now exists called "ripinfo.txt". Open this file.
  • Inside the "ripinfo.txt" there should be a long line that starts with "rtmpdump".
  • Copy and paste that long "rtmpdump" line into the commandline and press Enter.
  • Your video should now be downloading.


Happy offline video watching.
Comment or leave feedback sepero 111 @ gmx . com

Friday, June 8, 2012

How To fsck a Truecrypt Volume (solution)

In Linux, unencrypting a truecrypt volume as "unmounted" will create a temporary file like this
/tmp/.truecrypt_aux_mnt1/volume



Recently when trying to run fsck or e2fsck on a corrupted truecrypt volume, I was presented with this
# fsck.ext4 -p /tmp/.truecrypt_aux_mnt1/volume
/tmp/.truecrypt_aux_mnt1/volume: recovering journal
fsck.ext4: unable to set superblock flags on /tmp/.truecrypt_aux_mnt1/volume


/tmp/.truecrypt_aux_mnt1/volume: ********** WARNING: Filesystem still has errors **********




Most websites will tell you to recover using a separate super block, but that is likely not the problem here. The problem is that fsck.ext4 can't properly fix an ext4 image file directly. The file must be mounted with losetup, and then it can be checked properly.
# losetup -f /tmp/.truecrypt_aux_mnt1/volume
# fsck.ext4 /dev/loop0e2fsck 1.42 (29-Nov-2011)
/dev/loop0: recovering journal
Setting free inodes count to 15549549 (was 15549553)
Setting free blocks count to 19290620 (was 19290665)



After mounting the image to a loopback device you can see that fsck was successful. To unmount the image from the loopback device, run
# losetup -d /dev/loop0



encrypted mounting ubuntu


Comment or leave feedback sepero 111 @ gmx . com

Monday, May 28, 2012

Install Puppy Linux to USB without a CD (extracting files out)

[This is a rough guide, open for improvement. Leave any tips in a comment, or email me.]

A couple days ago I installed Puppy Linux (Precise 5.4.3) to a USB Flashdrive without a CD. I couldn't find a decent guide for this anywhere, so I figured it out primarily with help from a DSL tutorial. I did the install using Ubuntu Linux (which has built in support for reading iso files). If you are on another operating system, you will need some software like WinCDEmu to read the files from the iso file. You will also need to have Syslinux software to install a bootloader on the device.
apt-get install syslinux

Puppy Linux is great because it will fit on those old 256MB, 512MB, and 1GB USB disks, giving them new life.

Here I will roughly list the steps required to install Puppy Linux to USB.

  1. Format the usb to fat32 file system.
  2. I don't think this is completely necessary, but if possible, mark the usb partition as bootable. (using a program like fdisk)
  3. Prepare (mount) the Puppy Linux iso file so that you can for read/extract the files from it.
  4. Copy all the files from the iso to the usb stick.
  5. Create an empty file on the USB drive named: USBFLASH
  6. On the USB, rename the file isolinux.cfg to syslinux.cfg.
  7. Edit syslinux.cfg and change "pmedia=cd" to "pmedia=usbflash". (Be aware, editing this file may prevent USB booting if your editor modifies carriage return on the line ends.)
  8. Install syslinux loader to the USB drive in Linux
    syslinux -s /dev/sdb1

    Install syslinux loader to the USB drive in Windows (assuming F: is your usb)
    syslinux.exe -mas F:


Congratulations if you made it this far. You should now be able to reboot into your new Puppy Linux USB installation. Here is another great resource for installing syslinux, which may help on using with Windows-  http://www.syslinux.org/wiki/index.php/HowTos

Resources:
Puppy Linux pmedia options, and other flags.
quicklist: usbflash usbhd usbcd ideflash idehd idecd idezip satahd satacd scsihd


Comment or leave feedback sepero 111 @ gmx . com

keywords
usb stick pendrive flashdrive pen flash drive puppylinux

Tuesday, May 15, 2012

Django REMOVE_SLASH

If you're coming from another CMS or Framework like me, then Django is probably messing up your weblinks too with the APPEND_SLASH option. (Since when is it more user friendly or beneficial to put a slash after every url? Most websites on the internet leave the end slash off, and Django seems to be going against common convention in this regard.)

You could leave APPEND_SLASH off, but this may lead to problems with SEO.

Anyway, I love Django in many other ways, and thankfully Django is flexible enough to allow us to fix this problem. I developed a middleware that basically does the opposite of APPEND_SLASH, and it's accordingly named Remove Slash Middleware.

It simply works like this:
1. Remove all slashes from the end of the requested url.
2. If the url location is not found, then add one slash '/' and try again.


Now you can choose to get rid of all those slashes at the ends of your urls. Delete, subtract, pop, erase those slashes.
https://gist.github.com/2204099
https://gist.github.com/gists/2204099/download


Comment or leave feedback sepero 111 @ gmx . com

Friday, May 11, 2012

OpenShot won't display audio Waveforms

Let me start by saying I like the video editor OpenShot. It looks good, and it has a clean, well organized interface. The worst thing I can really complain about is the razor tool. You would never find a bizarre tool like that in a well made proprietary video editing program (it can be beneficial to have a look at your competition). But I'm extremely willing to compromise when it comes to OSS, so that is something I could honestly adapt to over time.

Though, there is one thing preventing me from using OpenShot Entirely- lack of visual audio waveform. I can't see a visual of my audio.

When I record screencasts, about half the audio is actual dialog, and the other half is "um, uh", or silence. These long periods of garbage need to be cut out, sometimes with little bursts of audio that I need to keep. Without visual audio, this is a form of torture that I cannot endure. I would actually have to play the whole video (which could be hours in length), and listen closely to it. Only stopping to edit whenever I hear a bit of audio.

Additionally when cutting, it's is incredibly imprecise when it comes to sound. Because I can't see the audio, I can't be sure if I'm cutting a few seconds before the audio begins, or a few seconds after the audio begins. Ideally, I need to know at exactly what frame the audio begins on. The only way I can find out is by wasting more time listening to the video audio, and repeatedly undoing/redoing mistakes.

With a visual waveform, I can scan several hours of audio, cutting out huge chucks of silence quickly and efficiently. With a visual waveform, I can tell exactly where audio begins and ends. I can realign audio to different locations in the video with ease.

Ultimately this situation really sucks, because I rarely use any transitions or special effects at all, so it's not like I'm in need of something flashy or superfluous. I just need some basic video editing functionality. I understand that being a developer on such a project can often be a thankless job, so I want to say thank you OpenShot developers for all your hard work. I hope in the near future that I too will be able to use your video software.


Comment or leave feedback sepero 111 @ gmx . com

Wednesday, May 2, 2012

Webmasters- Don't Neglect Visitor Feedback

Today I will remark on a very common issue, neglecting visitor feedback. If you want the largest amount of great feedback, this is my advice-

Allow visitors to give textual feedback directly on the page they are currently on, and have it displayed on that page for others to see.

God forbid that visitors correct (or suggest corrections to):
  • Typos
  • Grammar
  • Broken links
  • Incorrect information
  • Outdated information
  • Page order, organization


There are different ways to allow visitor feedback:
  • wiki page implementation (should always include a separate "talk" page for every informational page)
  • visitor comments on page, and visible to others
  • a url to a contact page, email, mailing-list, or forum

Note:
The only intelligent reason I can think of making visitor feedback difficult is if your content is highly controversial, or "politically incorrect". You will surely become vandalized often if that is the case.



Wiki

When should you use wiki implementation?
  • Whenever information changes over time.
  • Whenever it's possible that the information could be more complete.


Recognize that vandalization will always occur with wiki style pages, but the positives can often out weigh the negatives. Is your content more likely to be vandalized than the average website? These are all pretty subjective criteria, so you just have to make an estimation of your own level here.

A wiki implementation allows visitors to easily fill in gaps of information. Wiki can also lead to visitors making tiny edits/corrections here and there- innovative little ideas about writing things that would have never crossed your mind.

Wikipedia.com has moderators, registered users, and even allows for some anonymous user editing. They are an excellent example of how to implement wiki style editing.




Comments

When should you use page comments?
  • Anytime you're not implementing wiki.

Yes, you read that right. Simply put, if it's not a wiki type page, you should implement visitors comments. Why the hell wouldn't you? If you don't allow comments because you are trying to avoid spam, think again. The amount of spam you receive will be proportional to amount of quality feedback you get. If you exclude comments to reduce spam, you're successfully reducing quality feedback also.

Many people like to read the comments of others and this can also keep visitors on your site longer. Visitor comments can sometimes reveal tremendously informative things that were not mentioned by the page author. Also, having other visitor comments displayed will encourage new visitors to be less shy about giving their input on the page.


How to handle comments-
Use common sense. You want comments to be super easy, while also reducing spambots. An excellent solution to this problem is OpenID login. People can still remain semi-anonymous, while still being scrutinized on an identity basis. The barrier to leave feedback is very low, while amount of spam protection is just as high as if you had gotten their credentials directly. On a website I previously ran, I permitted anonymous comments, and I setup filters to moderate comments that posted url links (likely spam). Also comments were blocked based on a honeypot input system. The filters would automatically block and remove any repeat offenders. This successfully allowed anyone to comment, while having virtually no spam.



Contact Page, Email, Mailing-list, or Forum


These are all good forms of contact, but none are an intelligent replacement for wiki or on page comments! These forms of feedback should be thought of as complimentary. They require more initial time, preparation, and knowledge from from the user. They also may require the user to reveal more information than they may be willing to divulge (therefore preventing them from giving feedback at all).

These forms of contact act to compliment a good feedback system, but often are poor if used alone.





Conclusion

Every website is going to have different needs, but we create all this content for the visitors. If we are doing something wrong, we should be smart enough to allow those visitors to let us know.

Tuesday, May 1, 2012

Manually Install Django-Nonrel 1.5

At the time of this writing, the installation guide for Django-Nonrel does not list the most updated repositories and is misleading. So I'm writing this to give some people a clue who are trying to figure the puzzle out.

If you just want to easily install Django-Nonrel for Google App Engine right now, then use the Django-Nonrel Installer (supports versions 1.3, 1.4, and 1.5)


Here are the steps for a manual install of django-nonrel:
  1. Download the all needed archives.
http://github.com/django-nonrel/django/tarball/nonrel-1.5-beta
http://github.com/django-nonrel/djangotoolbox/tarball/toolbox-1.5-beta
http://github.com/django-nonrel/djangoappengine/tarball/appengine-1.5-beta
http://github.com/django-nonrel/django-dbindexer/tarball/dbindexer-1.5-beta
http://github.com/django-nonrel/django-testapp/tarball/testapp-1.5-beta
http://github.com/django-nonrel/nonrel-search/tarball/develop
http://github.com/django-nonrel/django-permission-backend-nonrel/tarball/develop
http://bitbucket.org/twanschik/django-autoload/get/default.tar.gz

Also needed for MongoDB backend:
http://github.com/django-nonrel/mongodb-engine/tarball/master
http://github.com/django-nonrel/mongodb-cache/tarball/master

*Advance warning. Django-Testapp does not work with MongoDB at the time of this writing. So if you're installing MongoDB, but hopefully these instructions can get you in the right direction*


  1. Extract the archives.
  2. It's recommended (not mandatory) to rename every folder to something more relevant.
Example:
rename django-nonrel-nonrel-search-cd54e52/ to nonrel-search/


  1. A) If you know how symbolic linking works, link all of the libraries into the folder django-testapp/
This can be tricky because many of the libraries are an extra level deep in structure. You have to look inside each folder and find the name of the library folder. The library folder inside nonrel-search is named "search".
Example:
cd django-testapp
ln -s ../nonrel-search/search .


  1. B) If you're unfamiliar with symbolic linking or if you're on a Microsoft system, just move the library folders directly into the django-testapp/ folder.
Again, you have to look inside each folder and find the name of the library folder.
Example:
cut nonrel-search/search/ paste into django-testapp/


    Finished
    At this time you should have a complete setup. If you have the GAE sdk installed and listed in your $PATH, you can test out the local server. Change to the directory django-testapp/ and start up the local server by running a command similar to this:
    $ python manage.py runserver

    Then point your browser to:
    http://localhost:8000






    For more Django-Nonrel Documentation:
    http://docs.django-nonrel.org


    Update 2013 May 23:Fixed archive URLs, and updated to django -nonrel 1.5 beta.


    Comment or leave feedback sepero 111 @ gmx . com

    Saturday, April 28, 2012

    Installing Django-nonrel Easily Automated

    Notice: Development of this installer has been discontinued due to my personal discontinued use of django-nonrel. If anyone else would like to maintain this installer, contact me (sepero 111 @ gmx . com) and I will link to your work.

    If you've ever tried setting up django-nonrel for Google App Engine, then you realize that it can be a pain. Multiple archives to download, long directories to rename, trying to figure what goes where, and the extreme tediousness of setting up multiple symbolic links...

    This program will automate the process of installing Django-nonrel for GAE.

    Download Link:
    https://github.com/Sepero/django-nonrel-installer/archive/master.zip

    You will need to run it on the command line with the argument of your desired django-nonrel branch. The available arguments are:
    • --master    to install django-nonrel 1.3 master (This option will be removed in future releases.)
    • --dev13      to install django-nonrel 1.3 development
    • --dev14      to install django-nonrel 1.4 development
    • --dev15      to install django-nonrel 1.5 development
    • --clean      to erase the current install

    The installer should be run in the directory where it exists. Here is an example of how to install 1.5 development in a terminal 
    $ python dj_nonrel_install.py --dev15

    Installing 1.3 development in a terminal
    $ python dj_nonrel_install.py --dev13

    The folder "django-nonrel" will be created, and all files will be downloaded/installed within the folder for use with Google App Engine. After it's finished, just move/rename the directory to where ever you want the permanent location to be.

    Speed up creation of your development environment and get on to making awesome django apps! Any improvement suggestions or submissions are very welcome. This is tested on Linux, and will likely work on similar systems. It most definitely will not (yet?) run on MSWindows. Should now run on all Operating Systems!


    Download Link:
    https://github.com/Sepero/django-nonrel-installer/archive/master.zip
    https://github.com/Sepero/django-nonrel-installer


    Reference Links:
    Django Documentation - http://docs.djangoproject.com/en
    Django-Nonrel Documentation - http://djangoappengine.readthedocs.org/en/latest/index.html
    Django-Nonrel Mailing List - http://groups.google.com/group/django-non-relational




    Update 2012 Apr 28:
    Currently working to make the installer dual compatible with installing MongoDB also. (Use pip to install MongoDB.)

    Update 2012 May 01:
    Django-testapp doesn't work with MongoDB for some reason. A bug report has been filed with it's author. I'm sorry, but at the time of this writing, MongoDB support cannot yet be implemented.

    Update 2012 May 15:
    The installer has now been modified to work with all operating systems. For systems that don't support symbolic links, the libraries will be moved directly inside of the Django-Testapp folder.

    Update 2012 May 28:
    Support has been added for "master" and "develop" branches. Master is installed by default. To install development branches of django-nonrel, use the command line argument --dev.

    Update 2012 Jun 4:
    Added Reference Links.

    Update 2012 Sep 20:
    Fixed problem with downloading development branches.

    Update 2012 Dec 25:
    Branch 1.4 is now available to install. Changed to install all contents into a folder.

    Update 2013 Mar 14:
    Fix for djangoappengine library. Switched source hosting to github.

    Update 2013 May 19:
    Django-nonrel 1.5 now available to install. Fixed issue with urls and unittests. Updated program description.

    Update 2013 May 20:
    I've just been informed that "master" branches will retired and all branches will be considered development. The default install branch will be moving to 1.5 development.

    Last Update 2013 Sep 24:
    There will be no more updates of this installer as I no longer work with django-nonrel. You are free to take the code and continue work/updates on this project. Email me, or Leave a comment in the section below with a link to where others can find your work.


    Comment or email your feedback at sepero 111 @ gmx . com

    Friday, April 27, 2012

    Django-nonrel pissing me off

    Is it really so difficult to makes things relatively straight forward for the end user? The instructions for installing django-nonrel pretty much translate to "Just unzip the shit in a folder, dude! It's awesome *cue Bill and Ted air guitar music*"

    Ok, so I'm exaggerating somewhat, but the truth is it's not awesome. Instead it's a convoluted pain in the ass. Multiple files to download and untar. Ridiculous directory names that all have to be renamed. Half the libraries are an extra directory deep, while half aren't. If you're a developer worth half your salt, you'll likely setup the symbolic links instead of just dumping all the directories together. Setting up the symbolic links is made even more annoying and tedious because of the multiple links necessary, and the "hide n seek" nature of the libraries. As a large part of forgiveness, I understand that the django-nonrel team aren't to blame for at least half these issues.


    The solution? A program to automate the whole process, so you can get on with making awesome django apps! I'll be uploading my python program soon for the specific purpose of automating the install of django-nonrel. Hopefully it will help others out in getting jump started with an otherwise nice system.


    How it works:
    1. Create an empty working directory.
    2. Put the python program in there.
    3. Run it from inside that directory! *cue Bill and Ted guitar music*


    Just that easy. It will: download the zip files->extract them->delete the zips->properly name the new folders->create all symbolic links->give you a hint to get going


    Update:
    Get it all here- Django-nonrel Easy Automated Installer
    http://seperohacker.blogspot.com/2012/04/installing-django-nonrel-easily.html



    Comment or email your feedback at sepero 111 @ gmx . com

    Binary Grep Program: SearchBin

    SearchBin is a fast commandline program for searching within binary files. It's a bit like grep for binaries.

    It has three capabilities for searching.
    -Search for bytes using hexidecimal
    -Search for a plain text string
    -Search for a smaller binary file


    EXAMPLES
    Search for the hex bytes "FF14DE" in the file gamefile.db:
    $ ./searchbin.py -p "FF14DE" gamefile.db
    Match at offset:            907          38B in  gamefile.db
    Match at offset:           1881          759 in  gamefile.db
    Match at offset:           7284         1C74 in  gamefile.db
    Match at offset:           7420         1CFC in  gamefile.db
    Match at offset:           8096         1FA0 in  gamefile.db
    
    The printed offsets are listed in decimal and hex formats.


    You can also search for unknown patterns with "??". Just insert them where ever you have an unknown byte:
    $ ./searchbin.py -p "FF??DE" gamefile.db

    You can search through multiple files at once, and search piped input:
    $ ./searchbin.py -p "FF??EE" gamefile.db supersecret.idx
    $ cat gamefile.db | ./searchbin -p "0xFF??EE"

    You can also search using regular text strings and other binary files.
    $ ./searchbin.py -t "hello" gamefile.db
    ./searchbin.py -f binaryfile gamefile.db 



    Options of SearchBin:

    $ ./searchbin.py --help
    
    Optional Arguments:
      -h, --help            show help message and exit
      -f FILE, --file FILE  file to read search pattern from
      -t PATTERN, --text PATTERN
                            a (non-unicode case-sensitive) text string to search
                            for
      -p PATTERN, --pattern PATTERN
                            a hexidecimal pattern in format '0xFF'
      -b NUM, --buffer-size NUM
                            read buffer size (in bytes). 8MB default
      -s NUM, --start NUM   starting position in file to begin searching
      -e NUM, --end NUM     end search at this position, measuring from beginning
                            of file
      -m NUM, --max-count NUM
                            maximum number of matches to find
      -l FILE, --log FILE   write matched offsets to FILE, instead of standard
                            output
      -v, --verbose         verbose, output the number of bytes searched after
                            each buffer read
      -V, --version         print version information




    Extra Notes:
    An argument -t or -p or -f is required. The -p argument accepts a
    hexidecimal pattern string and allows for missing characters,
    such as 'FF??FF'. When using -f argument, the pattern file will
    be read as a binary file (not hex strings). If no search files are
    specified, %prog will read from standard input. The minimum memory
    required is about 3 times the size of the pattern byte length.
    Increasing buffer-size will increase program search speed for
    large search files. All size arguments (-b -s -e) are read in decimal
    format, for example: '-s 1024' will start searching after 1kilobyte.
    Pattern files do not allow for wildcard matching.
    Reported matches are displayed as 0-based offset.


    Further Examples:
    Search for the text string "Tom" in myfile.exe. Text is case sensitive.
    ./searchbin.py -t "Tom" myfile.exe

    Search for the text string "T?m" in myfile.exe, where ? is a wildcard. This will match "Tom" "Tim" "Twm" and all other variations, including non-printing bytes.
    ./searchbin.py -t "T?m" myfile.exe

    Search for the hexidecimal pattern "AABBCCDDEE" in myfile.exe.
    ./searchbin.py -p "AABBCCDDEE myfile.exe

    Searches for the hexidecimal pattern "AA??CC??EE" in myfile.exe, where ?? can be any byte value.
    ./searchbin.py -p "AA??CC??EE" myfile.exe

    Takes the binary file pattern.bin, and searches for an exact match within myfile.exe.
    ./searchbin.py -f pattern.bin myfile.exe





    Features:
    +No compiling necessary
    +Requires Python 2.7 or Python 3
    +Less code
    +Search in files of unlimited size
    keywords: hex hexidecimal binary like grep search seek find fast



    DOWNLOAD it from here:
    https://github.com/Sepero/SearchBin/archive/master.zip

    Source:
    https://github.com/Sepero/SearchBin

    Report Problems, Suggestions, or Thanks to sepero 111 @ gmx . com
      or https://github.com/Sepero/SearchBin/issues




    2012 Jun 19 Update:
    Major over haul to search function. Dramatically increased search speed for wildcard patterns. Also included search functionality for regular text strings.

    2012 Jun 28 Update:
    Made updates to Readme file and added more comments to code for readability.
    Also, I moved all files to Mercurial and bitbucket.com.

    2012 Jul 07 Update:
    Unifying all documentation. Publishing to freecode.com

    2013 Feb 02 Update:
    Switched code indentation to tabs as it is a universal standard. Moved code back to github due to its popularirty.

    2013 Oct 11 Update:
    Added Python 3 support. Added in more unittests. Added in more information code comments. Updated documentation.