Chris Erwin

Discrete and Discreet

December 10, 2008

InDesign CS3 and the Missing Jostens Toolbar

Filed under: Apple,Computers,Scripting,Technology — Chris Erwin @ 4:32 pm

Are you having problems with the Jostens toolbar not showing up in InDesign CS3?  Were you led here by Google?  Are you not interested in my uninteresting story on how I solved this technological mystery?  Then just issue these commands and move along.

sudo chmod -R a+w "/Applications/Adobe InDesign CS3/Plug-Ins/Jostens"
sudo find /Users -name "InDesign SavedData" -print0 | xargs -0 rm

If you’re here for the story, read on!

At work the yearbook team is using InDesign CS3 on OS X 10.4 to create the yearbooks this year.  We upgraded them to CS3 over the summer and I didn’t anticipate any problems.  Turns out we did have a problem, and it was a big one.

The printing is done by Jostens, who provided a CD with an InDesign plugin and some support files that are used for their specific layout.  I installed the plugin and opened InDesign to make sure the toolbar showed up.  It did, but unfortunately I tested it as a user with more file permission rights than the students.  I know better, but I’m also lazy, so what can I say?

A few days later the teacher reported the toolbar was not showing up when InDesign was opened.  I checked and sure enough the toolbar was not present when running InDesign as one of my student-level accounts.  To me, this pointed to file permissions issues.

I started by giving all users read, write, and execute permissions for /Applications/Adobe InDesign CS3/Plug-Ins/Jostens/.  I logged back in under my student account but the toolbar was still not there.  After trying all sorts of other crazy permission changes everywhere I tried another student-level account of mine.  To my surprise, the toolbar appeared when I ran InDesign.  Hmm.

I pondered this for a while, envisioning myself at the critical plot twist of an episode of House, ACSA.  I didn’t have a team to bounce ideas off of and insult, nor did I have a cane or a three-day beard.  I sure had a mystery on my hands though.  What was the difference between these two accounts?  I logged in and out of each one a few times, running InDesign and pondering the results.  When I logged in as cerwin, the toolbar did not appear.  When I logged in as chrise, it did.  Every time.

housets
 
 

“…can’t be autoimmune…”

I thought about ordering a CT or treating for sarcoidosis, but then I realized I had four more patients (computers) in the room, all presenting the same symptoms.  I wrote off the first patient as dead (for now) and slid down a seat.  Starting over, I logged in as an administrator and made /Applications/Adobe InDesign CS3/Plug-Ins/Jostens 777.  Is it a good idea to give normal users write rights to an important folder?  No, but I was in a hurry and figured I could restore that folder any time a user mucked with it.

Logged in as chrise.  The expectation was that the toolbar would show up fine, which it did.  Logged out and in as cerwin.  The expectation this time was that it wouldn’t show up, for no good reason.  Much to my surprise, it did show up.  Hmm.  It’s not Lupus.  But it is a compound problem, combining the permissions on the plugin folder with something else.

I thought a bit more until I realized the problem.  InDesign is caching its toolbar layout in a file in my profile somewhere.  Since cerwin had logged in on computer 1 before the permissions were fixed, the toolbar failed to launch, and InDesign made its layout cache without including that toolbar.  chrise had logged in after the permissions were fixed and thus InDesign’s layout cache in that profile included the Jostens toolbar.

Simple enough.  A few quick rm -r commands and I was back on computer #1 with a clean slate.  I logged in as cerwin and lo and behold, there was the toolbar.  Ok, that’s simple enough, I can just go around and delete everyone’s profile out of /Users, right?  It’s not that easy, since the users might have saved some larger files locally to avoid taking up space on the server.

I poked around /Users a bit until I found the offending file.  I finally found it: “InDesign SavedData”  Nice extension, Adobe.  No matter, as it was time for some bash fu.

sudo find /Users -name “InDesign SavedData” -print0 | xargs -0 rm

