Home > iphone, linux > How to sync music between iphone and Ubuntu

How to sync music between iphone and Ubuntu

December 27th, 2009 Leave a comment Go to comments

This method is deprecated
Use This other method instead to sync iphone and ubuntu

http://www.mexlinux.com/how-to-sync-music-between-iphone-and-ubuntu-using-new-ifuse/

OK, now is beginig to be possible to sync your music from Ubuntu to your iPhone, thanks to the work of marcan and many others.

Disclaimer: This is very Alfa software, I didn’t invented any of the things I’m writing about, I just adpated the marcan instructions in the way they worked for me, to my personal systems, wich I’m sure many are using: Ubuntu Karmic Koala 9.10 and iPhone 3G with OS 3.1.2, by the way you need to have some music synced by iTunes before you can start.
Don’t cry if your iPhone melts:

1- update your system, either via synaptic or with

sudo apt-get update

sudo apt-get upgrade

2- Add the PPA repository with the needed packages :

deb http://ppa.launchpad.net/jonabeck/ppa/ubuntu karmic main

Either adding it as root to your /etc/apt/sources.list file

Or with the GUI “Software sources”

Then add the key for the repo with this command:
sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com F0876AC9

And update again with:

sudo apt-get update


3- Install the packages required for compilation, and the already packaged libraries:

sudo apt-get install git-core cmake autoconf libtool libglib2.0-dev intltool gtk-doc-tools libsqlite3-dev libxml2-dev  libiphone-dev libplist1 libusb-1.0-0 libusb-1.0-0-dev libusbmux0 libusbmux-dev ifuse libiphone0 libplist0 libplist-dev

4-Get the libgpod code and compile it:

$ git clone git://gtkpod.git.sourceforge.net/gitroot/gtkpod/libgpod
$ cd libgpod
$ CFLAGS=”-g -O0″ sh autogen.sh –prefix=/usr
$ make
$ sudo make install

5-Create a folder to mount it, and mount it:

sudo mkdir /media/ipod

**connect your iPhone**

sudo ifuse /media/ipod

6-Create the needed directory and files:

cd /media/ipod/iTunes_Control
mkdir Device

Find your UUID with

lsusb -v | grep -i iSerial

grab your UUID wich is the 40 characters long text
and run the following command replaceing with yours:

ipod-read-sysinfo-extended /media/ipod

This has generated a needed file into the Device folder.

7-Thats it. Now you can open the gtkpod application and sync your iPhone.

Notes:
In order tu unmount your iphone first dissconect it via gtkpod and the you can use

sudo umount /media/ipod

And to mount it again just

sudo ifuse /media/ipod

