Kilala.nl - Personal website of Thomas Sluyter

Unimportant background
Login
  RSS feed

About me

Blog archives

2017

2016

2015

2014

2013

2012

2011

2010

2009

2008

2007

2006

2005

2004

> Weblog

> Sysadmin articles

> Maths teaching

<< 10 / 2007 12 / 2007 >>

Installing additional locales on Tru64

2007-11-28 10:48:00

Wow, that was a fight :/

A few days ago we had a "new" TruCluster installed, running Tru64 5.1b. All of the stuff on it was plain vanilla, which meant that we were bound to run into some trouble. Case in point: the EMC/Legato Networker installation.

Upon installation setld complained as follows:

==========

Your choice:

1 LGTOCLNT999 EMC NetWorker Client

cannot be installed as required subset IOSWWEURLOC??? is not available.

==========

As the name suggests (EURLOC) the missing files involve the additional European locales that are not part of the default installation.

After fighting and searching and swearing a lot I got things sorted out as follows:

1. Get the Tru64 CD-ROM that was used for the installation. You'll need the "Associated Products 1" CD.

2. Insert the CD into your system.

3. Mount the CD: mount -r /dev/disk/cdrom1c /mnt

4. cd /mnt/Worldwide_Language_Support/kit

5. setld -l `pwd` IOSWWEURLOC540

This will install the locale I needed. Of course you are free to substitute the names of other locales as well.

EDIT:

Also, feel free to read through the proper instructions.


kilala.nl tags: , , ,

View or add comments (curr. 1)

A different kind of hacking

2007-11-25 22:40:00

You know? This whole college deal, burning the midnight oil over homework, feels like hacking to me. It gives me the same feeling I had during my internships or during late-night projects at the office. A feeling that I'm completely into what I do and that I want to keep on going.

Case in point: tonight I'm working on a report for Analysis 1 - Didactics, scratching away at my whiteboard. And of course I turn to the music I always play at times like these.

If you're curious, the song's Funky doll from the original Bubblegum Crisis soundtrack.

It's awfully eighties, but there's something I just love about that song. Of course, I'm also glad there was no video camera there to register my gay-ass dancing at the board. There's just something weird about a geek dancing, while working ^_^;


kilala.nl tags: , ,

View or add comments (curr. 0)

Yay, for more results

2007-11-19 23:29:00

Yay for more test results :)

Remember that one report that had me worried so much? Well, it came back a 70% so it wasn't all bad :)

Also, that one test I was waiting for (on General didactics) came back a whopping 80%! Awesome!


kilala.nl tags: ,

View or add comments (curr. 2)

path_helper: sometimes Apple does kludgy, stupid things

2007-11-18 15:24:00

I've always been quite happy about most of the stuff Apple does. A lot of their solutions to problems are elegant and pretty. However, there are also some cases in which they do awful stuff under the hood. Stuff that makes me cringe in disgust.

Case in point, the new path_helper command.

I've been an avid user of LaTexIT, a LaTex helper programme, for a few months now. It's great how easy it makes the creation of mathematical equations in LaTex.

Unfortunately LaTexIT doesn't yet work flawlessly on Leopard. One of the things that goes wrong is the fact that it just won't start :D After trying to start the app a few times, I noticed a run-away process called path_helper.

I asked Pierre whether path_helper might be tied to the problems he's having, because we don't often get run-away processes. Pierre confirmed that others have hinted at path_helper as well, but that he isn't quite sure yet. Unfortunately he doesn't have a Leopard license yet, so he can't debug the problems yet (hint: make a donation if you use LaTexIt! Pierre could use a Leopard license!).

To help him out, I dug around a little bit. What follows is what I e-mailed Pierre. If you don't want to read through the whole bit, here's the summary:

Apple wants to make it easy to expand the $PATH variable for every user on the system automatically. Instead of tagging on new PATH= lines onto the end of /etc/profile, they've created the path_helper command that gets called by /etc/profile. Path_helper reads directory paths from the text files in /etc/paths.d and appends these paths to $PATH.

