Tutorial

Windows with two network connections: internal and external

Posted in Blog, Tech, Tutorial on May 6th, 2011 by Matt – 2 Comments

This post applies to both Windows 7 and Windows XP (and probably the server OS’s as well).

At the office we have two available networks: An internal network with our servers that also has filtered internet and an external wifi network that just offers unfiltered internet.

The main issue is that, as an IT tech, I download a lot of large files that can slow down our network, so I often found myself using a laptop on our external wifi downloading items so that I don’t slow internal people down.

My goal was to have two network connections on my Windows 7 PC, one wired internal connection and one a wifi external connection. I also want my internet traffic to go over my wifi connection but at the same time any have the ability to access all the internal sources.

A warning before I start: Doing this incorrectly can open a giant security hole in your network, please don’t do it without the approval of your IT dept.

First, I simply hooked up both network connections and tested them both (by only plugging one in at a time and checking the internet) as fully functional.

Once both are functional you need to edit your routing table so the correct requests go over the correct network adapter.

You can do this via the command line, but I found the Nirsoft NetRouteView utility to make this whole process a whole bunch easier.

Download and extract the NetRouteView utility. Then if on Windows 7, right click the NetRouteView.exe file and select “Run as Administrator”.

NetRouteView with two connections

Click the “Interface Name” column title to sort your entries by interface like above.

Depending on your network only one or two changes should be made. First, you need to remove the 0.0.0.0 entry from your internal network. That entry is a “catch all”. We want the catch all on the outside network and not the inside. So remove 0.0.0.0 from your internal adapter and make sure its already there on your external connection.

For most people that should be it! But for me I had to add one entry to my internal network to get it to work. I wanted the whole 192.0.0.0 (that means anything that has a 192 for its first number in it’s IP address) to go on my internal network connection. So I added the following:

Adding a route

Adding a route

Thats it! To check that everything is going over the correct interface I added the Network Traffic gadget to my Windows 7 desktop twice (just drag it to the desktop twice from the gadget list). I made my internal connection red and my external connection green.

Network Traffic with two connections

Network Traffic with two connections

Now I can watch as I view a web page which adapter it’s going out.

Redirecting Lotus Notes Data to a Network Share

Posted in Blog, Tutorial on January 11th, 2011 by Matt – 2 Comments

I currently redirect users’ Lotus Notes data folder (the folder that contains their ID files as well as other personal files) to network shares. This allows for users to roam from computer to computer in our office and always have their data available. As far as IBM is concerned this is an unsupported configuration, they will not help you if you have issues. We’re currently using the 8.5.1 client with FixPack 4 installed.

Preparing Users Data for the Network

The first step is to copy a users Data folder onto a network share. The location of the share should be the same for all users. For example; each of our users has a “home” drive mapped to H: where they store their personal documents. Under this drive we have a folder titled “lotus” that we place a copy of the contents of their Data folder.

After you’ve copied the contents to the network share, you’ll need to edit the users notes.ini file thats located within that share. The line you’ll need to change in that file is “Directory=C:\…” change it to the location where you’ve copied their data. In my situation I change that line to “Directory=H:\lotus”

Redirecting Lotus to Look in the Network Share

Now that we have our user data in a network location, we need to tell lotus to look there and not in the usual Data folder location. There are a couple of methods to do this. First is using a registry entry and the second is actually editing the shortcuts. In my experience the shortcut method has been much more reliable.

Registry method:
For each user add the following registry entry (maybe as part of a log on script)
[HKEY_CURRENT_USER\Software\Lotus\Notes\8.0] “NotesIniPath”=”H:\\lotus\\notes.ini”

Redirecting via the Registry

 

Shortcut method:
Edit the shortcuts on the all users desktop and the start menu so the target line is as follows (quotation marks and all)
“C:\(Install location of Lotus Notes)\notes.exe” “=h:\lotus\notes.ini”

Redirecting via Editing Shortcuts

Some Notes (Get it?!)

Currently on Windows 7 I do a Single User Install of the Standard Client. I’ve found that if I do a multi-user install I get prompted for my ID password for ntaskldr.exe. Googling has not returned a way to correct this.

While this modification does allow users to roam between computers, they can not have more than one instance of Notes open at a time.

After you’ve successfully got Notes functioning redirected you can delete the Data directory from the local machine. As long as your redirects are in place, it will never be recreated.

