LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Problem writing file to iPod using gtkpod (https://www.linuxquestions.org/questions/linux-software-2/problem-writing-file-to-ipod-using-gtkpod-320790/)

tdotman 05-06-2005 12:54 PM

Problem writing file to iPod using gtkpod
 
Hi, I recently installed gtkpod to access my iPod under Linux. It's a FAT32 iPod, and it's mounted fine. Gtkpod can see the tracks, and I can get files off the iPod. But when I try to add new files I get the following message:

Error writing PC file "/media/ipod/iPod_Control/Music/f02/gtkpod01210.mp3".

This seems kind of weird, because the file I'm trying to add isn't even called gtkpod01210.mp3. The iPod is definitely mounted writable, so it must be something else.

I have two machines running Fedora Core 3, and I get the same problem on both of them. Any suggestions would be appreciated.

macemoneta 05-06-2005 04:18 PM

GtkPod renames the files as they are moved onto the iPod. Check your /var/log/messages for filesystem error messages.

Pretty much every iPod I've seen has had to be reformatted at least once (make sure your firmware is up to date). You can reformat and initialize your iPod (assuming you have a good backup) with the following under Linux (assuming your iPod is /dev/sda2 mounted at /media/ipod):

(quit gtkpod)
umount /media/iPod
mkdosfs -F32 /dev/sda2
mount /media/iPod

Restart gtkpod and from the file menu, select "Create iPod's Directories". When that's done, reset your iPod.

Now you can reload the iPod. If you reset your iPod and ever get the exclamation-folder icon, it just means that the iPod directories need to be recreated. This usually means that the filesystem has been trashed, so you need to rerun the steps above. I suspect that the firmware some iPods shipped with had a bug in the filesystem handling. Once they've been updated and reformatted, they seem fine forever.

tdotman 05-07-2005 09:45 AM

Success
 
Thanks for the tip. I ended up plugging it into a windoze box to update the firmware, and then I just did a "restore" on it while it was plugged in. Now it works fine.

If was going to go the mkdosfs route, I think I'd need to add -F32 too.

macemoneta 05-07-2005 10:02 AM

I'm not sure if the restore reformats the iPod, or just erases and rewrites. If not, any filesystem corruption still exists, but may be obscured. I had originally tried this route, and found that the iPod was still acting funny; it would freeze while playing and have to be reset, or the same song would be listed multiple times (even though it was only on the iPod once). If you see strange symptoms like that, you'll know that you need to reformat from scratch. If restore does reformat, then perhaps the bug is in the Windows iPodSetup.

Yes, you need to specify -F32, sorry about the omission.

reh_42 01-19-2006 10:49 PM

Macintosh iPods
 
Quote:

Originally Posted by macemoneta

(quit gtkpod)
umount /media/iPod
mkdosfs -F32 /dev/sda2
mount /media/iPod

What if you have an iPod formatted for a Macintosh? Would I run the same series of commands, or would I change the second line (like I think I should)?

Thank you!

tdotman 01-20-2006 06:48 AM

If your iPod is formatted for MacInstosh and you run those commands, it will no longer be formatted for McIntosh (and all your music will be gone).

I upgraded the firmware and did a "restore" under windows and then when I tried to access it with gtkpod it worked fine. Just make sure all your files are backed up first. That's what I would try first, and if that doesn't work try a linux format.

reh_42 01-22-2006 02:51 PM

I tried to do this, but it's not working correctly. Here is what happened (my iPod is named Pepe Roni, by the way):

# umount /media/Pepe\ Roni/
# mkdosfs -F32 /dev/sdb3
mkdosfs 2.11 (12 Mar 2005)
# mount /media/Pepe\ Roni/
mount: wrong fs type, bad option, bad superblock on /dev/sdb3,
missing codepage or other error
In some cases useful info is found in syslog - try
dmesg | tail or so


What do I do now? Should I edit either the /etc/fstab or /etc/mtab?

Thank you,

Ruth

macemoneta 01-22-2006 03:11 PM

It's /etc/fstab you want to edit. Change the entry for /dev/sdb3 to specify a filesystem type of vfat.

reh_42 01-22-2006 07:41 PM

Thank you so very much.

reh_42 01-23-2006 05:35 PM

Shoot - okay, it didn't work. I don't have an iTunes.db file (I'm not sure if this inevitably matters).

I opened gtkpod and read the device. It picked up the two songs that I had added from my friend's iTunes whenever I updated the firmware. I then added a directory (/home/audio) to the iPod. After it was finished, I tried to sync it and was once again presented with the warning screen of ...

"Could not open file '/media/IPOD .....mp3' for writing"

What in the world is happening?

macemoneta 01-23-2006 06:45 PM

From the gtkpod 'File' menu, select 'Create iPod's Directories' to create the directory structure needed on the iPod. That directory structure was lost when the partition was formatted. Also, make sure the /etc/fstab entry specifies rw access is permitted.

reh_42 01-23-2006 10:59 PM

I created the iPod directories and added a song then synced, but was left with the same problem.


Here is what my /etc/fstab entry looks like.

<file system> <mount point> <type> <options> <dump> <pass>
/dev/sdb2 /media/IPOD vfat rw,nosuid,nodev,auto 0 0


Here is what my /etc/mtab entry looks like.

/dev/sdb2 /media/IPOD vfat rw,nosuid,nodev 0 0

macemoneta 01-23-2006 11:30 PM

You usually need the 'users' or 'uid=xxx,gid=xxx' options to set proper ownership permissions in /etc/fstab. For example:

/dev/sdb2 /media/IPOD vfat users,rw,nosuid,nodev,auto 0 0

or

/dev/sdb2 /media/IPOD vfat uid=reh_42,gid=reh_42,rw,nosuid,nodev,auto 0 0

Also, in previous posts you referred to /dev/sdb3; are you specifying the correct partition in /etc/fstab?


All times are GMT -5. The time now is 07:39 AM.