Removing EA's (extended attributes)

This is a discussion on Removing EA's (extended attributes) within the OS2 forums, part of the Other OS category; Is there a correct way of removing Extened Attributes? Explain: I use the file program DirMaster from Enriva Development. Whenever I access, more, copy, a simple FAT or DOS file ...

Go Back   Unix Linux Forum > Unix > Other OS > OS2

FixUnix.com - Unix Linux Forums

Unix Content Register FAQ Calendar Search Today's Posts Mark Forums Read
Reply

 

Thread Tools
  #1  
Old 08-08-2008, 08:08 PM
Default Removing EA's (extended attributes)

Is there a correct way of removing Extened Attributes?

Explain: I use the file program DirMaster from Enriva Development.
Whenever I access, more, copy, a simple FAT or DOS file from a DOS/FAT
directory. EA's are added. I can see the file "ea data. sf" in the
FAT/DOS directory begin to grow. I know that there are no important
attributes for these files (at least from the programs that used them
- WordStar DOS) , but this "es data. sf" simply takes up room. I can
delete it under another operating system (SuSE 10.3) that is dual
booted on this machine.

Am I missing something?
Is there a more correct (under OS2) way to delete them?

Paul

--

Reply With Quote
  #2  
Old 08-08-2008, 11:10 PM
Default Re: Removing EA's (extended attributes)

On Sat, 9 Aug 2008 00:08:15 UTC, "PaulRS"
wrote:

> Is there a correct way of removing Extened Attributes?
>
> Explain: I use the file program DirMaster from Enriva Development.
> Whenever I access, more, copy, a simple FAT or DOS file from a DOS/FAT
> directory. EA's are added. I can see the file "ea data. sf" in the
> FAT/DOS directory begin to grow. I know that there are no important
> attributes for these files (at least from the programs that used them
> - WordStar DOS) , but this "es data. sf" simply takes up room. I can
> delete it under another operating system (SuSE 10.3) that is dual
> booted on this machine.
>
> Am I missing something?
> Is there a more correct (under OS2) way to delete them?
>
> Paul
>


Have you investigated the EAUTIL command?

Gord Snider
--
Gordon Snider
Toronto, Canada
Reply With Quote
  #3  
Old 08-09-2008, 04:49 AM
Default Re: Removing EA's (extended attributes)

On Sat, 9 Aug 2008 00:08:15 UTC, "PaulRS" wrote:

> Is there a correct way of removing Extened Attributes?
>
> Explain: I use the file program DirMaster from Enriva Development.
> Whenever I access, more, copy, a simple FAT or DOS file from a DOS/FAT
> directory. EA's are added. I can see the file "ea data. sf" in the
> FAT/DOS directory begin to grow. I know that there are no important
> attributes for these files (at least from the programs that used them
> - WordStar DOS) , but this "es data. sf" simply takes up room. I can
> delete it under another operating system (SuSE 10.3) that is dual
> booted on this machine.
>
> Am I missing something?
> Is there a more correct (under OS2) way to delete them?


eautil filename nul /s

--
Bob Eager


Reply With Quote
  #4  
Old 08-09-2008, 05:07 AM
Default Re: Removing EA's (extended attributes)

In article ,
"Gordon Snider" wrote:
>
>Have you investigated the EAUTIL command?


To remove EAs from all files in the current directory,
enter the following at a command prompt:

for %f in (*.*) do eautil "%f" NUL /S

--
Don Hills (dmhills at attglobaldotnet) Wellington, New Zealand
"New interface closely resembles Presentation Manager,
preparing you for the wonders of OS/2!"
-- Advertisement on the box for Microsoft Windows 2.11 for 286
Reply With Quote
  #5  
Old 08-09-2008, 05:52 AM
Default Re: Removing EA's (extended attributes)

On Sat, 9 Aug 2008 09:07:43 UTC, black.hole.4.spam@gmail.com (Don Hills)
wrote:

> In article ,
> "Gordon Snider" wrote:
> >
> >Have you investigated the EAUTIL command?

>
> To remove EAs from all files in the current directory,
> enter the following at a command prompt:
>
> for %f in (*.*) do eautil "%f" NUL /S


That will remove nearly all....

for %f in (*) do eautil "%f" NUL /S

If used in a batch file, use %%f instead.

--
Bob Eager


Reply With Quote
  #6  
Old 08-09-2008, 07:45 AM
Default Re: Removing EA's (extended attributes)