My users are not administrators on their machines. A single user install by default stores the users Data folder in the Program Files directory, which a user can’t write to. But since we’re redirecting that folder to a writeable location the users never have any permission issues.

Thinning Down FireFox 4′s Tab Bar – Update!

Posted in Blog, Tech, Tutorial on September 16th, 2010 by Matt – 11 Comments

This post is now outdated, please see the update available here:

http://gdgtry.com/2011/01/thinning-down-firefox-4s-tab-bar-2/

My previous post about modifying FireFox 4′s tab bar layout has been one of the more popular posts on my blog. After updating to FF4 Beta 6 the modification broke, but I’ve found a solution:

#navigator-toolbox[tabsontop="true"] #TabsToolbar{
padding-left: 80px !important;
padding-right: 102px !important;
padding-top: 2px !important;
margin-top: -25px !important;
}

#appmenu-button{
padding: 3px 5px 3px 5px !important;
height: 20px !important;
}

As you can see, the only change is we tell the tab bar to move up 25 pixels from where it was. We also ditch the tab position as fixed as it’s not really necessary.

FireFox 4 with a better tab layout

This gets us back to our old style. I haven’t had time to test all the edge cases to see if it messes anything up, but it should get your normal browsing bar back to an acceptable size.

Finding out where a picture was taken using EXIF info

Posted in Blog, Random, Tech, Tutorial on August 18th, 2010 by Matt – 5 Comments

Alternate title: How to creepily stalk people using their pictures.

Since I’ve gotten an iPhone 4 I’ve stopped carrying a normal camera with me on outings. I find the iPhone’s camera more than sufficient for most of my photo needs. Many other people are also doing the same. The fun thing about most camera phones now, is that they tag image information with GPS coordinates. Thanks to some easy online tools, you can now track people only by their pictures.

Lets get an example. I did a Google Search for “shots taken with my iPhone” and the first result is a blog with “9 Cracking Shots Taken With My iPhone“. The second picture posted is a pic taken on a road supposedly in Death Valley. Lets see if it is.

A test image for GPS EXIF inforation

We can download a program to view where the photo was taken via its EXIF information. Programs like “Simple EXIF Viewer for Mac OSX” work well. Or you could install a FireFox extension like “EXIF Viewer“, it’s a very nice way to quickly view information for any image embedded on a web page. But both of these seem silly to install when you probably only need to view EXIF info once in a blue moon.

My new favorite way to view where photos were taken is to use online tools like “Jeffery’s EXIF Viewer” or the “Find EXIF” website. So, using our example, we would: Right click the image, Copy Image Location, Paste the image location into one of the online tools. In this example I’ve used Jeffery’s EXIF viewer that embeds a nice little Google Maps pin of where the image says it was taken. Results from the EXIF GPS information

And if you follow the links over to Google Maps, and drop a street view pin as close to GPS data as possible, you get this:

Results from the iPhone's GPS EXIF info

You can view the actual Google Street view location here. Pretty cool.

Fixing Windows XP CD Playback Stuttering and Skipping

Posted in Blog, Tech, Tutorial on July 12th, 2010 by Matt – Be the first to comment

One of our users has a HP desktop that was having issues playing audio from music CDs. The audio was constantly stuttering and skipping. I tried various software playback programs all with the same result.

The solution turned out to be a setting for the CD-Rom drive. The drive was configured to use PIO mode when it should be configured to use DMA mode. Switching to DMA mode resulted in smooth audio CD playback. Here’s how to change the setting:

Solving Audio CD Suttering in Windows XP

The steps:

  1. Right Click on My computer, click Manage
  2. Select Device Manager from the list on the left
  3. Expand the IDE ATA secton
  4. Right click on each IDE Channel (you may have multiple Secondaries and Primaries), click Properties
  5. Select the Advanced Settings tab
    Change the Transfer Mode to DMA if Available under each device
  6. Repeat steps 4 & 5 for each Primary and Secondary IDE Channel
  7. Reboot your computer

That should resolve the Audio CD stuttering and skipping under Windows XP.

Thinning Down FireFox 4′s Tab Bar

Posted in Blog, Tech, Tutorial on July 7th, 2010 by Matt – 64 Comments

This post is now outdated, please see the update here:

http://gdgtry.com/2011/01/thinning-down-firefox-4s-tab-bar-2/

If you’ve read my rant on window layout in a widescreen world you’d know that I dislike wasted vertical space in my window layouts.

FireFox 4 beta has just been released and they haven’t solved my pet issue… that silly title bar. Just look at the wasted screen real estate:

