From ArchWiki
Revision as of 20:33, 11 February 2010 by DIDI2002 (talk | contribs) (added a newline)
Jump to navigation Jump to search


In general, use of an iPod can be accomplished by simply mounting it somewhere and then pointing a libgpod-compatible program at that mountpoint. Amarok, Rhythmbox, and gtkpod are all capable of this.

Changing iPod Mountpoint

HAL will mount an attached iPod to /media/<iPod name>. If the volume label of your iPod is long, or contains a mixture of spaces, and/or lower-case and capital letters, it may present an inconvenience. You may easily change the volume label for more expedient access using mlabel from the mtools package:

  • Get and confirm the current volume label:
# mlabel -i /dev/sdxx -s ::
  • Set the new volume label (as iPod)
# mlabel -i /dev/sdxx -s ::iPod

Where /dev/sdxx is the current mountpoint of your iPod.

HAL will now automount iPod to /media/iPod.

Converting video for iPod

Gen 5/5.5

DVD to iPod

Get with:
Depends on: aur/gpac mplayer

Has detailed help, and is fairly self explanatory.

Mirrored at

An alternative is to use a method suggested at [DVD Ripping] then use one of the programs listed below to convert that to an iPod-friendly format.

Video File to iPod

Get with:
Depends on: mplayer

I originally found this script here: It has been modified to properly handle filenames with unusual characters. Thanks to Thomer for the great script.


Handbrake is a nifty tool with presets for a variety of iPod versions. A CLI version is available from pacman by:

pacman -S handbrake

or a version with a GTK interface by:

yaourt -S handbrake-gtk-svn

(See Yaourt for information on setting up yaourt)