This removed the InDesign SavedData file from everyone’s profile and restored their access to the Jostens toolbar.

September 17, 2008

Windows Vista and Non-Broadcasted SSIDs

Filed under: Computers,Technology,Windows — Chris Erwin @ 12:54 pm

When I told the teacher in charge of one of the laptop carts at the high school that I’d be taking 3 of his laptops and his access point because “the computers are set to connect to the access point, but they just won’t” he asked if I was going to put them in therapy.  I confirmed that I’d be setting them up in a circle for group therapy so we could work through their aversion to connecting the the WAP.  I was more correct in this than I had first thought.

Turns out there’s an extra check box in Vista’s wireless network profiles that says “Connect even if the network is not broadcasting” and sure enough our WAPs don’t broadcast their SSIDs.  Simple enough fix, and if you’ve found this via googling about why your Vista laptop won’t reconnect to your wireless network, you’re done.  I however have 120 laptops that have this setting.  Hmm.

For a simpler fix we now turn our attention to the Proxim AP-4000M, of which I have 9 to deal with.  Simple enough, but they don’t have the SSID broadcast setting in their web interface.  After about 20 minutes of perusing the manual, I found the telnet commands I needed.  I fired up putty and in no time had all 120 laptops working.  “show wif” lists your wireless profiles.  make note of the numbers and type “set wif # closedsys disable” for each number.  “reboot 0″ or power-cycle the access point.

“But Chris!” you say, “Isn’t broadcasting your SSID a bad idea?”  Well, you see we use WEP encryption with MAC filtering, which is about as secure as a 1-digit bike lock to someone who knows what they’re doing, not to mention the whole system is being replaced by a building-wide Cisco setup soon enough.  Not broadcasting your SSID is security through obscurity.  Besides, how else can you show off your clever network name?  Our home network is currently SPACEBALLS: The Router.

June 18, 2007

How I Sold Out to The Man

Filed under: Apple,Electronics,Technology,iPod — Chris Erwin @ 2:17 pm

My Creative Zen Touch had developed a problem with the headphone jack nearly a year ago. The left channel solder joint broke and I couldn’t find a small enough soldering iron to get in there and fix it. Not all is lost, as it has a nice 1.8″ 20GB hard drive which I will surely find useful.

I started researching mp3 players about a month ago to find a suitable replacement. Creative has the Vision M, but I’ve had enough of Creative after my Zen Touch’s headphone issue as well as the huge headache of switching to Vista with my Audigy 4 Pro. Creative hasn’t come up with a suitable driver that works well in Vista with low latency. Vista’s sound system has changed and Creative failed to adapt. EAX no longer works due to the changes to Vista’s sound stack, and Creative actually has the stones to charge for the wrapper they’ve developed to allow for EAX in Vista. Yeah, thanks.

There are some interesting options from companies such as iRiver and Sony, but one brand stood out – The Apple iPod. Now, I disagree with Apple’s reputation as a ‘good’ company whose interests lie in what’s good for the consumer. Just like Microsoft or Intel or any other corporation, their interest is in money and money alone. Steve Jobs has come to the realization that there is money to be had in pretending to have consumer interests in mind. For this reason, I try to avoid Apple products as they are for the most part overpriced for what they are. Sure they’re decent products, better in many respects than some consumer-level products from other companies, but they’re not the epitome of computing perfection carved from pure awesome and running software coded in awesome++ like the Apple fanboys would have you believe. They’re just decent with a less-than-decent price tag.

Anyway, as much as I dislike Apple, they had a pretty solid product. The 5.5g (fifth and a half generation, the September 2006 update to the fifth gen) plays mp3s, which covers my current music library, as well as AAC files. As I imagine many people do, I at first thought one of the A’s in AAC stood for Apple, and thought ‘why would I want to play an Apple proprietary format?’ Turns out AAC stands for ‘Advanced Audio Coding’ and is a standardized lossy compression format set to replace mp3. It just so happens that Apple is one of the few companies using it at the moment, and music from the iTunes Music Store happens to be in AAC format.