FireFox 4's Tab Layout

However, thanks to FireFox’s flexibility, the addition of a few lines to one file can solve the problem! Simply adding the following below the @namespace line:

#appmenu-button-container{
position: fixed !important;
}

#navigator-toolbox[tabsontop="true"] #TabsToolbar{
padding-left: 80px !important;
padding-right: 102px !important;
padding-top: 2px !important;
}

#appmenu-button{
padding: 3px 5px 3px 5px !important;
height: 20px !important;
}

To your userChrome.css file, and you now get this wonderful layout:

FireFox 4 with a better tab layout

Hooray!

The userChrome.css file is located in the following locations:

XP: C:\Documents and Settings\<user>\Application Data\Mozilla\Firefox\Profiles\<profile>\chrome\
Vista\7: C:\Users\<user>\AppData\Roaming\Mozilla\Firefox\Profiles\<profile>\chrome\

A note: This “fix” will look bad if you have FireFox set to not display that tab bar when you only have a single tab open. Just set FF to always show that tab bar to resolve the issue (FireFox Button > Options > Tabs > Always display tab bar).

EDIT: I changed a line in the navigation toolbox from margin-right to padding right. Using padding right gives a better look.

Schedule Automated Backups on Windows using SyncToy

Posted in Blog, Tech, Tutorial on June 18th, 2010 by Matt – Be the first to comment

“You do have backups… right?” Thats a phrase I’ve asked often and rarely gotten a “yes” reply. If your computer completely died tomorrow, would you be prepared?

With USB disk drive prices falling lower and lower every day, there’s no reason not to have your important documents backed up. For users of Apple’s Mac OSX, the process for setting up a full backup of their computer is a simple as plugging in a USB disk and telling the prompt that, yes, you want to use the disk for backing up. Under Microsoft’s Windows there’s never been a simple method. As far as most users know the only way to backup is to manually copy and paste their files onto a USB drive occasionally. They usually start doing this manual backing up after a loss of some sort, then gradually let their guard down until they’re no better off than before. If you’re one of those users who doesn’t backup, here’s a solution to your backup needs.

By the end of this tutorial you will have fully automated backups of your “My Documents” folder to a USB hard drive.

A note: This backup method keeps an exact copy of your My Documents folder and all changes you make to it on an external drive. If you accidentally delete a file from your My Documents, it will be deleted off of the backup USB drive. However it will automatically put a copy of the file in your Recycle Bin should you need to recover it.

We’re going to need one piece of hardware and one piece of software for this setup. The hardware will consist of a USB hard disk drive attached to your computer. The software we’re going to use is Microsoft’s SyncToy utility. Download it here: SyncToy from Microsoft and install it. Installing it is straight foward, hit “I Accept” a few times, check a box and then hit “Next” a few times. After you’ve installed it, go into your Start menu and open it.

This is the screen you’re greeted with when you first run SyncToy. The way SyncToy works is you set up “pairs” of folders. A “left” folder and a “right” folder. You can then set up three different ways for those folders to backup and copy files from one folder to the other. Click “Create New Folder Pair” to set up our first backup.

The left folder is the source you want to backup. Since our goal is to backup our whole My Documents folder, our My Documents folder is what we need to select. Click Browse under the left folder side then highlight “My Documents” if your on Windows XP or your user name if your on Windows Vista or 7 and then hit “OK”.

Now we need to select the “Right Folder” for where are backed up files will go to. In this case thats going to be our external hard drive. Hit Browse under the right folder side click the little plus sign or arrow next to “My Computer” then highlight your USB drive. The drive will most likely have  “E:” or “G:” name next to it. Now click the “Make New Folder” button so we have a place for all of our files to go. Give the folder a useful name like “My Documents Backup” and then hit “OK”. Now hit next to move on to the next step.

This screen is where we setup how we want the folder pairs to backup and copy files from our “left folder” to our “right folder”. We have three options: Synchronize, Echo and Contribute. The only one we care about for this tutorial is Echo. Echo will backup all of our files from our My Documents onto the USB drive. Select it and hit next.