PaulRS wrote:
> Is there a correct way of removing Extened Attributes?
>
> Explain: I use the file program DirMaster from Enriva Development.
> Whenever I access, more, copy, a simple FAT or DOS file from a DOS/FAT
> directory. EA's are added. I can see the file "ea data. sf" in the
> FAT/DOS directory begin to grow. I know that there are no important
> attributes for these files (at least from the programs that used them
> - WordStar DOS) , but this "es data. sf" simply takes up room. I can
> delete it under another operating system (SuSE 10.3) that is dual
> booted on this machine.
>
> Am I missing something?
> Is there a more correct (under OS2) way to delete them?
>
> Paul
>

Besides eautil, there's a 'noEA.exe' utility in the LxLite package on
Hobbes that is fairly easy to use.
http://hobbes.nmsu.edu/pub/os2/util/...er/lxlt133.zip

Mike

--
--- Michael G. Slack (remove '_'s to reply) ---
Reply With Quote
  #7  
Old 08-09-2008, 08:03 AM
Default Re: Removing EA's (extended attributes)

On 09.08.08 11:52, Bob Eager wrote:

> On Sat, 9 Aug 2008 09:07:43 UTC, black.hole.4.spam@gmail.com (Don
> Hills) wrote:
>
>> In article , "Gordon
>> Snider" wrote:
>>
>> for %f in (*.*) do eautil "%f" NUL /S

>
> That will remove nearly all....
>
> for %f in (*) do eautil "%f" NUL /S


For the commands I use on OS/2, * and *.* are equivalent. Linux would
handle them different.

--
Andreas Schnellbacher
Reply With Quote
  #8  
Old 08-09-2008, 08:39 AM
Default Re: Removing EA's (extended attributes)

In article <176uZD2KcidF-pn2-5ddwzVpqYQfq@rikki.tavi.co.uk>
rde42@spamcop.net "Bob Eager" writes:

> On Sat, 9 Aug 2008 00:08:15 UTC, "PaulRS" wrote:
>
> > Is there a correct way of removing Extened Attributes?
> >
> > [...]

>
> eautil filename nul /s


The stuff one learns. FWIW, "help eautil" should display the
full set of commands.

I've never bothered to strip out EAs. Those apps I run in OS/2's
VDOS session (and I use WordStar-DOS all the time) seem to manage
to lose them successfully then OS/2 goes and recreates them. The
only time I actually worry about EAs is when I change a file with
a DOS program and it loses the icon, which can be a right pest.
--
Andrew Stephenson

Reply With Quote
  #9  
Old 08-09-2008, 09:51 AM
Default Re: Removing EA's (extended attributes)

Hi Andreas

Andreas Schnellbacher wrote:
> On 09.08.08 11:52, Bob Eager wrote:
>
>> On Sat, 9 Aug 2008 09:07:43 UTC, black.hole.4.spam@gmail.com (Don
>> Hills) wrote:
>>
>>> In article, "Gordon
>>> Snider" wrote:
>>>
>>> for %f in (*.*) do eautil "%f" NUL /S

>> That will remove nearly all....
>>
>> for %f in (*) do eautil "%f" NUL /S

>
> For the commands I use on OS/2, * and *.* are equivalent. Linux would
> handle them different.
>




Using just * means all files

Using *.* means all files with an extension


They are not quite the same thing and you may want to be aware of that.


Regards

Pete
Reply With Quote
  #10  
Old 08-09-2008, 10:44 AM
Default Re: Removing EA's (extended attributes)

On 08/09/08 09:51 am Peter Brown wrote:

>>>> for %f in (*.*) do eautil "%f" NUL /S
>>> That will remove nearly all....
>>>
>>> for %f in (*) do eautil "%f" NUL /S

>>
>> For the commands I use on OS/2, * and *.* are equivalent. Linux would
>> handle them different.


> Using just * means all files
>
> Using *.* means all files with an extension
>
>
> They are not quite the same thing and you may want to be aware of that.



Depends on the program: they are the same to DIR and DEL, but
BackAgain/2(000) treated them differently.

Perce
Reply With Quote
  #11  
Old 08-09-2008, 10:28 PM
Default Re: Removing EA's (extended attributes)

On Sat, 9 Aug 2008 00:08:15 UTC, "PaulRS"
wrote:

> Is there a correct way of removing Extened Attributes?
>
> Explain: I use the file program DirMaster from Enriva Development.
> Whenever I access, more, copy, a simple FAT or DOS file from a DOS/FAT
> directory. EA's are added. I can see the file "ea data. sf" in the
> FAT/DOS directory begin to grow. I know that there are no important
> attributes for these files (at least from the programs that used them
> - WordStar DOS) , but this "es data. sf" simply takes up room. I can
> delete it under another operating system (SuSE 10.3) that is dual
> booted on this machine.
>
> Am I missing something?
> Is there a more correct (under OS2) way to delete them?
>
> Paul
>