So because the want to make it just a -little- easier to add to $PATH, they've:

* Created a new directory structure under /etc/paths.d

* Allow new apps or environments to add text files to /etc/paths.d

* Created a new command which simply reads text files and barfs out shell commands.

* Thus broken the Unix standard way of globally setting $PATH.

Good going Apple! You bunch of schmucks!

======================================================

Hmm, this seems to be a weird little, extra tool that Apple has tagged onto the OS. I'm not sure if it's the most elegant solution to the problem. I see what they want to do though: they want to be able to easily make adjustments to the $PATH variable for all users on the system.

Personally I'd just use the global profile in /etc, but apparently Apple have chosen a roundabout way.

Each user's .profile calls that path_helper process. The only thing that path_helper does is generate the requisite sh/csh commands to adjust the $PATH variable.

From the manpage:

=====================

ath_helper(8) BSD System Manager's Manual path_helper(8)

NAME

path_helper -- helper for constructing PATH environment variable

SYNOPSIS

path_helper [-c | -s]

DESCRIPTION

The path_helper utility reads the contents of the files in the directories

/etc/paths.d and /etc/manpaths.d and appends their contents to the PATH and

MANPATH environment variables respectively.

Files in these directories should contain one path element per line.

Prior to reading these directories, default PATH and MANPATH values are

obtained from the files /etc/paths and /etc/manpaths respectively.

Options:

-c Generate C-shell commands on stdout. This is the default if SHELL

ends with "csh".

-s Generate Bourne shell commands on stdout. This is the default if

SHELL does not end with "csh".

NOTE

The path_helper utility should not be invoked directly. It is intended only

for use by the shell profile.

Mac OS X

END

=====================

So instead of putting PATH=$PATH:/usr/whatever/bin in /etc/profile, Apple have decided to make a new config file: /etc/paths.d. This config file will list all directories that need to be appended to the default $PATH.

/me looks at /etc/paths.d

Actually... It's a directory, containing text files with directory paths. For example:

=====================

Kilala:~ thomas$ cd /etc

Kilala:etc thomas$ cd paths.d

Kilala:paths.d thomas$ ls

X11

Kilala:paths.d thomas$ ls -al

total 8

drwxr-xr-x 3 root wheel 102 24 sep 05:53 .

drwxr-xr-x 91 root wheel 3094 13 nov 21:11 ..

-rw-r--r-- 1 root wheel 13 24 sep 05:53 X11

Kilala:paths.d thomas$ file X11

X11: ASCII text

Kilala:paths.d thomas$ cat X11

/usr/X11/bin

=====================

I guess Apple's reasoning is that it's easier to add extra text files to /etc/paths.d, than it is to add a new PATH= line to /etc/profile. Personally, I think it an in-elegant (and rather wasteful) way of doing things :/

Wait, it's even worse! The path_helper gets called from /etc/profile! Ugh! :(

=====================

Kilala:~ thomas$ cd /etc

Kilala:etc thomas$ cat profile

# System-wide .profile for sh(1)

if [ -x /usr/libexec/path_helper ]; then

eval `/usr/libexec/path_helper -s`

fi

if [ "${BASH-no}" != "no" ]; then

[ -r /etc/bashrc ] && . /etc/bashrc

fi

=====================

Let's see what happens when I run the command...

=====================

Kilala:etc thomas$ /usr/libexec/path_helper -s

PATH="/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin"; export PATH

MANPATH="/usr/share/man:/usr/local/share/man:/usr/X11/man"; export MANPATH

=====================

What a totally stupid and annoying way of doing this. What's worse, I'm quite sure it also breaks the Unix-compliancy of Leopard when it comes to standards for setting $PATH.

Hmm :/


kilala.nl tags: , , ,

View or add comments (curr. 12)

Ouch, Analysis-1 is going to be a toughy

2007-11-17 11:55:00

Careful now, this may sting a little... o_O