The following is a description of the three backup method options. You can skip on to the next paragraph if you are just interested in getting the tutorial setup. Read on if you want to be able to use the SyncToy utility in a more advanced method.

  • Synchronize: This option will set up your folder pair so that any change you make to a file in either the left or right folder will be mirrored into the other folder. Example using this tutorial: If you add, delete or change a file off of the USB drive, it would add, delete or change it in of your My Documents.
  • Echo: This option is the traditional backup method. All file additions, deletions and changes in your left folder are mirrored over to your right folder. Any additions in your right folder will be ignored. Example: You add a file on My Documents, it gets copied to the USB drive. You change a file on the USB drive, the original from My Documents replaces it. You delete a file from the USB drive, it gets placed back from My Documents.
  • Contribute: This is exactly the same as Echo except it never deletes anything from the right folder (USB drive in our example). This may be the best backup method. If you accidentally delete a file from your My Documents, you can recover it from the USB drive since nothing is ever deleted from it. The only problem is it will eventually fill up your USB drive and you will need to clear out older files.

Name your folder pair. Give it a decent name like “My Documents Backup” and hit Finish.

Huge Success!

All finished! No you can hit the Run button to run your first backup.

To automate the backups we need to schedule them using the Task Scheduler.

Schedule SyncToy Sync Task in Windows Vista and Windows 7

  1. Click on the Start menu, then select All Programs – Accessories – System Tools – Task Scheduler.
  2. Click on Create Basic Task in the “Actions” pane on the right.
  3. In the “Create Basic Task Wizard”, type in a Name and Description. For example: My Documents Backup.
  4. Click on Next button.
  5. Choose the frequency of when do you want the task to start. Daily is a good choice.
  6. Click on Next button.
  7. Set a Start Time leave the start date alone. I would set the start time of 1am.
  8. Click on Next button.
  9. In the “Action” step, select Start a Program as the option for the task to perform.
  10. Click on Next button.
  11. Under “Program/Script”, click on Browse button and locate the SyncToyCmd.exe. It’s located in “C:\Program Files\SyncToy 2.1\SyncToyCmd.exe”
  12. In the “Add Arguments” textbox, type “-R” without the quotation marks.
  13. Click Finish!

Schedule a SyncToy Task in Windows XP

  1. Go to the Start menu, select All Programs – Accessories – System Tools – Scheduled Tasks.
  2. Select Add scheduled task to start the Scheduled Task Wizard. You will see a list of possible programs to run.
  3. Select SyncToy from that list.
  4. The wizard will next prompt you to enter how often you want to run the scheduled SyncToy. Select Daily.
  5. The next page asks when to start the task. Select a start time, I recommend 1am.
  6. The next page asks for the user name and password to run the program under. If you have one, enter your password you use to log onto Windows. Otherwise click Next.
  7. The final page contains an option to open the properties dialog when the wizard ends. Select this checkbox.
  8. In the pop-up box, go to the end of the Run textbox and add ” -R” (notice the first space) without the quotation marks, after the last quotation mark already in the Run field.
  9. Click OK!

All finished!

You now have fully automated backups of your My Documents folder onto a USB disk drive. This exact same tutorial can be modified using you My Pictures folder or My Music folder instead of My Documents if all you want to backup is your pictures or music or any other folder on your computer.

Now no more worries about weather your documents, pictures and music are backed up.

How-to Split, Merge, Rotate and Re-Order PDF Files

Posted in Blog, Tech, Tutorial on June 16th, 2010 by Matt – Be the first to comment

It sounds like a trivial task, breaking up or splitting a pdf document in to multiple pages, but without Adobe Acrobat Pro, it can be quite hard to find a utility that does this well. Luckily I’ve just stumbled upon a great solution. The best part is, its free.

PDF Split and Merge

PDF Split and Merge (aka PDFsam) is a great little open source utility that does just what its name implies. As well as splitting and merging it can rotate pdf pages or merge two pdf documents together.

PDF Split and Merge Interface

While PDFsam is free, and 100% functional, they do have an “enhanced” version that includes the ability to encrypt pdf documents. The cost? $1. Totally worth it.

Using PDF Split and Merge is straight forward. Just select the function you’d like to preform from the left hand side, select the file you want to change and set a few options. If you’re splitting a file, you can choose to split every page into its own pdf document, split just the even or odd pages out or split it after a certain number of pages.

Also included is a nifty visual page reordering. You can view all the pages in your source PDF document then just drag and drop the just the pages you want into whichever order you’d like.

PDF Split and Merge Document Page Reordering

This is a great utility that provides some of the function of the multi-hundred dollar Adobe Suite. And remember this is an Open Source (aka free) project. Give the developers some money if you appreciate their product.

PDF Split and Merge is available here: PDFsam