Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 65397 - portage-2.0.51 not able to use FAT32 partition to hold distfiles
Summary: portage-2.0.51 not able to use FAT32 partition to hold distfiles
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High major (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks:
 
Reported: 2004-09-26 05:50 UTC by Wojciech Myrda
Modified: 2004-11-02 06:47 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Wojciech Myrda 2004-09-26 05:50:27 UTC
All the versions of portage (2.0.51) up to (presently latest) RC4 have permision problem with FAT32 partition and are not able to read/write from it/onto it.

Example:
#emerge shared-mime-info
Calculating dependencies  ...done!
>>> emerge (1 of 1) x11-misc/shared-mime-info-0.15 to /
*** Adjusting cvs-src permissions for portage user...
!!! Unable to chgrp of /mnt/win_d/__gentoo to portage, continuing

Traceback (most recent call last):
  File "/usr/bin/emerge", line 2862, in ?
    mydepgraph.merge(mydepgraph.altlist())
  File "/usr/bin/emerge", line 1755, in merge
    retval=portage.doebuild(y,"merge",myroot,self.pkgsettings,edebug)
  File "/usr/lib/portage/pym/portage.py", line 2373, in doebuild
    if not fetch(fetchme, mysettings, listonly=listonly, fetchonly=fetchonly):
  File "/usr/lib/portage/pym/portage.py", line 1642, in fetch
    file_lock = portage_locks.lockfile(mysettings["DISTDIR"]+"/"+locks_in_subdir+"/"+myfile,wantnewlockfile=1)
  File "/usr/lib/portage/pym/portage_locks.py", line 72, in lockfile
    portage.writemsg("Cannot chown a lockfile. This could cause inconvenience later.\n");
NameError: global name 'portage' is not defined

Reprodusible: ALWAYS, same error occurs in portage-2.0.51-RC1/RC3

Temporary Fix: Reverting back to portage 2.0.50-r11

fstab:
/dev/hda11     /mnt/win_d      vfat            user,defaults,umask=000 0 2

The partition is mounted with umask=000 in order to let users have easy access to it. Partition /usr on the other hand is not big enough to hold even small distfiles directory therefore it is essensial that it is possible for portage to use FAT32 partition/s for distfile directory.
Comment 1 Nicholas Jones (RETIRED) gentoo-dev 2004-09-26 22:43:11 UTC
2.0.51_rc6
Comment 2 Wojciech Myrda 2004-09-27 11:19:38 UTC
Great fix. However not complete. The FAT32 partition is fully readable and any distfile present on it is available to portage. Portage is able to retrive the file as well, but just like it says a file. Downloading more than one at a time ends up with the error (the first file however gets saved with no problem).

It is not as severe issue as before since rerunning "emerge -f foo" until all files are saved is possible, however this is very inconvinient.

Looking forward for the fix :)

Example
>>> Downloading http://www.polbox.com/h/hs001/ppp-2.4.2-mppe-mppc-1.1.patch.gz
--20:08:31--  http://www.polbox.com/h/hs001/ppp-2.4.2-mppe-mppc-1.1.patch.gz
           => `/mnt/win_d/__gentoo/ppp-2.4.2-mppe-mppc-1.1.patch.gz'
Connecting to 192.168.1.1:8080... connected.
Proxy request sent, awaiting response... 200 OK
Length: 12,532 [text/plain]

100%[=========================================================================>] 12,532        --.--K/s

20:08:31 (364.39 KB/s) - `/mnt/win_d/__gentoo/ppp-2.4.2-mppe-mppc-1.1.patch.gz' saved [12532/12532]

Traceback (most recent call last):
  File "/usr/bin/emerge", line 2885, in ?
    mydepgraph.merge(mydepgraph.altlist())
  File "/usr/bin/emerge", line 1737, in merge
    retval=portage.doebuild(y,"fetch",myroot,self.pkgsettings,edebug,("--pretend" in myopts),fetchonly=1)
  File "/usr/lib/portage/pym/portage.py", line 2380, in doebuild
    if not fetch(fetchme, mysettings, listonly=listonly, fetchonly=fetchonly):
  File "/usr/lib/portage/pym/portage.py", line 1741, in fetch
    os.chown(mysettings["DISTDIR"]+"/"+myfile,-1,portage_gid)
OSError: [Errno 1] Operation not permitted: '/mnt/win_d/__gentoo/ppp-2.4.2-mppe-mppc-1.1.patch.gz'
Comment 3 Nicholas Jones (RETIRED) gentoo-dev 2004-09-27 12:48:52 UTC
That will be handled in _rc7 coming soon.

You can do this if you'd like in the meantime:

try:
  os.chown
except:
  pass
Comment 4 Jason Stubbs (RETIRED) gentoo-dev 2004-10-21 06:55:34 UTC
Fixed in the released 2.0.51. Reopen if there are more issues.
Comment 5 Jan Pobrislo 2004-11-02 06:47:44 UTC
when DISTDIR itself is folder on fat32 it reports lots of warnings. all this chowning and chgrping should be turn-offable, for example in make.conf

please reopen this bug