Wir fahren nach Berlin

4. Oktober 2008 1 Kommentar

Vor unserem Auslandsaufenthalt haben Valérie und ich noch ein paar schöne Tage in Berlin verbracht! Für mich war es der erste (und bestimmt nicht letzte) Besuch und ich kann sagen, dass Berlin mich sehr positiv überrascht hat. So hatte ich mir die deutsche Hauptstadt nicht vorgestellt.

Ich möchte garnicht wagen hier eine Beschreibung zu versuchen – dazu ist die Stadt einfach zu vielseitig. Valérie hat schon einige Stichworte in Ihrem Blog genannt. Dem bleibt eigentlich nichts mehr hinzuzufügen aber unterstreichen würde ich das Wort modern. Wer mehr über Berlin erfahren will sollte selbst dort hin fahren. Es lohnt sich!

Außerdem findet ihr bei Valérie noch viele schöne Bilder. Hier ein paar die ich mit meiner Handy-Kamera gemacht habe:

Categories: Reise

How to: Use existing Time Machine backups wireless

2. August 2008 43 Kommentare

This how-to describes how to use shares on your local network as backup volumes for Apple’s Time Machine. This is interesting especially if the network is wireless! And different from other hints on the web, this article tells you how you can keep your existing backups for that. Apple sells this functionality with its Time Capsule products (but they do not support the reuse of existing backups).

If you don’t want to read the whole article and know the Terminal well, here it is in very compressed form:
defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1
sudo hdiutil create -srcdevice /dev/<diskXsY> -format UDSB -fs HFS+J -volname Backups -layout NONE /Volumes/<your network share>/.<your ethernet macaddress without colons>

Many posts on the web helped me to get this working and I would like to thank especially Florian Kruse for his article on this topic. If you are setting up Time Machine for the first time and would like to do that over network, read his article.

What you will need:

  1. Time.
  2. Some kind of computer (Mac, Linux, Windows, …) that you have access to and that is connected to your network. I will reference to it as the server from now on.
    If it’s possible to connect external hard drives to your router, you can of course use this as your server as well.
  3. A network share on the server (the place where your backups will be kept). This can also be your existing external drive where you keep your backups right now.
  4. The same amount of free space that your existing backups take up. And it must not be on the same partition on which the existing backups are stored right now!
    One way to find out how much space they use is to open the Disk Utility (under /Applications/Utilities), select the backup volume and see what it says at the bottom of the window.
    This is because you will need to create a copy of your backups (see next section why). If you’re planning to use your external hard drive as your backup volume, you will need to create the copy elsewhere, format your backup volume and then move the copy back.

How it works:

If you connect an external drive (e.g. over USB) to your Mac and make your backups, the files, folders and Time Machine config files are naturally written onto the partition you chose.
But if you use Volumes that are mounted over network, Apple decided to use another technique. They create a SparseBundle file on the network drive (read here what it is). This file is a kind of disk image and contains all the data we would have on a USB drive. It is then mounted on your Mac and is used for backups.
Now you could say: “Why this double trouble”? There are some reasons why we want this!
The best thing is, that it has the HFS+ Journaled filesystem! This way we can use any network share without having it to support HFS+ Journaled. Maybe you have tried to connect your USB drive to the server before. What happened? Right you can’t mount it writable because HFS+ Journaled isn’t fully supported by Linux, yet.
Another advantage is, that it only takes up the space it needs! You don’t have to create a fixed partition that takes up hundreds of gigabytes even if it’s not used. Nevertheless it can be unmounted (which Time Machine actually does) every time the Backup is not needed.
Yet another important reason: The files on your Mac can have complicated extended permissions and hard- and soft-links etc.. Network shares like Samba(Windows share) or FTP do not support these high fidelity file permissions and types. So you wouldn’t be able to use them as backup volumes.

Before you start:

Make sure your Mac can connect to the network share on the server and has read and write permissions. The used protocol is irrelevant (see section above why).
I cannot explain how to set up the network share in this article since and is different for each platform and type.
Warning: Be careful with your backups! I myself had a head-crash while my backups were broken. Yes, it is possible! So always know where your backup files are!

