× 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.



I had a script given to me by a contractor of a vendor. It didn't
work. Almost no documentation as to the processing on my end after
script was complete. Turned out that multiple files were copied into
a directory. But, syntax was wrong, as supplied by contractor.

What I saw in the verbose output (-v option) was scp ab instead of
scp a b. The script was scp a$1 b - which made no sense. Contractor
was moving script from another server. Why the $1 at all will forever
remain a mystery.

Assumption is vendor has some idea what is going on. Vendor might,
but contractor might not.

John McKee

On Sat, Aug 17, 2013 at 10:50 AM, Clay B Carley <cbc@xxxxxxxxx> wrote:
Hi John,

Although I'm not exactly familiar with scp on i, I would imagine it's
very similar if not the same to scp on Linux.

What this would mean to me is:
copy a*.txt to <local directory b>

That should copy ablah.txt, afoo.txt, abar.txt, all to (local) directory
"b".

Here's an example:

[cbc@T42 ~]$ cd test
[cbc@T42 test]$ mkdir b
[cbc@T42 test]$ touch afile.txt
[cbc@T42 test]$ touch abfile.txt
[cbc@T42 test]$ touch afoo.txt
[cbc@T42 test]$ touch abar.txt
[cbc@T42 test]$ ll
total 24
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 abar.txt
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 abfile.txt
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 afile.txt
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 afoo.txt
drwxrwxr-x 2 cbc cbc 4096 Aug 17 08:48 b
[cbc@T42 test]$ scp a*.txt b
[cbc@T42 test]$ ll
total 24
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 abar.txt
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 abfile.txt
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 afile.txt
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 afoo.txt
drwxrwxr-x 2 cbc cbc 4096 Aug 17 08:49 b
[cbc@T42 test]$ cd b
[cbc@T42 b]$ ll
total 16
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 abar.txt
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 abfile.txt
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 afile.txt
-rw-rw-r-- 1 cbc cbc 0 Aug 17 08:49 afoo.txt
[cbc@T42 b]$

Does this help?

Clay Carley
Sonic.net/ Sonic Telecom

On 08/16/2013 12:04 PM, John McKee wrote:
What does scp do given the following:

scp a*.TXT b

where there can be multiple files that start with the letter a

and

b is a directory


John McKee

--
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.