The Blog of Justin Loutsch

I don't know the question, but the answer is 42!

About

I'm Justin, and I live in Boston. I'm a huge geek into process automation and work reduction, and am also an editor at Eat Your Serial. Thanks for dropping by!

MFP M177fw Scanner Error 22

March 31st, 2014

I recently bought a shared printer for work and this error appeared, after much googling, I found forum posts from HP with a bunch of people requesting that some mod also send them the solution in a PM.

I made an account and requested that the mod post the solution publicly, but this is apparently against HP policy.

They claim this is due to this method being a last resort which can brick the device, so I take no responsibility for anything that happens to your printer.

Without further ado, here is the solution to HP MFP scanner error 22:

Make sure the printer is connected directly to a wall outlet.

Laserjet 177fw Reset.

This will reset the printer back to factory settings. You would have to configure the network over again.

Turn the printer off. On right side of the display.

Hold your thumb in the bottom right corner inside the screen.

Power on the printer.

Wait till permanent storage appears and remove your thumb off the display.

If you are still having issues, I would call HP Tech Support and inquire about a replacement printer.

Contact HP Worldwide.

Salsa dancing!

November 19th, 2013

I’ve been taking salsa lessons since June in an effort to get myself out of the house and meet some new people. It all started with a deal from amazon local, along with cheap swing dancing tickets from the Boston phoenix. I went swing dancing once in an old factory showroom with no air conditioning on a 95 degree Friday evening and decided I never wanted to go to that building again. Maybe in the winter?

Salsa was a whole new story. It was hot there at first also but they got air conditioning pretty quickly. I enjoy the instructors a lot, they’re very helpful and fun. There’s definitely a difference between them. The instructors are Lili, Roberto, and Stefanie. When I dance with Lili she tells me to relax and have fun, and Stefanie just yells the count at me to make sure I don’t miss a beat. My training as a trombone player in band class has finally paid off and helps me keep the beat, and also get back on track when I miss one.

Over the summer I’ve progressed from beginner to advanced beginner, and am now in training group level 1. Every Monday after class there’s a social dance where we get to dance with people from all levels as well as those from the community who want to come dance for free (as far as I know, the only place where you can dance salsa for free). That’s a great opportunity for us to practice the combinations we just learned as well as others, and to get to know each other more as well.

I was going dancing every Friday night over the summer as well, even took my mom when she came to visit. I didn’t know as much then and it was harder to help her learn then but I’ve promised her more lessons over Christmas. I had to cut down on the number of times I was dancing due to developing a bit of tendonitis, and I also bought some new balance shoes with thicker soles that my feet can bend as much, which I’m happy to say have helped a lot. I have another class Wednesday night and am going dancing again on Friday.

Thursday night, I have my 2nd bachata class!

And now, I’ll leave you with a video of me and my partner dancing. This was taken a couple months ago now, so just imagine I’m even better now :)

Just make sure to turn the volume down low on your device, this video was recorded near the speakers and it’ll be very loud.

Here’s another informative post being added for posterity in the hopes it will help others. I was able to find precious little on the internet about setting up these devices.

My company has recently opened a new headquarters, complete with a lab of several different functions. My job as network administrator was to make sure the technology moved smoothly without incident from old location to new, and then once that was done to make sure the scientists were well supported with their scientific equipment.

Our new chemist facilitated the sale of his machines from his former company and brought them with him, but was not the one to set them up for functionality. I’ve never worked in lab setting and these machines were brand new to me. The machines themselves are somewhat old, and the software even older (our current copy being written in 1996 I believe). We could get a new and updated copy of the software, but it would easily cost $6000-$7000.

He suggested to me we would need older machines to run the software, but I was confident that compatibility mode would handle the software fine. What I didn’t count on was the machine have RS-232 serial cables. Turns out I was wrong on that count, and installing the software on Windows 8 prevented the system from booting properly, loading only a taskbar with an invisible clock and a lenovo button. Safe mode worked fine but even uninstalling the software didn’t fix this issue. I ended up using lenovo’s one click restore solution to reset the laptops to factory defaults.