How to do it:

  1. Turn Time Machine off so it doesn’t interfere.
  2. Creating the SparseBundle (the interesting part)
    As I said before, you will need empty space in size of your backups where you can save the bundle file. If it’s on the network share, great! That’s where it should be. If you’re planning to use your external hard drive as your network share, you will need to create the bundle file elsewhere, delete your backups and then move the bundle there. “Elsewhere” can also be on the external drive as long it’s on a different partition.    

    1. Find out the backup identifier
      To do so, in Terminal (/Applications/Utilities) enter
      ls -la /Volumes/<nameofyourtimemachinevolume>
      It will show you a list of files. Find the one that starts with a dot and ends with a twelve digit hex-code e.g .0019e56f322a Write down this string somewhere.
    2. Find out the device file of the backup volume. Therefore open the Disk Utility (/Applications/Utilities). There, right-click (control-click) on the backup volume and open the Information window. The device filename is the name after Disk Identifier. It should be something like disk1s1. Again, note it.
    3. Unmount the backup volume
      In Disk Utility, select the backup volume and hit unmount. Do not eject the disk!
    4. Create the SparseBundle by opening the Terminal (/Applications/Utilities) and entering the following line:
      sudo hdiutil create -srcdevice /dev/diskXsY -format UDSB -fs HFS+J -volname Backups -layout NONE /path/to/free/space/filename
      Where diskXsY is the Disk Identifier you found in 3.2 and /path/to/free/space is the location where you would like to save the bundle file to. When it’s done, you will find a file named filename.sparsebundle there.
      Hint: This operation takes a long time. It took about an hour for my 75 GB backup.
    5. Optional: If you did not create the file on the network share, move it there now (in Finder hold down the option key for moving instead of copying). If you would like to use your existing backup drive as the network share, you will probably need to format it first (not as HFS+ Journaled!) and then move the sparsebundle file there. To format it, use Disk Utility.
    6. Name the file right
      The .sparsebundle file must have the same name you found in 3.1. Finder won’t let you rename files to names that start with a dot. So open the Terminal again and goto the location where you created the file. There, type
      mv filename.sparsebundle .0019e56f322a.sparsebundle
      Of course using your values instead.
  3. Enable Time Machine for network volumes
    By default, Time Machine won’t let you choose volumes that are mounted over network. To enable it type the following in the terminal:
    defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1
  4. Turn Time Machine on
    Make sure you have mounted the network share with the sparsebundle file in it (and it’s not in subfolders). Then open Time Machine preferences, click “change disk…” and choose the network share.
    Leave the settings window open to see if it worked. If so, it will start to backup. When it finishes, you will be able to use your old backups!
Categories: other Stuff

Retro Apple Boot Logo on iPhone 2.0

29. Juli 2008 4 Kommentare

The new Pawnage-Tool for iPhone or iPod touch allows to set custom Images that show during boot (read here how to use it, you will need to choose the expert mode in pawnage-tool).

The coolest thing of course is to use the Apple retro logo!

Here is the file you can use with the pawnage-tool:
logo.png (right click and save as…)

The following file is for the GIMP if you would like to modify it or add custom text to it:
logo.xcf

(Read my other post how to install GIMP on Mac 10.5)

Categories: other Stuff

Schwarzwald total

28. Juli 2008 Keine Kommentare

Letztes Wochenende haben wir Valéries Eltern in Kniebis mitten im Schwarzwald besucht! Es gab gutes Essen und die Luft war frisch. Wie im Urlaub. Auf Valéries Blog findet ihr ein paar Bilder von unserer Wander-Tour: Valéries Blog

Categories: other Stuff

Valérie rettet die Welt!

28. Juli 2008 2 Kommentare

Es hat geklappt! Valérie hat ihren eignen Blog! Damit ist die Welt vielleicht ein kleines Stückchen besser geworden.
Wir dürfen gespannt sein wie sie ihr Blog-Motto umsetzt: Der Versuch die Welt zu bereichern…

Ich wünsche dir viele Besucher auf deinem neuen Blog Schatz!

