I was given a Mac-formatted iPod Nano 4G a while back but always had trouble using it with Fedora. By default, the kernel mounts HFS+ (the Mac filesystem) volumes as read-only, which meant that I couldn't update the iPod. Remounting it read-write sort of solved that, but the iPod had problems recognising new tracks and having to manually remount it read-write was a pain (and writing udev rules even more so).
I tried using iTunes in a Windows XP virtual machine, but the VM crashed every time iTunes tried to update the device. This resulted in the filesytem on the device being corrupted so that it could not be mounted. In the end I decided to reformat the iPod to FAT32 (Windows iPod format), so it could be used much more easily in linux.
This turned out to be very simple. I first attached the iPod to my PC via its USB cable and put the iPod into "Disk Mode" by holding down the select and menu buttons together until the Apple logo appeared, then holding select and play/pause. The iPod screen changed to show that it was in Disk Mode.
The iPod appeared on my system as /dev/sdc, with its main partition as /dev/sdc1. If you need to find out where the system creates a device node for your iPod, do as root:
Code:
tail -f /var/log/messages
And watch the output. On mt PC it looks like this:
Code:
Jun 7 15:00:38 johnspc kernel: usb 1-6: new high speed USB device using ehci_hc
d and address 3
Jun 7 15:00:38 johnspc kernel: usb 1-6: New USB device found, idVendor=05ac, idProduct=1263
Jun 7 15:00:38 johnspc kernel: usb 1-6: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Jun 7 15:00:38 johnspc kernel: usb 1-6: Product: iPod
Jun 7 15:00:38 johnspc kernel: usb 1-6: Manufacturer: Apple Inc.
Jun 7 15:00:38 johnspc kernel: usb 1-6: SerialNumber: 000A27001DCEFF61
Jun 7 15:00:38 johnspc kernel: Initializing USB Mass Storage driver...
Jun 7 15:00:38 johnspc kernel: scsi6 : usb-storage 1-6:1.0
Jun 7 15:00:38 johnspc kernel: usbcore: registered new interface driver usb-storage
Jun 7 15:00:38 johnspc kernel: USB Mass Storage support registered.
Jun 7 15:00:43 johnspc kernel: scsi 6:0:0:0: Direct-Access Apple iPod 1.62 PQ: 0 ANSI: 0
Jun 7 15:00:43 johnspc kernel: sd 6:0:0:0: Attached scsi generic sg3 type 0
Jun 7 15:00:43 johnspc kernel: sd 6:0:0:0: [sdc] 1946049 4096-byte logical blocks: (7.97 GB/7.42 GiB)
Jun 7 15:00:43 johnspc kernel: sd 6:0:0:0: [sdc] Write Protect is off
Jun 7 15:00:43 johnspc kernel: sd 6:0:0:0: [sdc] Assuming drive cache: write through
The last few lines had
[sdc] at the start, telling me that the iPod could be accessed at /dev/
sdc
Warning: back up any files you might have on the iPod before the next stage!
I then gave the following command as root:
Code:
mkdosfs -F 32 /dev/sdc1
This creates a new FAT32 filesystem on the iPod,
wiping out the previous HFS+ filesystem and all its data.
I reset the iPod by holding down the select and menu buttons until the Apple logo appeared.
I started up Rhythmbox and it detected an unformatted iPod and asked me to name it. I was then able to transfer music and playlists to and from the device with no hassle. Success!