26 November 2013, 09:25 | #1 |
Registered User
Join Date: Apr 2010
Location: London / UK
Posts: 420
|
.uaem and info.uaem files?
I've just noticed that while backing up my real Amiga files to my computer via FS-UAE, it has created the above 2 files for every single file! So for example I now have:
AlienBreed3D (folder) AlienBreed3D.info (icon) AlienBreed3D.info.uaem AlienBreed3D.uaem so this has obviously doubled the amount of files, which is a considerable amount on a 4GB hard disk! What are these files, and how do I get rid of them? When I have to copy these back to my real Amiga HD, I don't want to have to exclude all of these files manually, it will take forever. |
26 November 2013, 10:02 | #2 |
Registered User
Join Date: Oct 2006
Location: germany
Posts: 149
|
FS-UAE uses these files to store file attributes and such iirc.
if you play whdloadgames in FS-UAE you might need these files on certain titles. if you play on a real amiga these files are not needed at all. also each .ueam file is just a few bytes usually whopping 33 bytes. so even with the entire whdload collection (games/demos/mags) the "wasted" space shouldn't be a big problem at all even on a 4gb hd . also getting rid of them on the amiga shouldnt be a huge problem. just look for some kind of a script/program which is able to mass delete files with pre defined filtes e.g. *.uaem or something. Last edited by thevoice; 26 November 2013 at 10:05. Reason: i can almost type i guess |
26 November 2013, 13:31 | #3 |
Amiga-based Cyborg
Join Date: Dec 2004
Location: Canada
Posts: 808
|
I thought when these were implemented that there would be an option to turn them off.
|
26 November 2013, 19:27 | #4 |
FS-UAE Developer
Join Date: Dec 2011
Location: Førde, Norway
Age: 43
Posts: 4,043
|
What thevoice said, and you probably want to keep them (especially if you want the directory hard drive to function as a backup) in order to keep all metadata intact.
When you copy content back to an Amiga drive (from within FS-UAE), the .uaem files will not be copied (they'll only be read in order to figure out the correct permissions/dates). So you won't have to exclude then manually @mr_a500 Yes, that was and is still a possibiliy, I haven't implemented that yet (one might want to be able to turn it on/off per volume), and there hasn't been any demand for it... (= no-one has bugged me about it ) |
28 November 2013, 13:54 | #5 |
Registered User
Join Date: Apr 2013
Location: Engelsdorf / Germany
Posts: 468
|
Maybe the files could be hidden on host OS? In Linux/Mac OS X and - maybe - BSD, a simple "." in front of the file name will hide the file. In Windows there could files be hidden by set it in files properties - maybe this could be a file flag in Windows.
|
28 November 2013, 17:45 | #6 |
FS-UAE Developer
Join Date: Dec 2011
Location: Førde, Norway
Age: 43
Posts: 4,043
|
@amigafreak68k Yes, I have considered (and rejected) that, see http://eab.abime.net/showpost.php?p=909394&postcount=32.
|
01 January 2014, 22:33 | #7 | |
Registered User
Join Date: Aug 2004
Location:
Posts: 3,334
|
Quote:
I was wondering, is there any reason why FS-UAE doesn't use the same _UAEFSDB.___ method as WinUAE? That just adds one file per directory, and would be great for interoperability too, e.g. if the user has shared folders he created using WinUAE. |
|
02 January 2014, 05:21 | #8 |
Registered User
Join Date: Dec 2013
Location: Mountain View / USA
Posts: 34
|
Another idea is instead of brute force creating those files, create them only if an attribute is different from the default (most common) case. Should keep FS UAE from creating these files in 99.9% of the cases, and guess those file are a performance loss.
And ehm, I bother you now to implement a switch to turn this off. ;-) Because most programs don't require it. |
04 January 2014, 17:26 | #9 | |
Registered User
Join Date: Mar 2013
Location: Leipzig/Germany
Posts: 466
|
I use this to delete the unneeded .uaem-files in Linux:
Code:
find /path/to/directory/ -name "*.uaem" -print0 | xargs -0 grep -lZe "----rwed" | xargs -0 rm Quote:
Edit: In fact there seem to be some people here with some good knowledge. So guys, what about some practical solutions instead of only requesting features? Last edited by jbl007; 04 January 2014 at 17:59. |
|
04 January 2014, 18:16 | #10 | |||
FS-UAE Developer
Join Date: Dec 2011
Location: Førde, Norway
Age: 43
Posts: 4,043
|
Quote:
- I personally liked the .uaem approach better, more info here http://eab.abime.net/showpost.php?p=909698&postcount=34 and here http://eab.abime.net/showthread.php?t=67882. - I think there were some concerns with the portability of the UAEFSDB files / file name escaping across multiple OSse because the UAE versions for different platforms didn't agree on what file names had to be rewritten, etc. I don't even remember all the details now, but I concluded that writing a new meta system would be both safer and nicer (the "nicer" argument being somewhat subjective of course ) Quote:
Quote:
(Regarding the C code, it is *almost* that easy if you want a basic non-configurable on-demand uaem feature ) |
|||
04 January 2014, 20:12 | #11 |
Registered User
Join Date: Mar 2013
Location: Leipzig/Germany
Posts: 466
|
I don't know what I'm doing wrong, but fs-uae always creates .uaem files. For example saving a litte text file in MEmacs:
Code:
$ LANG=C stat foo File: 'foo' Size: 18 Blocks: 8 IO Block: 4096 regular file Device: 25h/37d Inode: 8052 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ stw) Gid: ( 100/ users) Access: 2014-01-04 20:05:10.540000000 +0100 Modify: 2014-01-04 20:05:10.540000000 +0100 Change: 2014-01-04 20:05:10.542887952 +0100 Birth: - $ cat foo.uaem ----rwed 2014-01-04 20:05:10.54
|
04 January 2014, 21:20 | #12 |
FS-UAE Developer
Join Date: Dec 2011
Location: Førde, Norway
Age: 43
Posts: 4,043
|
.uaem files create because of the following line(s) in fsdb_host.cpp:
// always write metadata file, for now... need_metadata_file = 1; (since I didn't finish implement a configurable option, it uses the most conservative approach = always write files). Note: removing this line does not make it work as desired, you'd also probably want it to be set to 1 if a comment exists and if permissions are other than ----rwed (and ----rw-d). |
04 March 2014, 13:54 | #13 |
Amiga-based Cyborg
Join Date: Dec 2004
Location: Canada
Posts: 808
|
Can you please add that option to disable creation of .uaem files? I just searched my hard drive and found and deleted 46,857 .uaem files!
|
16 March 2014, 14:02 | #14 |
FS-UAE Developer
Join Date: Dec 2011
Location: Førde, Norway
Age: 43
Posts: 4,043
|
I'll an add option for that in one of the next development versions (Not that I really think it is *that* problematic with 46,857 .uaem files, since it also means you have at least created that many files and folders from within the emulated Amiga, and an occasional find /dir -name *.uaem -delete can alraedy clear it out )
Last edited by FrodeSolheim; 16 March 2014 at 14:08. |
16 March 2014, 17:52 | #15 |
Registered User
Join Date: Aug 2004
Location:
Posts: 3,334
|
Another down side of having many un-needed .uaem files is fragmentation. Even if you delete them (which will also delete the needed ones for files which have comments), the freed space on the drive will then be in thousands of small fragments.
|
07 August 2014, 20:19 | #16 |
FS-UAE Developer
Join Date: Dec 2011
Location: Førde, Norway
Age: 43
Posts: 4,043
|
2.5.8dev is being prepared now, which supports a new option: uaem_write_flags (controls when .uaem metadata files are created):
0 - disable (never create .uaem files) 1 - default (always create .uaem files) n - when file notes are added t - when file time cannot be stored exactly on the host system h - when the hold bit is set s - when the script bit is set p - when the pure bit is set a - when the archive bit is set r - when the read bit is NOT set w - when the write bit is NOT set e - when the execute bit is NOT set d - when the delete bit is NOT set To only create .uaem metadata files when files notes are added: Code:
uaem_write_flags = n Code:
uaem_write_flags = nhsparwed Regardless of the use of this option, when specific .uaem files already exists, they will always be updated. Last edited by FrodeSolheim; 08 August 2014 at 02:23. Reason: uaem_write_flags was spelled wrong in the examples |
16 August 2014, 21:35 | #17 | |
Registered User
Join Date: Mar 2013
Location: Leipzig/Germany
Posts: 466
|
Works great, thanks for implementing this.
I'm using nhsparwed as a default setting now, this makes life a bit easier Quote:
It would be nice to extract archives at the host side and auto-generate .uaem-files if needed. |
|
16 August 2014, 21:42 | #18 | |
FS-UAE Developer
Join Date: Dec 2011
Location: Førde, Norway
Age: 43
Posts: 4,043
|
Quote:
I have already thought about created an little unarchiver tool and bundle it with Fs-UAE Launcher... (the tool would also be useful to extract .zip archives with ISO-8859-1 file encoding - as would be used on Amiga. Many common zip programs do not support this mode of operation...). |
|
16 August 2014, 22:00 | #19 |
Registered User
Join Date: Mar 2013
Location: Leipzig/Germany
Posts: 466
|
Hm, I tried some time ago without success. The .filenote() (or .comment()? - don't remember) methods always returned empty strings. And yes, there were files with file notes in the archive. I think, I'll give it another try...
|
16 August 2014, 22:06 | #20 |
FS-UAE Developer
Join Date: Dec 2011
Location: Førde, Norway
Age: 43
Posts: 4,043
|
Here is partial code from the archive scanner used for WHDLoad imports (it supports both .lha files and .zip files with embedded .uaem files):
Code:
for info in archive.infolist(): name = info.filename if name.endswith(".uaem"): continue comment = info.comment try: metadata = archive.read(name + ".uaem") except KeyError: pass else: metadata = metadata.split("\n")[0].strip() comment = metadata[32:] comment = urllib.unquote(comment) |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
how to create .info files | jimbobrocks92 | support.Other | 2 | 31 December 2011 08:03 |
How to Create .info Files? | AmigaFan | support.Other | 6 | 25 January 2009 20:18 |
info on creating info files icons ? | Dimlow | New to Emulation or Amiga scene | 10 | 16 July 2008 19:28 |
.info files | Aljrob | support.WinUAE | 5 | 14 March 2007 15:42 |
New here with a question about .info files | jobro | Amiga scene | 14 | 24 November 2005 22:48 |
|
|