Also alle den Link am besten gleich Bookmarken: http://www.klaissle.com!

Categories: other Stuff

Hard-install of my home-server aka Time Capsule

24. Juli 2008 1 Kommentar

It’s been a hard way but now the finish comes into sight. After having the sound streaming over network (I reported) and finally getting Time Machine to work wirelessly (I will report in near future), I could begin mounting my debian box into the cupboard.

Here are some pictures:

First, install. Although its software, it\'s a hard job!

Me as usual.. Although its software, it's a hard job!

Just have it run. Nothing more. You know, the beauty is inside :)

Works out of the box! You know, the beauty is inside :)

Ok everything is setup. Mount localhost. HAHAHA

Ok everything is setup. Mount localhost. HAHAHA

This looks so simple but it was a struggle

This looks so simple but it was a struggle

Glue it all together. Noticed the exhaust holes? Hihi

Brushed metal and glass. Noticed the exhaust holes? Hihi

Plug in cables and shut the door.

My so called case

After cleaning up...

In context. After cleaning up...

 

Categories: other Stuff

How to: AirTunes without AirPort

22. Juli 2008 8 Kommentare

This how-to describes how to set up a linux (or mac or even windows) machine to serve as a sound client for your mac so that it will play any sound from your mac over network. For example you can sit on the couch with your MacBook on your lap and don’t have to shredder your music with these tiny internal speakers. Or, you could play music in your living room from the mac in your office. Apple calls this functionality AirTunes and sells it with its AirPort or TimeCapsule products.

Wonderful world? Almost. What you will need:

  1. Joy on fixing computers
  2. Time
  3. A linux box or a mac that is connected to the speakers. E.g. your stereo.
    It should potentially be able to run forever so you don’t have to turn it on every time you want to use your speakers. If you already have an existing set-top-box for your TV running linux (e.g. the Reelbox or any other VDR) you can of course use this! I’m using an VIA EPIA Mini-ITX board with fanless cooling. You could also use a windows machine with cygwin on it.
    No matter how this machine is shaped, I will reference to it as the client from now on (because it receives the sound stream).
  4. Some kind of network connection between the mac (we call it the server here) and the client.
    Most likely this connection is wireless through your router.

If you would have to buy an extra router for this purpose anyways, think about spending the money on an Apple AirPort and have it working out of the box. But, on the other hand if you already meet the four prerequisites, then you can save at least a hundret bucks!

0. Before you start:

  1. Have an OS running on the client. Installing Linux or cywing is a chapter that cannot be covered here.
  2. Make sure you have a working network connection between server and client. This too, is another chapter for itself.
  3. Connect the stereo or other speakers to the client. (this is important for testing)

A. Setting up the client-side (receives sound)

We need to get sound out of it and the Enlightment Sound Deamon (esd) working.
Important: I assume a debian system here. If you use another distro, you should know what to do there.

  1. See if you have it already installed. Type # esd -tcp -public in the promt. If it starts and makes a funky sound, you’re half way there! Continue with B. Setting up the server side
    If not, install it with # apt-get install esound and try the above again. If it still doesn’t work, do the following.
  2. To get your soundcard working, it’s easiest to use ALSA (established and works with most cards). To do so, install alsa-base and alsa-utils with # apt-get install alsa-base and # apt-get install alsa-utils resepctively. Restart. Then configure your soundcard with # alsaconf. This assistant should find your soundcard and configure it for you. Then try 1 again.
    If not, see section C. for Troubleshooting.