This semester we're covering Analysis 1, which requires a wholly new way of thinking. Where Statistics 1 was pure maths and calculation, this course requires something additional: insight and a sense of logic.

The thing about this course is that it's all about proving maths. Not using maths to prove stuff, but proving the mathematic equations themselves.

Folks who aren't too hot on math may want to skip the next section :D

==========

For example, the calculation show is above belongs to the question "Prove or disprove that (k^2 -1) is divisible by eight, for all values of K that are integers and odd". "Odd" in this case is opposed to "even".

So, how do you even get started on such a question?! Well, you start filing in bits and pieces, starting out by equating k to (2n + 1). Why? Because one can make -any- odd number by taking integer n, multiplying it by 2 (thus becoming an even number) and then adding 1.

Once all of that is done we're left with 4(n^2 + n). In order for the original theory to be right, this'd mean that any value of (n^2 + n) needs to be even. And that's what I'm testing in the second and third lines: first for even numbers, then for odd numbers. And indeed, both tests come out positive: any value for n will result in an even number.

Pulling this back to the original theory means that any outcome is indeed divisible by eight, because four times any even number is always divisible by eight.

==========

Joy!... I've always sucked at being insightful, so a lot of these "tricks" don't come natural to me. Then again, I used to get good grades for math and even for stuff like this. I ought to be able to get the hang of it again.

I hope ^_^;;


kilala.nl tags: , , ,

View or add comments (curr. 1)

Return of the Word 2004 FontCacheTool troubles

2007-11-15 19:09:00

Darn... Fighting this little bit of trouble just cost me half an hour and a good chunk of my mood.

After installing the OS X 10.4.11 update, the MS Word 2004 FontCacheTool problems I had back in 2006 arose again. Apparently this part of MS Office regularly gets into trouble with OS X's fonts and caches *grr*

I tried to get rid of the problem in a nice way by disabling any duplicate fonts and by removing the font cache. But that didn't help me any. So instead I reckoned I'd play it dirty; I didn't have time to play with Word.

$ cd /Applications/Microsoft*/Office/Support*

$ sudo mv FontCacheTool FontCacheTool.orig

Screw that piece of kit... If it doesn't want to play nicely, it won't get to play at all. Of course, that's not the proper solution. On the upside of things, Word does boot up very quickly now! ^_^;


kilala.nl tags: , ,

View or add comments (curr. 0)

How do you make grownups re-learn basic maths?

2007-11-15 13:20:00

This semester, the didactics course that's part of Analysis 1 focuses on the teaching of basic maths to children. What kind of troubles do they run into? What are common mistakes they make? How does learning maths even work?!

Of course it's a bit hard for a bunch of grownups to sympathize with the issues kids run into. Adults have been calculating things in their heads for decades and everything's become an autoamtic process.

8 + 5? The answer "13" automatically pops up in my head. No need to even think about it. 2 x 20? Boom! "40".

So how do you make adults relive their days of learning basic maths?

By making them do maths in base-8, ie octal counting.

Using the classic method known as the Land of Okt (het land van Okt), aspiring teachers are introduced to the problems of learning maths. We're using a book published by APS, though there's also a book dedicated to this specific subject.

I have to say that it's an interesting and somewhat frustrating experience. It feels odd break down addition and multiplication into steps again. Ie: 3 + 9 = 3 + 5 + 4 = 14. Or: 4 x 5 = 2 x 12 = 24. Don't even get me started about fractions :D

Yeah... Good stuff! If you're curious to see some of the assignments we're doing, check the Wiki page for week 1.


kilala.nl tags: , , ,

View or add comments (curr. 0)

More test results have come in

2007-11-12 23:38:00

Hooray for more good results!

It's been confirmed that the first result that I got back (see a few days ago) was actually an 8,3! /o/ That's the equivalent of an 83%. Nice!

And the reports I'd turned in for Statistics 1 (all of which can be found over here) were also good for a G (and hence an 8, or 80%). Fsckin' A!