Next up: VirtualBox with windows XP. Software installed successfully, and I’d received a few different USB to RS232 serial cable adapters but still it didn’t work. After taking a closer look at the back panels of these machines, I realized there are ethernet ports on the controllers which means they can be made available on the network. Called up the manufacturer and was connected with a technical support chemist who walked me through accessing the IP address settings. Turns out the easiest way to ensure the IP addresses are correct is to reset the device to defaults using the depressed black buttons on the back of both controllers (near the ethernet ports). The default IP addresses of the controllers are 192.168.200.98 and 192.168.200.99. This can be checked by cycling through the menus of the “func” button until the IP address appears.

Next up: plug the ethernet cables from both controllers into a network hub, and plug the laptop into the ethernet hub. If using Virtualbox, pass the ethernet port through to the Guest OS. You may need a second NIC or a wireless adapter to get internet access, but I don’t see any harm in plugging another cable into the hub and the wall to get a network connection that way.

My experience with the software will vary greatly from any other due to the age of the software but in the configuration menu you would then add in the IP addresses of both machines and run a short test to ensure that the machines can talk to one another.

I owe a huge debt of thanks to technical support chemist at Shimadzu for not only providing the solution to this setup, but also for being proactive and calling back several times to make sure he got a hold of me.

This is a general informational post meant for those dealing with similar problems.

I really ran into 2 problems with this setup, so let’s start with the networking first. The scanner worked fine over the wireless network, but I had to reset the router since it was set to work as an AP, and we needed the router capabilities to add a guest network.

Setting this router (ASUS RT-N66U) to router mode enabled 2 separate subnets, one for WAN and one for LAN, which gave the printer the IP address 192.168.2.x instead 192.168.1.x and prevented the scanner setup utility from finding the scanner on the network. I wired the scanner into a hub and then set up a hub to plug the router into so the computer next to it would get a 192.168.1.x IP address while the router can continue on 192.168.2.x.

Then I ran the scanner setup utility and it added the scanner no problem, but when I opened the MP Navigator scanner application included by Canon, scanning always failed and returned error code 5,145,61. I reinstalled, changed the active scanner in the network scanner utility, all to no avail. I went back to the printer and printed out it’s LAN Configuration information and sat back at the computer.

Finally, I opened the MP Navigator application again and entered the scan photos dialogue, then clicked on the preferences button at the top right of the window. In the product name dropdown you’ll see MX870 series (Network:xxxxxxxxxxxx) where the Xx represents the MAC address of the connection type (LAN will have one MAC address, and wireless will have another). In this case, it turns out that even though I had selected the correct address in the scanner setup utility, the application preferences were still trying to use the wireless MAC address of the scanner. Since it was connected to the wired network, this obviously caused it to fail.