B. Setting up the server side (streams sound)
What we do here is to use the Enlightment Sound Deamon again. This time for streaming the audio to your client. In order for the ESD to get any audio from your system, you’ll need to install an audio driver called Soundflower.
  1. Download Soundflower 1.3.1 from my webspace soundflower-131 or from MacUpdate
    The developers homepage (cycling74) only has an older version.
    After installation, go to your System Preferences and choose the Soundflower driver as your default output device and as your default input(!) device (and if you like, as default system sound device). What it does is to forward the sound (from the output) to the Soundflower driver (to the input) so we can access it with ESD.
  2. Next, we have to install ESD. For this, we need MacPorts. If you already have it installed, jump to the next step. If not, don’t hesitate to install it! You might need it for other purposes in future anyways. You can get it from here: macports.org.
    Optional: After installing, you might want to add /opt/local/bin to your PATH. See my other post how to do this properly.
  3. Now install the esd via macports by typing # sudo /opt/local/bin/port install esound
  4. Almost done! Run the esd and stream it’s input to the client by doing (not as root):
    # esd -tcp -bind ::1 & (makes it listen to your computers ipv6 stream, “&” starts it in background)
    Hit return twice to get the promt (Apple Terminal specific thing…) and pipe the input to the streamer with # (esdrec -s ::1 | esdcat -s <client-ip>) &
C. Troubleshooting
  • When trying to start esd you get error /dev/dsp not found.
    ? Have you installed alsa-base? Run alsa-conf again. It’s neccessary to restart afterwards!
  • alsaconf doesn’t find your soundcard.
    ? If it’s an onboard soundcard, make sure it’s enabled in the BIOS!
  • Both ESDs run but no sound.
    ? Stereo on? Stereo’s volume up? iTunes’ volume up? Song is not playing its last seconds?
    ? Does the client make a funky sound when starting ESD? This is essential. If not, make your soundcard work with ALSA.
    ? Can you ping the client IP?
    ? Is there a firewall somewhere inbetween? Make sure you can send on TCP port 16001
    ? Make sure you have started esd on the client first and then on the mac.
    ? Do not start esd as root! Do it as the user you’re logged in as (default).
    ? I had some trouble with background processes before. Try  # esd -tcp -bind ::1 then open another Terminal window and type # esdrec -s ::1 | esdcat -s <client-ip>
    ? Both processes on the mac and the process on the client should not quit. Test this by not appending the & sign to the command. If one of them quits immediately you found the problem. Try restarting the client and deleting the ~/.esd_auth files on the client and do it all again in the right order.
  • Some useful links
    Similar tutorial: Mac OS X hints
    ALSA official WIKI: alsa-project.org
    S.o. who had ALSA trouble: nicktips.blogspot.org
    ALSA sound mini How-To: ALSA sound howto
    Official EsounD Manual: http://www.tux.org/~ricdude
    Debian Packages. You might find something useful for tests here: packages.debian.org
D. Autostart / Cleanup
  1. Startup script on client. Again, I assume a debian system here.
    Modify  your /etc/esound/esd.conf to look like this esd.conf. Important is to set the autospawn to 1 and the default_options to -tcp -public.
    Warning: This config makes esd listen for any incoming stream. Replace -public by -bind <server-ip> to make it listen only to your mac!
    Then extract this startup script Esound (for init) to /etc/init.d/  and make proper symlinks by running update-rc.d Esound defaults. That’s it. On next boot, esd should start automatically. If you ever need to start it by hand you can simply do esd &
  2. Startup script on the server. This is still beta and not working 100% reliable. If you made any progress here, I would be thankful to hear from you.
    Download this startup script: Esound for mac and extract it to /Users/Shared Then set it to be executed at login by typing: sudo defaults write com.apple.loginwindow LoginHook /Users/Shared/Esound
    Hint: Give the ESD some time to respawn after waking up your mac from sleep.
  3. Troubleshooting
    If the whole machinery doesn’t work after wakeup or reastart, you probably have to restart the deamon on the client. To do this, find out it’s PID with ps aux | grep esd and kill it. Then restart it with esd &. Next, on the server side kill it the same way and restart streaming by doubleclicking on the /Users/Shares/Esound script. Any suggestions are welcome!
Categories: other Stuff

Howto: Turn off EDGE on iPhone 2.0

20. Juli 2008 21 Kommentare

UPDATE:
BossPrefs is now available for Firmware 2.0! You can find it in the Cydia-Installer. It lets you turn on and off EDGE on demand! So use BossPrefs instead!
 

Firmware 2.0 came and installer.app left.
Right. Installer.app will not work on firmware 2.0 phone, nore will the the other apps you have installed with installer before. This also means, that you won’t have BossPrefs or Services to turn on or off your EDGE connection on demand. Here is a little workaround to permanently turn EDGE off until the above tools will become available for the firmware 2.0.

