× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



The dot folder is an alias for the directory itself. The dot dot
folder is an alias for the directory above it. They are not
considered as files in the directory, so the directory is empty when
only those two entries remain.

John McKee

On Wed, Mar 28, 2012 at 1:47 PM, Kurt Anderson
<kurt.anderson@xxxxxxxxxxxxxx> wrote:
Except it doesn't delete them.  Not using RMVLNK and not using rm.  (At least at 7.1.)

I have to admit the flow of the page threw me.  It looks like the 1st answer has a comment saying to not use rm -rf .*, but the answer doesn't mention using it.  The comment that came after the one saying to not use rm -rf .* says to use it, but came 12 minutes later.

I tried the directory listing into xargs with varying results:
Worked:  ls -A /test/ | xargs rm -rf
Didn't work:  ls -A /home/kurt/test/ | xargs rm -rf

I was essentially wondering if there were any other gotchas with using .*

Thanks,
Kurt

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Charles Wilt
Sent: Wednesday, March 28, 2012 1:24 PM
To: Midrange Systems Technical Discussion
Subject: Re: RMVLNK - extension-only files

Actually that post said don't try .*

As it would try to delete the . and .. folders...

Charles

On Wed, Mar 28, 2012 at 2:17 PM, Kurt Anderson <kurt.anderson@xxxxxxxxxxxxxx> wrote:
In the RMVDIR help there is the line:
If the file system that contains the directory does not support removal of links in the directory and the directory contains object links, error message CPFA0AC "Directory contains objects. Directory is &1." will be sent.

I guess ours doesn't support it.

Thanks for the link, Charles.  Essentially that post is saying to remove .* as well.  Since the system does protect against removing . and .. directories, I think .* is an okay method of removing the files in question.

-Kurt

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Charles Wilt
Sent: Wednesday, March 28, 2012 12:33 PM
To: Midrange Systems Technical Discussion
Subject: Re: RMVLNK - extension-only files

Surprised RMVDIR doesn't work...

RMVLNK not working is apparently not unusual
http://serverfault.com/questions/256748/remove-all-files-not-working-w
ith

Could you use QSH? The thread above suggests ls -A | xargs rm -rf

Charles

On Wed, Mar 28, 2012 at 12:53 PM, Kurt Anderson <kurt.anderson@xxxxxxxxxxxxxx> wrote:
We have an update process that needs to remove a folder on the IFS.  It first performs a RMVLNK  on a folder's contents by using the wildcard *.   This, however, is not removing a file that exists named .OLD (which we think is something created by a software vendor of ours).  Within the help of RMVHLP it says "An asterisk (*) matches any number of characters and a question mark (?)matches a single character."

I tried using *.* but that didn't pick up the .OLD file either.  What does work is .* however that also tries (but fails) to delete the folders . and ..

After removing the contents of the folder, we're doing RMVDIR.   I did try RMVDIR with RMVLNK(*YES) instead, but that didn't work to empty out the folder.

Would it be safe enough for me to add in a RMVLNK command using .* ?

Thanks,
Kurt Anderson
Sr. Programmer/Analyst
CustomCall Data Systems
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L)
mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To
subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take
a moment to review the archives at
http://archive.midrange.com/midrange-l.

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/midrange-l.

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take
a moment to review the archives at
http://archive.midrange.com/midrange-l.

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/midrange-l.

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.