The solution is to click into the dropdown and find the mac address that matches the LAN settings printed out (it should be the only other available option.

This was done in CentOS 6.4 but PolicyKit is part of gnome so it should work across different distriubtions.

I’ve run into this problem before, but it finally today became something I needed to solve after I moved the server to a new office with no monitor or inputs.

I would VNC in but the external drives could not be mounted due to gnome policykit controls (for security’s sake).

So, here’s how to enable disk mounting in a VNC session in policykit.

CD into /etc/polkit-1/localauthority and you’ll find a bunch of files:

net.reactivated.fprint.device.policy org.fedoraproject.config.firewall.policy
org.fedoraproject.config.services.policy
org.fedoraproject.systemconfig.kdump.policy
org.freedesktop.NetworkManager.policy
org.freedesktop.RealtimeKit1.policy
org.freedesktop.consolekit.policy
org.freedesktop.devicekit.power.policy
org.freedesktop.devicekit.power.qos.policy
org.freedesktop.modem-manager.policy
org.freedesktop.network-manager-settings.system.policy
org.freedesktop.packagekit.policy
org.freedesktop.policykit.policy
org.freedesktop.udisks.policy
org.gnome.clockapplet.mechanism.policy
org.gnome.control-center.defaultbackground.policy
org.gnome.cpufreqselector.policy
org.gnome.gconf.defaults.policy
org.gnome.settings-daemon.plugins.wacom.policy
org.gnome.system-monitor.policy
org.opensuse.cupspkhelper.mechanism.policy

The one we’ll want to edit is org.freedesktop.udisks.policy.

First, backup this file:

sudo cp /usr/share/polkit-1/actions/org.freedesktop.udisks.policy /usr/share/polkit-1/actions/org.freedesktop.udisks.policy.bak (or any other location you prefer).

In the terminal, run the following command: vi /usr/share/polkit-1/actions/org.freedesktop.udisks.policy

Look for this section:

<action id=”org.freedesktop.udisks.filesystem-mount”>
<description>Mount a device</description>
<description xml:lang=”da”>Montér en enhed</description>
<message>Authentication is required to mount the device</message>
<message xml:lang=”da”>Autorisering er påkrævet for at montere et fil system</message>
<defaults>
<allow_any>yes</allow_any>
      <allow_inactive>yes</allow_inactive>
      <allow_active>yes</allow_active>
</defaults>
</action>

Change the fields in red so that all say “yes” instead of no.

Save the file (in vi, this is down by hitting the escape key, then typing a colon, W, Q!, and will look like this: :wq!). Restart the VNC session. You should now be able to mount your external drives in a VNC session.

Recently a hard drive failed in our RAID 5 QNAP NAS array. The CTO suggested a low level format would make the drive usable again, and he was right. In my case it was a Seagate drive, so I used Seatools and it’s full erase feature. I found that Seatools wouldn’t run via USB, nor would it run on a spare box I had laying around, so it was easiest to burn Seatools to a CD and just plug the drive into my desktop. This took about 14 hours total so I let it run overnight.

Once I plugged the drive back into the QNAP, I expected that the RAID array would begin rebuilding. This was not the case, however, and is apparently a shortcoming of the QNAP system. Their software RAID can’t recover from dead disks apparently, but only ones incorrectly flagged as faulty.

I did a lot of googling to figure out how to fix this, and with a lot of help from this site figured out step 1.

The first step is clone the partition structure of the drives over to the newly formatted drive. To do this, first ssh into the QNAP server as the administrator.

Run fdisk -l (that’s a lowercase L) to get a listing of all disks in the system. My QNAP server has 4 drives, each labeled with a number over the drive bay. These numbers correspond to sda, sdb, sdc, and sdd. In my case, sdc failed, and after replacing it was still recognized as sdc.

Find one that’s complete, as this is what you’ll want to copy over to the new drive. The new drive will be the missing label in the fdisk output (sdc was missing in my case).

Next command: fdisk /dev/drive label (for me: fdisk/dev/sdc)

Type n and tap enter for a new partition. For partition type, enter p for primary. Enter 1 for the partition number, and 66 for the last cylinder size. Stick with the default value for first cylinder, but enter different values for the last cylinder of each partition.
Type n and tap enter for a new partition. For partition type, enter p for primary. Enter 2 for the partition number, and 132 for the last cylinder size.
Type n and tap enter for a new partition. For partition type, enter p for primary. Enter 3 for the partition number, and 243138 for the last cylinder size.
Type n and tap enter for a new partition. For partition type, enter p for primary. Enter 4 for the partition number, and 243200 for the last cylinder size.

Next mark the first partition of your drive as bootable:

Command (m for help): a Partition number (1-4): 1
Then change partition 2 to ‘Linux Swap / Solaris’ format Command (m for help): t Partition number (1-4): 2 Hex code (type L to list codes): 82 Changed system type of partition 2 to 82 (Linux swap / Solaris)

Finally, save the new partition table Command (m for help): w The partition table has been altered!

Ctrl-C to exit fdisk

Eject the new disk and reinsert

The site I linked to then says that all you have to do after this is eject the disk and reinsert it, and the rebuilding will begin. However this is not what happened for me.

The disk structure was cloned just fine, but the array was still running in degraded mode even after I restarted the NAS.

I had to begin the rebuild process manually, and actually ended up calling QNAP to find out exactly how to do this. They wanted to remote into my machine using teamviewer, but I declined and ask them to walk me through the commands (since I’m comfortable with the terminal, this was fine, but YMMV).

This command must also be run while SSH’ed into the QNAP server: mdadm -a /dev/md0 /dev/sdc3

sdc3 is the largest partition in the QNAP layout and the one that is part of the array, while the other smaller ones are for the OS this one contains the data stored in the array.

The rebuild process could take a few hours (I allowed mine to run overnight). To follow the progress of the rebuild, use this command: cat /proc/mdstat (note: this will not work directly from the command prompt upon SSHing into the QNAP. I had to run “cd ..” to go back to the root directory before it would work.

Once the rebuild is complete, reboot the NAS. Once it’s online again and you can log into the web GUI, you’ll see in the RAID management page that the status has gone from “degraded mode” to “ready” and you will see all 4 drives listed instead of just the 3 healthy ones.

My year in review

December 23rd, 2012

I’ve been quite busy since my last blog post.  I’m currently writing this home from home, where I’ll be until some time next week for the Christmas holiday, but I figured now was a good time to fill in my readers on what I’ve been up to.

I was unemployed for 3 months, from March to May. This was a tough time for me, surviving off of severance and unemployment benefits, but I made out just fine. I went to the gym every day, and applied for jobs all week long. An ex came to visit when I started my new job, which didn’t really go so well mostly on my part due to the stress of having to find a place to live in 2 months, saving the $1000+ deposit and first/last month rent needed to move in, and paying the bills.  Not much happened during this 3 month chunk, which has made my year feel very compressed.  March was a great month to be unemployed in Boston though, 2 weeks of 70-80 degree weather, enjoying it on my friend’s deck.
I got creative towards the end of my unemployment and decided to crash some job fairs at local universities. Luckily Boston has a little over a dozen of these. I went to a career fair at Boston University, just slipping in past the sign-up table wearing my suit and began talking to recruiters. Ran into one former recruiter from my old company so we chatted for a bit and exchanged info, and then I moved on and found another recruiter who told me his cousin was looking for an IT person.  I gave him my resume, got his card, and emailed him a copy of my resume a day later.  Soon, I had an interview with a small biomed firm in downtown Boston.  That interview was the Thursday before mother’s day, I had 2 interviews in all and then started on June 18th.
I’m proud to say I’ve been employed full time since September (I started on a 3 month contract in June) and started with an excellent raise as a network administrator. My familiarity with linux was a great advantage to getting this role, as we use CentOS all the time, but my willingness to play around with new software and find better/faster ways to complete a task played a role as well.  I do a large chunk of software testing and IT support, and it’s safe to say that I’ve roled all of my skills into this one position. I even work with a German, and get to speak German with her every day. I will be starting a second job in January doing IT support at a local German school’s evening programs, where her father works. This will give me the chance to attend cultural functions I normally wouldn’t attend on my own, and expand my skillset while meeting authors, filmmakers, and other guests of the Institute.
As to finding a place to live, I moved from East Somerville, MA to Revere, MA. East Somerville was not very convenient and made me heavily reliant upon the bus system which got old very quickly if you had to go anywhere when it wasn’t rush hour.  Revere has a few downsides (Beachmont specifically is very sleepy) but I live just a 10 minute walk from the train station, which takes 20 minutes to get me to work. I live in a 2 story house on the top of the hill and I can see the ocean from my window. Many of my friends remark that I live far away, but in reality it’s only far when you factor in where they live. From the downtown area it’s often much closer than the other transit lines, plus I always get a seat because I live so close to the end. Bonus points for the house because it has a bar and a woodstove. I live with 2 other people, one of whom is the landlord, and he takes care of everything. Both guys have cars and I can occasionally borrow one if needed but with Target and the grocery store a mile away I generally try to walk there when able. The best part about this place is the rent is only $600/month rather than the $975 I paid for a studio, and while I sometimes do miss the privacy a studio affords, I’m really enjoying saving the extra money I used to be paying on rent. It feels great to have a safety net savings account for the first time in my life.
Other notable events of the year include meeting Kat and Mouse, if for just a few short hours. Kat came to town to check out hotel accomodations for a conference she was organizing, and Mouse came down from Maine so the 3 of us got dinner on the hotel and shot the shit for a while.  I put together a server for the first time ever which was a lot of fun, and learned a lot about RAID and VLM, and took this one step further to set up a RAID array with LVM in a remote server using only a text file and some googled walkthroughs tailored to my needs (post forthcoming). I’ve also been learning a lot about software testing and automating, using tools such as sikuli, selenium, and TestLink, and hope to do some writeups on those in the future. Oh, and I turned 27.
For now, I’m enjoying being home, spending time with the family and all the animals, and occasionally shoveling some snow. Off to bed with me now.

Most ebooks these days have some of DRM scheme in use to protect the rights of copyright holders. EPUB files from Sony and Google use Adept while Barnes and Noble has yet another scheme, and Amazon has several schemes depending on the file format.

These schemes effectively lock the buyer into buying from only one company, but there are several drawbacks to this: Amazon has removed books from devices remotely (1984 incident), but the bigger problem is if one of these companies goes out of business you will lose all of those ebooks that you paid for. Another important item to consider is availability of titles. Perhaps Barnes & Noble has the newest book in a series you love, while Amazon doesn’t, but you have a kindle. I guess you’ll just have to wait.

This is where we have some good news: all the major ebook DRM schemes have been broken (with the possible exception of iBooks, not 100% sure on that). Not only have they been broken, but over the last 2 years the process has become extremely simple. It began as several sets of python scripts, one that acquired the encryption key (to verify you own the file) and then the second to use that key to remove encryption. They had to be run in a terminal and were somewhat complicated if you’ve never done it before. Fast forward to now and there is a wonder ebook library program called Calibre which has plugins available for DRM removal which make it a simple case of adding in your kindle serial number or B&N credit card number (used as the encryption key with your account) and then once the device is plugged in and connected to Calibre all you need to do is right click the file on the device and choose add to library and not only is it added instantly but the DRM is removed at the same time, leaving you free to convert the file to any format needed and own it as long as you wish.

So, on to Pottermore. They went a different route, and instead of choosing DRM they applied a digital watermark to these files to identify anyone who might have shared them after purchase. The files are completely unencrypted but still identifiable. I for one was excited to check out how this watermark was implemented, and bought the first Harry Potter book for $7.99 the minute I got the invitation from Amazon. Upon purchasing one book, you are given multiple downloads (I think 7) which allows you to download the books in multiple formats.

I downloaded the epub and mobi formats of the books and unpacked them to look at the file contents. EPUB files are just zip files and can be renamed to .zip and opened with any archiving utility. Then it’s just a matter of looking through the various files searching for a watermark tag and removing it, as well as the HTML file with the text of the book itself.

For MOBI it’s slightly more complicated as the mobiunpack script is required to unpack the contents of the file, but the same process applies. Just edit the HTML to remove the identifying watermark line and save it, then use Amazon’s kindlegen to create a new mobi file from the edited files. Add it to Calibre and you’ve got a brand new unsecured, unidentifiable ebook.

This was done for educational purposes and I haven’t uploaded the ebook anywhere (they existed in eformat ever since publication anyway thanks to HP fans) but altogether I expected something a lot more complicated when hearing about a watermark but I think this was just the easiest way to explain the identifying line with an analog that we all understand today.

I’ve lived in East Somerville for 8 months now, and have noticed a few things about it that differentiate it from Somerville proper. First, there’s the pejorative nickname “Slumerville” use to denote what looks like a poorer area of the city. This area of Somerville is also underserved by the subway (as compared to Davis Square) and relies chiefly on buses and cars for transit needs.

In my neighborhood alone I can take the 89 or 101 to Sullivan Square subway station or the 80 close to Davis station or right to Lechmere, within a 5 minute walk. 15-20 minute walk would bring me to the 88 bus line which also runs to Davis but up and down Highland. This is convenient to that entire neighborhood as well as anyone going to the Somerville public library.

I have many friends who either have lived in this area, or live close by and consider it “far” from Davis, the most hopping/trendy part of Somerville (with Union Square a close second, in my opinion).  In actuality it’s a 20 minute walk, or 5-10 minute busride if you can stomach the long waits during off-peak hours. So essentially, this area is most convenient to live in during rush hour when the buses stop every 10-15 minutes rather than once every hour and a half or so. For all other times, various bus tracking apps allow you to see how many minutes til the next bus will arrive, which makes that waiting slightly more variable.

I believe another reason this area is referred to as “Slumerville” is because, the further down Winter Hill you go, in the direction of Sullivan Station (southeast) the poorer the area begins to look. I think this is largely attributed to the various immigrant groups that live in this part of East Somerville, an observation based on a few things. First, every morning at the local park there is what appears to be a large number of immigrants standing around waiting to be picked up for work (I’ve even seen painting vans picking them up on my way to work once in a while).

Another good indication of this demographic is the amount of ethnic restaurants and shops in the area. Mexican, Brazilian, Creole, Italian, Ethiopian, and more. I for one think that the inhabitants of this area benefit from having such a wide selection of food choices in a very small area.  Another benefit is that immigrants make better neighbors, leaving the areas they live safer in a bid to succeed and live safely. What does Davis have? Joshua Tree and upscale bars, JP Licks, McDonalds, barber shops and cafes, a homestyle restaurant with a bit of everything, and a burger joint. Oh and some Indian restaurants, Japanese restaurants, and a BBQ place.  All definitely a bit more upscale than you can find in East Somerville, even if not far away.

I think what this mainly comes down to is gentrification. The areas close to subway stops are obviously coveted and therefore more valuable, causing rents to go up. When I looked at my apartment the realtor told me it was much cheaper because it’s not convenient to a subway station. What did he mean by cheaper? Oh, $975. The people who live closer to the subway pay a premium for the privilege, while those live further away pay less for the same or better accommodations, but make up for it by having to take the bus before getting on a train.

I hear rumors of gentrification coming east Somerville fairly often, starting with nice French restaurant a few blocks away from Sullivan Station, and I worry that at some point this will push out the local businesses already there and provide the residents with less choice but I think that time is slow to come. Perhaps as the green line construction progresses more businesses will choose to move further into Somerville, but some have already tried this banking on construction starting only to be burned when the MBTA delayed the project due to funding.

So what does that live us with in East Somerville vs the rest of Somerville?

East Somerville has a Super Stop and Shop grocery store and Sullivan Station T stop, Rite Aid/Walgreens/CVS, bars, liquor stores, Dunkin Donuts, myriad restaurants and 2 convenient libraries.  Davis has hipsters and more well-to-do folks, and Union Square has homeowners who complain about a public housing building project that will supposedly block their marvelous view of Boston even though it’s blocked by a tree 6 months out of the year anyway despite the fact that it will house firefighters, police, and other low income earners.

Hi Chris

December 21st, 2011

Feel free to comment! Miss you buddy.