One of the reasons I didn’t want to used iTunes was the fact that ITMS purchased music uses Apple’s FairPlay DRM, and as everyone should know, DRM is inherently bad. I don’t support copyright infringement and understand that DRM was partly designed to curb illegal digital media sharing, but in reality it has done nothing to slow it down. Instead, the RIAA and many record labels are using DRM to make money by limiting when and where you can play the music that you have purchased. They are attempting to turn the purchase of music into the purchase of the rights to play a piece of music and limiting what those rights cover. By doing so, they would like to make it so that you have to purchase ‘My Humps’ rights for your mp3 player, your car, your computer, and your stereo, thus earning them 4 times the money for crappy music they don’t deserve any money for in the first place.

In the end however, my discontent with DRM and the RIAA and my strength of character in standing up for my principles took a back seat to my laziness. Am I playing DRM-encrypted music and videos on my iPod? Well, yes, but it’s not keeping me from playing anywhere I want; I only want to play them on my computer and on my iPod. Make no mistake, I will not hesitate to strip the DRM from the files should I want to play them elsewhere. iTunes isn’t keeping me very happy, especially with it’s horrible performance in Vista. For now though the DRM is in tact and the RIAA is happy.

I had already made some purchases off of iTunes. I had purchased a few episodes of The Office that I had missed, and I bought the ‘My Musical’ episode of Scrubs. I now have a working TV tuner card for my computer and don’t miss shows thanks to Vista’s Media Center (more DRM silliness). As soon as I get around to it, I will be converting some of my recorded shows to mpeg4 for use on my iPod. Does this make the media companies cry? Sure does, but I don’t care. I recorded it, so I’m going to watch it where and when I want. I won’t distribute it, because that’s wrong and I understand that. I don’t need Microsoft or Apple to hold my hand on that point.

So here I sit, listening to Carmina Burana on my evil corporate mind control device. Do I feel dirty paying for an Apple product? Well, perhaps I do on occasion, late at night, when I’m contemplating the state of open source software and net neutrality and everything that is free (as in speech) in this world, but normally my laziness is in charge and I don’t give a crap. I can’t take down corporate America and thus The Man by not buying one iPod. Hell, I’m not even a dirty hippie that wants to see corporate America fail. Steve Jobs can have a beer on me because I want just want to listen to some music.

January 10, 2007

De-Toothing a Mac

Filed under: Apple,Computers,Technology — Chris Erwin @ 11:13 pm

Converted from the old blog.

In this article I describe how to disable Bluetooth functionality for all users in OS X.

A java programming teacher at work ran into an issue where his students were using the built-in Bluetooth hardware in their iMacs to share work. He was rightfully concerned that this would occur during tests.

All of the Bluetooth settings in OS X are per user, and Workgroup Manager was of no use. Students use Active Directory domain accounts, so config file tweaking wouldn’t help.

After a little Googling we found this solution. Short of removing the Bluetooth hardware from the computers themselves, this seems to be the most effective method of disabling Bluetooth functionality for all users.

Simply remove the following files from /System/Library/Extensions :
IOBluetoothFamily.kext
IOBluetoothHIDDriver.kext

Remove the following files from /System/Library :
Extensions.kextcache
Extensions.mkext

If you removed them using the command line, reboot the machine. If you drug them to the trash, select “Secure Empty Trash” from the Finder menu and reboot the system.

To restore functionality, the files could probably be restored, but it’s just easier to re-image or rebuild the system altogether.

June 30, 2006

Wide-Spread File Deployment With VBScript

Filed under: Computers,Programming,Scripting,Technology,Uncategorized,Windows — Chris Erwin @ 4:27 pm