the version within the package managers seem to be broken though (ie Handbrake version 0.9.3

visit here
or here

If you do decide to take the CLI way, a good guide is available at,

More Advanced/Configurable Methods


Get with: pacman -S avidemux

This can convert to mp4 files. If you enforce a hard max of bitrate @ 700ish and keep the video size to 720x480 or 320x240 than it works fine for video file exporting.


Get with: pacman -S mplayer

Has extremely comprehensive configuration support, which will be able to spit out iPod-compatible video files. Check out man mencoder; a lot of mplayer opts will also affect encoding.

A basic guide is also available at Mencoder.

An example command to encode iPhone/iPod Touch-compatible video:

mencoder INPUT -o output.mp4 \
-vf scale=480:-10,harddup \
-oac faac -faacopts mpeg=4:object=2:raw:br=128 \
-of lavf -lavfopts format=mp4 \
-ovc x264 -x264encopts nocabac:level_idc=30:bframes=0


Get with: pacman -S ffmpeg

Another encoder with comprehensive configuration support. Example command to encode for 5G iPod:

ffmpeg -vcodec xvid -b 300 -qmin 3 -qmax 5 -bufsize 4096 \
-g 300 -acodec aac -ab 96 -i INPUT -s 320x240 \
-aspect 4:3 output.mp4

or iPod Touch/iPhone compatible video output:

ffmpeg -f mp4 -vcodec mpeg4 -maxrate 1000 -b 700 -qmin 3 -qmax 5\
-bufsize 4096 -g 300 -acodec aac -ab 192 -s 480×320 -aspect 4:3 -i INPUT output.mp4

iPhone/iPod Touch


By default, neither the iPhone nor the iPod Touch present mass storage capability over USB, though there exist two solutions for accessing your files.

The first is to mount your device through the FUSE filesystem SSHFS. This requires jailbreaking, which at the moment requires access to a computer running Mac OS or a recent version of Windows, and QuickPwn. After jailbreaking, an SSH server will also need to be installed on the device, which can be done through the Cydia program, installed on the device during the jailbreak process.

The second is to use a different FUSE filesystem called iFuse, which allows you to mount your device through USB, as you normally would. This method requires no hacking and is in general the better solution, though be aware that the software is still under heavy development. As of late, however, it has proven to be rather reliable and stable.

Note: The current development releases of libgpod and gtkpod (libgpod-git & gtkpod-git) support the iPod Touch and the Iphone OS 3.1.x. It's possible to transfer pictures and music without limitationsRefer to this page:[1]

Making Friends with the Device


After this the easiest way to properly initialise a few things on the device's side is with the iPod convenience script. This is available in AUR:

# yaourt -S ipod-convenience

(See Yaourt for information on setting up yaourt)

Next do modprobe fuse to actually load the fuse module. You may also want to add it to your MODULES array in /etc/rc.conf to have it loaded on boot.

A few things may need changing in the script, depending on your setup. If you don't use sudo, replace:

sudo lsusb -v -d 05ac: | grep iSerial | awk '{print $3}' | cut -b1-16 | xargs printf "FirewireGuid: 0x%s" >> $MOUNTPOINT/iTunes_Control/Device/SysInfo


su -c "lsusb -v -d 05ac: | grep iSerial | awk '{print $3}' | cut -b1-16 | xargs printf \"FirewireGuid: 0x%s\" >> $MOUNTPOINT/iTunes_Control/Device/SysInfo"

in the file /usr/share/ipod-convenience/mount-umount. You may also need to replace:

PROCESS=`ssh root@$IPADDRESS ps x | grep MobileMusicPlayer | grep -v grep | awk '{print $1}'`


PROCESS=`ssh root@$IPADDRESS ps ax | grep MobileMusicPlayer | grep -v grep | awk '{print $1}'`

(I'm not sure under what circumstances this is necessary; it was on my iPod Touch running 2.2.1, and it won't have any adverse affect under other firmware version)

After that, edit the /etc/default/ipod-convenience file with details of your device's IP address, and create the mount pount, which is /media/ipod by default (make sure to set the permissions correctly if you want it accessible by a regular user)

To actually mount the device, run ipod-touch-mount or iphone-mount (they both do exactly the same thing so it doesn't matter which). This should prompt for the root password of the device twice, which is 'alpine' by default in firmware versions 1.1 and up. This will need to be done every time you want to sync. (This can be done without having to type the password each time by using SSH keys - see Using SSH Keys for more information)

The iFuse Way

You will need to install libplist, libiphone, and ifuse, so either go over to the AUR or:

# yaourt -S libplist libiphone ifuse

(See Yaourt for information on setting up yaourt)

Now make sure that you have the fuse module loaded by doing modprobe fuse, assuming that you don't have it in /etc/rc.conf already.

You can now mount your device:

# mount -t fuse.ifuse <device file> <mountpoint>

The device file field is just a string that will show up in /etc/mtab, so you can use any value. The mountpoint field is where you actually want to have it mounted.

And you're done! You should be able to point your syncing software of choice to the mountpoint and be able to transfer files.

Unobfuscating the Database

Since firmware version 2.0, Apple has obfuscated the music database. If you are using recent firmware, the file /System/Library/Lockdown/Checkpoint.xml can be modified to enable use of the older, non-obfuscated database. Replace:




Then reboot your device.


Use your favourite iPod-compatible program. Individual configuration will vary, but in general, pointing your program to your specified mount point should yield good results.

After you've synced, run ipod-touch-umount (or iphone-umount, depending on your taste) to unmount the SSHFS file system and restart the MobileMusicPlayer process on the device, so that the new music database is read.

If you used iFuse, simply type:

# umount <mountpoint>

You will still need to reload the MobileMusicPlayer process. If your device is not jailbroken, then you are stuck restarting it.

The iFuse Way - iPhone OS 3.x

Warning: this software is considered unstable and should probably not be used in a productive environment

You will need to install libplist, libimobiledevice, libgpod, usbmuxd and ifuse, so either go over to the AUR or:

# yaourt -S libplist-git libimobiledevice ifuse usbmuxd libgpod-git

(See Yaourt for information on setting up yaourt)

Now make sure that you have the fuse module loaded by doing modprobe fuse, assuming that you don't have it in /etc/rc.conf already. Check if the group "usbmux" has been created and add your user using

# gpasswd -a <user> usbmux

To make sure the new rules apply, execute devadm control --reload-rules and plug in your iPod/iPhone. You should the be able to mount your device by running

$ ifuse ~/ipod

or similar. Make sure the directory used exists and is accessible to your user.

Mount the device and create the iTunes_Control/Device directory. Then, get your UUID. It should be in the syslog from usbmuxd, or you can find it by running

$ lsusb -v | grep -i iSerial

It should be 40 characters long. Then, run

$ ipod-read-sysinfo-extended <uuid> <mountpoint>. 

This should generate a file named iTunes_Control/Device/SysInfoExtended.

Now, start up your favourite app, it should detect the device via libgpod. I recommend using gtkpod-git for the time being, as that's what the libgpod devs seem to be using for debugging purposes.

iPod Classic/Nano3g

You need to set up the iPod to make libgpod able to find its firewire id. For this, you will need to get your firewire id manually

1) Mount the iPod as a rw mountpoint. In the following example, I will use /mnt/ipod.

2 ) Find the serial number by typing

  sudo lsusb -v | grep -i Serial 

this should print a 16 character long string like 00A1234567891231 (it will have no colons or hyphens)

3) Once you have that number, create or edit /mnt/ipod/iPod_Control/Device/SysInfo. Add to that file the line below:

  FirewireGuid: 0xffffffffffffffff

(replace ffffffffffffffff with the 16 digit string you obtained at the previous step and don't forget the trailing 0x before the string)

Your iPod can now be managed with amarok or gtkpod.

See also for more information about iPhone/iPod Touch support