kilala.nl tags: ,

View or add comments (curr. 5)

First exam result is in

2007-11-11 10:00:00

I just checked Osiris (my school's online student administration site) and found my first test result.

Statistics 1 came back a G, which is equivalent to a 7, or a 7,5 if I'm not mistaken. My expectations were spot on :)


kilala.nl tags: ,

View or add comments (curr. 3)

Here I go: my first exams in college

2007-11-05 09:57:00

My calculator, my pens, my reports and my summaries.

So... Exciting day! Today's the first time I'm taking exams for my new college education. Of course I've done all of this before, but that was years ago!

I've got two tests scheduled for today:

* 1200 - 1400 = Statistics 1.

* 1800 - 2000 = Didactics 2.

So yeah, I've got four hours of wasted time in between my tests. I'll use that to go through the summaries some more and to relax a little.

Well, here I go ^_^ Faito!


kilala.nl tags: , ,

View or add comments (curr. 2)

Leopard and new text-to-speech voices

2007-11-04 10:49:00

A small forum discussion at Ars Technica alerted me to one of the new features in OS X Leopard. Apple'd been working on a more lifelike voice-over, which resulted in the voice Alex. I have to say that it's pretty damn impressive, the way they make Alex sound rather lifelike.

What's even scarier is the fact that somehow Apple worked in little breathing-effects as well. There's something weird about hearing your computer draw breath before it starts to speak a sentence.

EDIT:

You can use the voice-over utilities to create audio files as well. Cheap audio-books anyone? Of course, Alex doesn't speak as vividly as any other narrator, but still.

Here's how to do it:

1. Open Terminal.app to get to the command line.

2. Type "say -f ".

3. Drag a plain text file from Finder into the Terminal window.

4. Type " -o ~/Desktop/Spoken.aiff"

5. Press enter.

The say command will read the text input file (-f flag stands for "file") and will output the audio as .AIFF file (-o stands for "output"). The resulting file will appear on your desktop. Once it's done you can convert the .AIFF file to .MP3 using Amadeus.

EDIT2:

Of course, another neat use for this command is to tell you when a huge task is done. For example, I run the "TEC-analysis.sh" script from the command line to analyse a weeks worth of Tivoli alarms. It'd be very easy to do the following:

$ ./TEC-analysis.sh; say TEC Analysis complete!


kilala.nl tags: , ,

View or add comments (curr. 4)

Leopard upgrade, part 1: Powermac

2007-11-03 15:44:00

My new Leopard desktop

Last night I upgraded the first of our three Macintoshes to the new Mac OS X Leopard. I'd decided to start out with the Powermac, since that one's the least crucial of our Macs. Before upgrading her iBook, Marli wants to see the new OS work on my Powermac. And of course I'm saving the all-important work-Macbook for last.

The installation was -not- without problems. I'd forgotten that I'd installed APE (Application Enhancer), which royally screws up any new Leopard install. This isn't that farfetched, since it's a rather hackish piece of software.

After doing a completely fresh, reformatted, install I found another unpleasant surprise: the Migration Assistant software cannot import users whose homedirectory has been File Vaulted. Crap. This meant that I had to transfer all my files and preferences by hand.

So far I like the new OS well enough (haven't noticed much difference), though there's one thing that I already loathe: Spaces. I -love- having a virtual desktop manager built into OS X. Absolutely. I just hate two of the "features" of Spaces.

1. You cannot move windows from one desktop to another using a key combo.

2. Spaces automatically switches to the desktop containing the -main- window of the application you select.

Why is number 2 so bad? Well, let's say that I'm typing up a report on desktop 4. Now a friend pops up on MSN, through Adium. The new Adium window appears on my current desktop: 4. I switch to Adium, to type a reply, and "zing!" I'm moved to desktop 2 because that's where Adium's main window resides.

That fscking sucks!

More Leopard gripes later :)


kilala.nl tags: , ,

View or add comments (curr. 0)

<< 10 / 2007 12 / 2007 >>