Quite often at work we need to deploy one or more files to large numbers of computers. The long way to do it is to manually copy to each computer through the network one at a time. When an entire school needs to be done, it gets very tedious. Another option is to set up a drag-and-drop event in Altiris Deployment Console, our deployment solution, which can then be deployed to an entire school in one shot. However, it can be annoying to set up a new event for every file that needs to be moved, and there are certain files it just doesn’t like to move (.url files for example).

Either my ‘hacker’ side who wishes to come up with creative solutions to problems, or my lazy side, led me to throw together a quick and dirty vbscript to take care of this. It had to be simple yet flexible enough that no code needs to be edited to change what files are being copied. The most challenging part was that I didn’t know anything about vbscript.

The reason I picked vbscript is because it can be executed on any Windows XP machine, so the work can be done from anywhere on the student VLAN. No compiling needed, and it’s more powerful than a batch file.

The script asks for four pieces of input. The file or files being copied, the directory on the remote computers to put the file in (same place on every machine), an input file containing a list of computers, and a log file to write to, so that we can manually hit any computer it missed.

Taking the input and copying the file are both very basic operations which anybody can learn to do with vbscript after a little googling. At the heart of the script is the LineParser function, which takes input from the computer name list and passes computer names to the CopyFile function. At first the computer name list file was just a list of full computer names, one per line, which were passed directly to the CopyFile function from the file system object. However, our computers are named schoolnumber-roomnumber-computernumber (##-[###|####]-##), so some loops should easily work. I then added the LineParser function to allow the input file to have one of three things on each line: a full computer name, a school number, or a room number and the number of computers in that room. Each line will either be ##-###-## or ## or ### ##. LineParser determines which of these three patterns is present on a line and acts accordingly.

If the line contains a school number (only two characters on the whole line):
If Len(LineReader)=2 then
SchoolNumber=LineReader
then the SchoolNumber variable is changed to that new school number. Any subsequent lines containing a room and number of computers will use that school number to construct computer names, until another school number line is encountered.

If the third character is a ‘-’ then the line must be a computer name. It is passed directly to the CopyFile function:
ElseIf Mid(LineReader,3,1)="-" then
FNameS = "\\" & LineReader & "\c$\" & MoveToPath
CopyFile(FNameS)

You can see the UNC path being built up from the rest of the user input.

If these two criteria are not met, then the parser assumes the line contains a room number and number of computers. If not, then the user constructing the input file screwed up, and I didn’t put any error protection in there for that so oh well. A loop then begins, passing computer names to the CopyFile function that are constructed using the room number and the last school number specified:

Else
     Room = Split(LineReader," ")     RoomNumber = Room(0)
     NumComps = Room(1)
     for i = 1 to NumComps
          if i < 10 Then
               iFixed = "0" & i
          Else
               iFixed = i
          End If
          CompName = SchoolNumber & "-" & RoomNumber & "-" & iFixed
          FNameS = "\" & CompName & "c$\" & MoveToPath
          CopyFile(FNameS)
     Next
End If

The vbscript function Split splits an input line at the delimiter given (space in this case) and tosses them into an array (so you end up with an array of words). The loop then builds computer names and passes them on. Fun stuff.

All of this results in allowing a flexible pseudo-language to be used to specify computers. an input file may look like this:
82
126 32
128 32
LIB 20
25-101-01
35-105-03
133 25
80
LIB 20
These 8 lines would result in the file(s) being copied to 131 computers. Note that the school number 82 persists past the two explicitly listed computers, until the school number 80 is specified.

The entire script can be found here. I plan to rearrange the if statement so that full computer names are the Else, so that any computer name can be used, not just those that follow the ##-… pattern. There are some other functions I’d like to add, but right now it does everything we need.

I learned two things in the two hours I spent doing it. I learned vbscript, and I learned that I don’t like vbscript. It is very inconsistent. It is certainly more powerful than batch programming, but doesn’t match perl, python, or any of the like for scripting. Oh well, it was fun.

Powered by WordPress