Page 1 of 1

Unix Trivia

Posted: Fri 08 Nov 2019, 03:06
by rufwoof
Why is the dd command called "dd" ?

.
.
.

dd = convert and copy command, but as c compile (cc) was already used it was decided to shift up the alphabet for the 'convert and copy' command.

Second video https://catonmat.net/why-unix-commands-are-short 30:40

Posted: Fri 08 Nov 2019, 03:36
by jafadmin
It actually comes from the IBM Job Control Language for batch processing.
The following example, using JCL, DD is used to copy a file on OS/360:

Code: Select all

//IS198CPY JOB (IS198T30500),'COPY JOB',CLASS=L,MSGCLASS=X
//COPY01   EXEC PGM=IEBGENER
//SYSPRINT DD SYSOUT=*
//SYSUT1   DD DSN=OLDFILE,DISP=SHR
//SYSUT2   DD DSN=NEWFILE,
//            DISP=(NEW,CATLG,DELETE),
//            SPACE=(CYL,(40,5),RLSE),
//            DCB=(LRECL=115,BLKSIZE=1150)
//SYSIN  DD DUMMY

Posted: Fri 08 Nov 2019, 09:44
by mistfire
DD

DUPLICATE
DISK

Posted: Fri 08 Nov 2019, 10:36
by rufwoof

Code: Select all

# dd --help
Usage: dd [OPERAND]...
or: dd OPTION
Copy a file, converting and formatting according to the operands.
.
.

Posted: Fri 08 Nov 2019, 15:31
by Burn_IT
jfadmin No it doesn't.

The DD statement in JCL stands for Data Definition and has nothing whatsoever to do with copying.

The program IEBGENER is the thing that does the copying.
SYSUT1 is the source file
and SYSUT2 is the target file
in your example.

Posted: Fri 08 Nov 2019, 15:55
by musher0
Bump one letter up in the Latin alphabet? I see:
dd = donvert and dopy. :lol:
whatever that means! :twisted:

Following a similar reasoning, conky is actually a donkey!!! :lol: Hee-haw!

Posted: Fri 08 Nov 2019, 22:33
by jafadmin
Burn_IT wrote:jfadmin No it doesn't.

The DD statement in JCL stands for Data Definition and has nothing whatsoever to do with copying.

The program IEBGENER is the thing that does the copying.
SYSUT1 is the source file
and SYSUT2 is the target file
in your example.
https://en.wikipedia.org/wiki/Dd_(Unix)#History

Posted: Fri 08 Nov 2019, 23:13
by p310don
I read somewhere it was data duplicate(or)

Posted: Fri 08 Nov 2019, 23:32
by Burn_IT
Read what I said!
I said IN JCL

The dd statement in JCL is used to link a logical filename in a program to a physical data stream somewhere in the real world.
It has nothing to do with what that data is used for, though it may tell the operating system what state to leave that data in when it is finished with it.

Posted: Sat 09 Nov 2019, 02:52
by jafadmin
Burn_IT wrote:Read what I said!
I said IN JCL

The dd statement in JCL is used to link a logical filename in a program to a physical data stream somewhere in the real world.
It has nothing to do with what that data is used for, though it may tell the operating system what state to leave that data in when it is finished with it.
http://ibmmainframes.com/about9267.html


.

Posted: Mon 11 Nov 2019, 13:58
by Burn_IT
And your point is??
In all those examples there is a program involved to do the copying.

Even if you do want to use JCL to do things like allocate space for a file or catalogue a file, you still have to have a "PGM" statement (an executable program).
The most used program for this is IEFBR14 which consists of just a return statement.

In those examples the program is the sort utility.

Posted: Thu 26 Mar 2020, 00:21
by 01101001b
mistfire wrote:DD

DUPLICATE
DISK
Somewhere I read it as "disk dump" :wink:

Posted: Thu 26 Mar 2020, 00:35
by Burn_IT
deleted as a repeat

Posted: Thu 26 Mar 2020, 04:11
by 01micko
Digressing somewhat but still on OT..

How many know what the .tar extension stands for?

Tape Archive.

Of course if you are over 35 or so and in IT or are a coder you knew this, no? 8)

Posted: Thu 26 Mar 2020, 09:21
by Leon
01micko wrote:How many know what the .tar extension stands for?

Tape Archive.

Of course if you are over 35 or so and in IT or are a coder you knew this, no? 8)
Or at least 35 or so ago starting in IT and has inserting tapes in tape drives of PDP (Programmed Data Processor)...

:D

Posted: Thu 26 Mar 2020, 14:39
by Burn_IT
I started in IT in 1966 - not that IT existed as such then.
Punch cards were the storage media most used, which led to favourite tales of Floor Sorts and Leicester Shuffles.

Posted: Fri 27 Mar 2020, 11:57
by Packetteer
Hi All
A friend of mine Joke was that he stated that he never numbered his
punch cards. This way if they ended up on the floor he could put them back
in any order


Best Regards
John

Posted: Fri 27 Mar 2020, 17:01
by rockedge
my very first computer program was line by line on punch cards...written in FORTRAN and ran on an IBM mainframe in 1974 at AVCO Lycoming, a gas turbine engine manufacturer. My dad was an engineer working on the AGT 1500 engine that eventually ended up in the Abrams M1A1 main battle tank.

He arranged that I could drop off the pack of cards in the correct order to the high priests (sysop's) who would at some point take my program from the queue and run it. Next day my dad brought home a printout of the results.

I was 13 years old and the program did not do much..more of a "Hello World" but it ran. Only the sysop's had direct access...the computer room was climate controlled high security area...no one could even look at it except those guys.

I later went to school to be a mainframe sysop and batch script programmer...but it was already the dawn of the new age and LAN's and the desktop computer workstation was on the horizon.