SocialTwist Tell-a-Friend
Categories: iphone, linux Tags: , , , ,
  1. Joe
    December 29th, 2009 at 10:26 | #1

    im getting the message that it can’t find most of those packages…i followed the steps and added that repo…

  2. December 29th, 2009 at 12:20 | #2

    @Joe
    I had a typo that said “lib-glib2.0-dev” when it should say “libglib2.0-dev” (it’s corrected now) but all other package names are correct.

    Try with synaptic, “refresh” (the blue arrow) and look for those packages

  3. csp
    December 29th, 2009 at 17:28 | #3

    Hi, that’s great!

    there was even a small issue with the lib names: used libxml2-dev instead of libxml++-2.0-dev

  4. csp
    December 29th, 2009 at 18:54 | #4

    Note: there is already an other method available using GVFS (no need to compile files, no need to manual mount the iphone)
    link: http://fernmannblog.wordpress.com/2009/12/18/howto-iphone-os-3-x-unter-linux-synchronisieren-diesmal-uber-gvfs/ (german)

  5. December 30th, 2009 at 01:54 | #5

    @csp
    You are right, corrected, thanks.

  6. December 31st, 2009 at 11:49 | #6

    package “lib-sqlite3-dev” doesn’t exist. The correct one is “libsqlite3-dev” ;)

  7. December 31st, 2009 at 12:43 | #7

    @Francesko
    Thx, wow I was maybe sleeping, so many typos….

  8. Jonathan
    January 4th, 2010 at 02:13 | #8

    I got my UUID and tried to run:
    ‘sudo ipod-read-sysinfo-extended /media/ipod’
    and got:
    Couldn’t write SysInfoExtended to /media/ipod

    The /media/ipod/iTunes_Control/Device directory already existed on my iphone, and I can’t write ANYTHING to the directory. It seems I can write to other directories on the phone.

    Can anyone help me? The phone isn’t jailbroken, its a 3g with 3.1.2 firmware.

  9. January 8th, 2010 at 10:07 | #9

    Please add a command to add the key for the repo?
    Now I have this:
    W: GPG error: http://ppa.launchpad.net karmic Release: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY F104610CF0876AC9

  10. January 8th, 2010 at 22:59 | #10

    @Vincent
    Just added, please see above.
    Thanks for pointing that out.

  11. Shyboy
    January 9th, 2010 at 16:23 | #11

    Hi i m new i ubuntu n i found it awesome OS than windows which is more prone to virusus.
    plz tell me i have installed virtualmachine n then winows xp in which i install itunes8.2
    it also detects my iphone in itunes
    plz tell can i sync restore it normally.

    Also tell i tryd to install itunes8.2 in ubuntu using wine but it fails to install so which software i can use to sync.
    Thankx in advance

  12. January 10th, 2010 at 00:02 | #12

    @Shyboy
    The method described in this post does not requiere itunes, either via wine or ina windows virtual machine. The only required aplication is gtkpod.

    (you can install gtkpod with the command: sudo apt-get install gtkpod)

    Nevertheless if you already have itunes and windows in a virtualmachine, syncronization is possible with the files you have inside windows, in this case you can use a shered folder from linux to your windows, so you don’t have to copy the files.

  13. Shyboy
    January 10th, 2010 at 04:42 | #13

    Thankx for reply
    i have shared folder also and songs and application are added in itunes in Windows via linux
    but i read an article somewhere dat i cant restore my iphone through this method is it possible to restore?

  14. siggismallz
    January 10th, 2010 at 09:37 | #14

    will it sync with amarok 1.4.10?
    as far as i understand, wireless syncing is at the moment not possible anymore?

  15. January 10th, 2010 at 12:06 | #15

    @Shyboy
    I remember I once did a restore from a windows inside virtualbox inside ubuntu. So it can work for sure. But I also remember I had to make some kernel modifications, wich I don’t remember in order to do that, but that was maybe one year ago… I can’t tell now.

  16. January 10th, 2010 at 12:11 | #16

    @siggismallz
    In theory it should work with any application using libgpod, but since development is being done with gtkpod that’s the more proven application. It’s just a matter of try it.

    Wireless syncing uses a diffrent method. So they can not be combined at the moment.

  17. Shyboy
    January 10th, 2010 at 14:34 | #17

    Means its not sure bt it may work
    thankss for reply

  18. wereguy2
    February 23rd, 2010 at 01:19 | #18

    iFuse and libiphone0 appear to be incompatible. Installing one will remove the other…

  19. James
    March 6th, 2010 at 01:53 | #19

    @wereguy2
    wereguy2 – i had this problem – just replace “libiphone0″ with “libimobiledevice0″

  20. Julian
    March 18th, 2010 at 12:29 | #20

    -O0″: command not found
    that’s what i get when i try to run CFLAGS=”-g -O0″ sh autogen.sh –prefix=/usr

  21. Julian
    March 18th, 2010 at 13:51 | #21

    what should i do to solve the problem above? I need to get this working :(

  22. March 25th, 2010 at 22:58 | #22

    This method is deprecated
    Use This other method instead to sync iphone and ubuntu
    http://www.mexlinux.com/how-to-sync-music-between-iphone-and-ubuntu-using-new-ifuse/

  1. No trackbacks yet.