The eautil formula given works for the current directory. However in
my DOS partition I have several levels of subdirectories and the "ea
data. sf" file is in the root directory. I would have to do this with
each directory at several levels.

Let me ask a more basic question: Do the DOS/Files themselves know
they have EA's or is it something that OS/2 puts in the "ea data. sf"
file attached to the filename.

If I just continue to delete the "ea data. sf" file am I messing
anything up? These are only DOS data files that have been moved,
copied to different directories, etc.. OS/2 has added EA's to them.
None are connected to icons, etc.

--

Reply With Quote
  #12  
Old 08-10-2008, 01:40 AM
Default Re: Removing EA's (extended attributes)

PaulRS wrote:
> The eautil formula given works for the current directory. However in
> my DOS partition I have several levels of subdirectories and the "ea
> data. sf" file is in the root directory. I would have to do this with
> each directory at several levels.
>
> Let me ask a more basic question: Do the DOS/Files themselves know
> they have EA's or is it something that OS/2 puts in the "ea data. sf"
> file attached to the filename.
>
> If I just continue to delete the "ea data. sf" file am I messing
> anything up? These are only DOS data files that have been moved,
> copied to different directories, etc.. OS/2 has added EA's to them.
> None are connected to icons, etc.


As a simple alternative, you can just:
attrib -r -s -h "ea data. sf"
del "ea data. sf"

To keep it from happening constantly, you can create a 0-length "ea
data. sf" and make it read only. I think this works as well.

--
[Reverse the parts of the e-mail address to reply.]
Reply With Quote
  #13  
Old 08-10-2008, 04:29 AM
Default Re: Removing EA's (extended attributes)

On Sun, 10 Aug 2008 02:28:36 UTC, "PaulRS" wrote:

> The eautil formula given works for the current directory. However in
> my DOS partition I have several levels of subdirectories and the "ea
> data. sf" file is in the root directory. I would have to do this with
> each directory at several levels.


It's trivial to write a REXX script to do this. Literally only a few
lines.

> Let me ask a more basic question: Do the DOS/Files themselves know
> they have EA's or is it something that OS/2 puts in the "ea data. sf"
> file attached to the filename.


The data is stored in EA DATA. SF on a FAT filesystem. It is linked from
the directory entry for each file.

> If I just continue to delete the "ea data. sf" file am I messing
> anything up? These are only DOS data files that have been moved,
> copied to different directories, etc.. OS/2 has added EA's to them.
> None are connected to icons, etc.


You are damaging the file structure, and CHKDSK will complain.

See:

http://www.tavi.co.uk/os2pages/eadata.html

--
Bob Eager


Reply With Quote
  #14  
Old 08-10-2008, 04:50 AM
Default Re: Removing EA's (extended attributes)

On Sun, 10 Aug 2008 02:28:36 UTC, "PaulRS" wrote:

> The eautil formula given works for the current directory. However in
> my DOS partition I have several levels of subdirectories and the "ea
> data. sf" file is in the root directory. I would have to do this with
> each directory at several levels.


Run this command in the directory that is at the top of the hierarchy
you wish to treat. Do not omit the comment on the first line.

/* Strip EAs from all files */

call RxFuncAdd 'SysLoadFuncs', 'REXXUTIL', 'SysLoadFuncs'
call SysLoadFuncs

call SysFileTree '*', 'f', 'FSO' /* Get file list */

do i = 1 to f.0
say 'stripping:' f.i
'@eautil' f.i 'nul /s'
end

exit 0


--
Bob Eager


Reply With Quote
  #15  
Old 08-10-2008, 08:51 AM
Default Re: Removing EA's (extended attributes)

In article <176uZD2KcidF-pn2-5JTYvjth4yok@rikki.tavi.co.uk>
rde42@spamcop.net "Bob Eager" writes:

> [...]
>
> Run this command in the directory that is at the top of the hierarchy
> you wish to treat. Do not omit the comment on the first line.
>
> [...]


Ta, Bob. Now added to my OS2UTILS toolbox directory -- one never
knows when weird stuff like this can prove handy.
--
Andrew Stephenson

Reply With Quote
  #16  
Old 08-10-2008, 01:36 PM
Default Re: Removing EA's (extended attributes)

