Today, we at Your Nearest Bar are proud to announce our first software release, called JetScanner. It is a little utility coded in Python (tested only on 2.7) that allows scanning pages from an HP JetDirect device that has an AiO or MFP device attached to it. Currently it is only tested with the HP JetDirect 175x, or J6035B. If you’d like us to add support for other JetDirect devices, please shoot an email to somedude at yournearestbar dot com.
The code is licensed under the GPLv2 and it’s available for download at http://code.google.com/p/jetscanner/. The program has descriptive help built-in with the switch -h or –help. Current plans include changing the PDF postprocessing and adding e-mailing capabilities, so check back in the future for an updated version.
Tags: command line, hp, jetdirect, jetscanner, multifunctional, python, scan, scanning
When using the linux utility dd, there is no visual output of the progress, how long it is going to take, or anything else. Easy to solve with the use of pv:
% pv /dev/sda | dd of=/dev/sdb bs=100M
that’ll display the amount of data transferred, the elapsed time, the throughput speed, a nice progress bar, and the ETA. For devices that do not have a fixed size, let’s say, /dev/zero, there’ll be only a throughput display.
Tags: dd, ETA, linux, progress bar, pv
When printing across different subnets, or configuring a personal firewall, certain ports need to be opened. For RAW and LPD/LPR printing, use the following:
If printing from Microsoft Windows, the operating system will need SNMP access open as well, otherwise the printer detection procedure won’t work. Open the following port:
Make sure that the SNMP access is read-only, or that it has a strong password if read-write is really needed.
Tags: firewall, lpd, lpr, printing, raw, snmp, subnet, tcp 515, tcp 9100, udp 161
Let’s go through a quick and easy way to enable SSHv2 access on a Cisco router. Should be similar on a switch.
- Make sure the IOS has the crypto modules, usually identified by a “k9″ or “k5″ in the IOS file name. Check with show version
- Configure a hostname with the command hostname and a domain name with the command ip domain-name
- Generate a new keypair with crypto key generate rsa and use 2048 bits
- Create a new username for SSH access: username sshuser password 0 mysshpassword. Replace sshuser and mysshpassword accordingly.
- Configure SSH parameters:
- ip ssh timeout 60
- ip ssh authentication-retries 3
- ip ssh rsa keypair-name NAME (replace NAME with the keypair name obtained from show crypto key mypubkey rsa
- Prevent non-SSH sessions with line vty 0 4 and transport input ssh
- Additionally, prevent SSH access from outside a certain subnet:
- access-list 15 permit 192.168.0.0 0.0.0.255
- line vty 0 4
- access-class 15 in
Now SSHv2 should be enabled and accessible. All commands should be entered in global configuration mode, except for the show commands.
Tags: cisco, cisco ios, router, ssh, sshv2
Given certain circumstances, Windows Media Center will get stuck at “Downloading TV Setup Data” and do nothing else. This generally occurs after some sort of hardware change, as it happened to me on a motherboard change and on a hard drive change. YMMV.
For the sake of clarity, this entire post refers to Windows 7, but it could apply to Vista as well, given that the paths are relatively the same.
Anyway, there are a few posts around the Web that tell you to run a command line for mcupdate.exe with some switches. That’s like getting a tire patch, it’ll work for now but won’t last. Here’s the new tire solution:
1) Go to the Control Panel, Programs and Features, and click “Turn Windows Features on/off”. Uninstall Windows Media Center.
3) Empty out the folder C:\ProgramData\Microsoft\eHome\
4) Go to the features and enable Windows Media Center again.
5) Run Windows Media Center and do the TV setup.
This solution is the only one that worked across reboots and allowed me to go and reset the TV signal without hassle. Please leave a comment if something else worked for you.
Tags: Downloading TV Setup Data, stuck, TV, TV setup, TV signal, windows 7, Windows Media Center
Today I’ve decided to give OpenSolaris a spin, and to my surprise, it doesn’t have the SmartArray drivers available by default. Took some considerable amount of research to come up with a procedure to do the install. Here are the steps:
- Download the SmartArray drivers for Solaris on the HP website (at the time of writing, I installed OpenSolaris 2009.06 and used drivers for Solaris 10)
- Uncompress the package with gunzip.
- Inside the newly uncompressed folder, there will be a file called CPQary3.pkg. First run pfexec touch /ADD_DRV_IGNORE_ROOT_BASEDIR then run pfexec pkgadd -d ./CPQary3.pkg in the folder with the uncompressed files. There will be some errors installing the man page, but those should be ignored. The driver will be successfully installed.
- Run the Device Driver Utility. Right click the Smart Array controller, go to Show Details. Make note of the node name of the controller, which was pcie11,409a in my case.
- Run pfexec add_drv -c scsi -i ‘”pcie11,409a”‘ cpqary3 while substituting it for the correct node name in your case. It shouldn’t give any errors. Please note that the node name has a single quote followed by a double quote.
- Run the OpenSolaris Installer, and it should detect your arrays.
Overall it’s an easy process, and it amazes me that the default image does not include this driver. Good luck with the install. Questions are welcome in the comment area.
Tags: compaq, cpqary3, hp, opensolaris, raid, smart array, smartarray
Computer has 4 hard drives, two in RAID-0 and 2 independent disks. RAID-0 contains two partitions, C: and D:. One of the drives started failing, needing replacement, and then a backup was done using Windows System Image Backup, included with Windows 7. Recovery DVD was generated t oboot the computer.
All fine and dandy, the failing HDD was replaced. Another RAID-0 volume was created, and proceeded to boot the recovery DVD. After following the steps and making sure to exclude the independent disks from the restore process, the backup says that there are no valid volumes present. Tried downloading the latest Intel drivers, no go. Tried going with all independent disks, the DVD wouldn’t even boot. After some time playing around and fearing for the data, here’s a few tips to have a successful experience:
- Make sure to label the new RAID-0 volume *exactly* as it was before. The default is Volume0, and it *has* to be the same for the restore to work;
- Disconnect any and all hard drives that you don’t need. In this procedure, there were two independent disks, one had the image backups, the other was for regular data storage. Had to disconnect the second independent disk for the restore to work.
In a nutshell, the procedure works fine, despite the majority of people going to Acronis (I agree it’s a much more reliable solution) for this image backup. Following the 2 simple tips mentionded before, the backup will restore and the drives will be the same as before. As always, make sure to have regular data backups in place!
Tags: backup image, data backup, intel raid, intel storage, system image, windows 7
With Microsoft Exchange 2007, there is a default policy that enforces the use of a 4 digit passcode (PIN) to unlock the phone. Here’s how to make the passcode optional to the user:
- Login to a machine with the Exchange Management Tools installed
- Open the Exchange Management Console
- Expand the Organization Configuration
- Click on Client Access and then choose the password tab
- Remove the check from the box that says Require Password
Afterwards, do a manual sync with the phone, then disable the passcode under Settings / General / Passcode Lock.
Tags: disable, exchange, exchange 2007, iphone, passcode, pin, policy
When migrating users between different computers, most people end up just copying their files on the desktop, my documents folder, etc, and forget the little things like the database that stores the previously emailed addresses in Microsoft Outlook. I’ve seen in a lot of cases, folks that rely almost exclusively on this database to know other people’s email addresses. Here’s how to copy it from one computer to the other:
In Windows Explorer, navigate to
C:\Documents and Settings\%USERNAME%\Application Data\Microsoft\Outlook
if it’s Windows XP, or
if it’s Vista or 7, and copy the file with the .NK2 extension. It’s usually called Outlook.NK2 but it depends on the name of the Outlook profile used. Copy this file to the same location on the new computer.
One gotcha: if the old profile is on a domain computer, the file caches some domain information, and when sending emails internally, there will be errors. To solve this problem, manually delete the internal address entries using the “delete” key and resend an email to cache the new entry.
Tags: .nk2, address, autocomplete, backup, Outlook, profile, recover
I’ve opened a channel on IRC for discussions regarding any of the topics posted on this blog, feel free to come in and ask questions or make comments/suggestions.
I’ll be there most of the time as VanDyke. Come in and chat!
Tags: freenode, irc, your nearest bar