First, to save you from any costs immediately, you should turn on the flight-mode and then turn on Wi-Fi again (yes, this combination is now possible). This turns off EDGE but also the phone capability, so it’s not a solution.

As a requirement you need to have OpenSSH installed. You probably have, if you chose the simple-mode in pawnage-tool.
I will describe the graphical way here but you can also do it via Terminal.
Hint: You might set the auto-lock time in Settings to never while doing this, since it will loose connection on locking. 

  1. Find out your iPhone’s IP Address in Settings>Wi-Fi by clicking on the small arrow next to your Wi-Fi Network.
  2. Open Cyberduck (you don’t have it? Get the best FTP-client for mac here http://cyberduck.ch)
  3. In Cyberduck, click on Open Connection. There,
    1. choose SFTP as the protocol to use
    2. enter your iPhone’s IP address as the server address
    3. root as user name
    4. alpine as password
  4. Once connected, go to /System/Library/Carrier Bundles
  5. You’ll see a lot of numbers. Don’t worry. Scroll down to end of the list to find human-readable names and choose your carrier.
  6. Download carrier.plist (if you do this with Terminal, open this file with nano)
  7. Double-click it to open it with Property List Editor
  8. Go to Root>apns>0 and change the value of apn (it’s sufficient to add an extra word, e.g. offline so you can undo changes later if you need to)
  9. Safe and upload the file to the same spot where you downloaded it off you iphone (be sure here, Cyberduck might fool you).
  10. Restart your iPhone and turn off airplane-mode. You can try if it worked by turning off Wi-Fi and trying to access a web page. If it says “unable to connect” you did everything right :)
Categories: on the iPhone

iPhone 2.0 unlock available!

20. Juli 2008 1 Kommentar
This morning, the iPhone dev-team posted this beautiful comment

This morning, the iPhone dev-team posted this beautiful comment

Here is how to do it:

The apps you installed with installer.app will be removed!
The installer.app is not available for Firmware 2.0 right now!

  1. Download the Pwnage-Tool from one of the mirrors posted in their blog
    e.g.: http://thebigboss.org/repofiles/nonrepo/PwnageTool_2.0.zip
    or: http://rapidshare.com/files/131007777/PwnageTool_2.0.zip
  2. Download the Firmware 2.0 from
    here: iPhone1,1_2.0_5A347_Restore.ipsw
    Do it with Firefox! Safari will unzip it automatically and you won’t be able to use it unzipped
  3. Download the Bootloaders 3.9 and 4.6
    3.9: http://ispazio.net/FFU/files/BL-39.bin.zip
    4.6: http://ispazio.net/FFU/files/BL-46.bin.zip
  4. Run the Pawnage Tool you downloaded in 1.
    You might want to run it in expert mode to edit Boot-Images and install custom packages.
    It will eventually build a single, custom .ipsw-File.
  5. Put your iPhone to recovery-mode. For this do the following
    1. Turn it off
    2. Plug in the USB-connector
    3. Push and hold the power- and home-button
    4. After approx. 3 seconds release the power-button but still hold the home-button
    5. When the recovery-sign appears, you can release the home-button as well
  6. iTunes will tell you, that it found a device in recovery-mode
  7. Hold down the alt-key and click on the restore…-button in iTunes
  8. Select your custom .ipsw-file
  9. After recovery, the BootNeuter.app will run and unlock your phone.
  10. After restart, you can restore an backup of your iPhone with iTunes
Categories: on the iPhone

Installing GIMP under Mac OS X 10.5 (Leopard)

18. Juli 2008 Keine Kommentare

GIMP is great! But just dragging it into the Applications folder won’t work under 10.5.

I’m writing this to save you some time with trying things that some people have posted on the Internet.
The following will not work:

  1. Reinstalling X11 from the Mac OS X install-DVD
  2. Downloading and installing the combo-update for 10.5
  3. or for 10.2
All you need to do is to goto http://www.xdarwin.org download and install the latest X11 package (you will be forced to logout afterwards).
Categories: other Stuff