Peter Brown wrote:
> Hi Andreas
>
> Andreas Schnellbacher wrote:
>> On 09.08.08 11:52, Bob Eager wrote:
>>
>>> On Sat, 9 Aug 2008 09:07:43 UTC, black.hole.4.spam@gmail.com (Don
>>> Hills) wrote:
>>>
>>>> In article, "Gordon
>>>> Snider" wrote:
>>>>
>>>> for %f in (*.*) do eautil "%f" NUL /S
>>> That will remove nearly all....
>>>
>>> for %f in (*) do eautil "%f" NUL /S

>>
>> For the commands I use on OS/2, * and *.* are equivalent. Linux would
>> handle them different.
>>

>
>
>
> Using just * means all files
>
> Using *.* means all files with an extension
>
>
> They are not quite the same thing and you may want to be aware of that.
>
>
> Regards
>
> Pete


Using eCS2.0RC5, in an OS/2 command window using cmd.exe, dir * and dir *.* both
produce the same list of files. The same is true in a DOS command window using
command.com. There may be contexts in which * and *.* are different, but right off
hand I can't think of one. 4os2 maybe?
Reply With Quote
  #17  
Old 08-10-2008, 04:14 PM
Default Re: Removing EA's (extended attributes)

On 08/10/08 10:36 am, James J. Weinkam wrote:
>> Using just * means all files
>>
>> Using *.* means all files with an extension
>>
>>
>> They are not quite the same thing and you may want to be aware of that.
>>
>>
>> Regards
>>
>> Pete

>
> Using eCS2.0RC5, in an OS/2 command window using cmd.exe, dir * and dir
> *.* both produce the same list of files. The same is true in a DOS
> command window using command.com. There may be contexts in which * and
> *.* are different, but right off hand I can't think of one. 4os2 maybe?


IIRC xcopy is one where you need * to pick up files without an extension
Dave
Reply With Quote
  #18  
Old 08-10-2008, 04:47 PM
Default Re: Removing EA's (extended attributes)

On 10.08.08 22:14, Dave Yeo wrote:

> On 08/10/08 10:36 am, James J. Weinkam wrote:
>
>> Pete wrote:
>>
>>> Using just * means all files
>>>
>>> Using *.* means all files with an extension

>>
>> Using eCS2.0RC5, in an OS/2 command window using cmd.exe, dir * and
>> dir *.* both produce the same list of files. The same is true in a
>> DOS command window using command.com. There may be contexts in
>> which * and *.* are different, but right off hand I can't think of
>> one. 4os2 maybe?

>
> IIRC xcopy is one where you need * to pick up files without an
> extension


No, apparently even XCOPY uses the DosFind* API. That doesn't make a
difference between "*" and "*.*".

--
Andreas Schnellbacher
Reply With Quote
  #19  
Old 08-10-2008, 08:02 PM
Default Re: Removing EA's (extended attributes)

On 08/10/08 01:47 pm, Andreas Schnellbacher wrote:
>> IIRC xcopy is one where you need * to pick up files without an
>> > extension

>
> No, apparently even XCOPY uses the DosFind* API. That doesn't make a
> difference between "*" and "*.*".
>


Hmm, testing shows that you're right Further testing shows even
commands like cp and cat that are built with EMX and use _wildcard()
don't care about * vs *.*
Dave
Reply With Quote
  #20  
Old 08-11-2008, 02:03 PM
Default Re: Removing EA's (extended attributes)

Dave Yeo wrote:
> On 08/10/08 10:36 am, James J. Weinkam wrote:
>>> Using just * means all files
>>>
>>> Using *.* means all files with an extension
>>>
>>>
>>> They are not quite the same thing and you may want to be aware of that.
>>>
>>>
>>> Regards
>>>
>>> Pete

>>
>> Using eCS2.0RC5, in an OS/2 command window using cmd.exe, dir * and dir
>> *.* both produce the same list of files. The same is true in a DOS
>> command window using command.com. There may be contexts in which * and
>> *.* are different, but right off hand I can't think of one. 4os2 maybe?

>
> IIRC xcopy is one where you need * to pick up files without an extension
> Dave

Not so.

Each of xcopy f:\ h:\drvf /h/t/r, xcopy f:\* h:\drvf /h/t/r, and
xcopy f:\*.* h:\drvf /h/t/r copies all of the files in the root of f. h:\drvf was
empty at the start of each trial.
Reply With Quote
Reply

Thread Tools


All times are GMT -5. The time now is 08:54 AM.

In an effort to better serve ads to our visitors, cookies are used on Fixunix.com. For more information, check out our Privacy Policy.

Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
Ad Management by RedTyger