Earlier quoted context omitted.
More generally, type ~ as an escape sequence. For example, type ~^Z to put a session in the background. Similarly, type ~~ to send an escape sequence in an inner session, etc...
... There's a program called SSH to get to another CPU. Tilde is the escape, it's doubled to send it through, And "quit" is tilde-. I think you know how the rest goes...
What typing ^D does on Unix (2009)
131–140 of 162 posts
Re: What typing ^D does on Unix (2009)
#132Earlier quoted context omitted.
More generally, type ~ as an escape sequence. For example, type ~^Z to put a session in the background. Similarly, type ~~ to send an escape sequence in an inner session, etc...
... There's a program called SSH to get to another CPU. Tilde is the escape, it's doubled to send it through, And "quit" is tilde-. I think you know how the rest goes...
Re: What typing ^D does on Unix (2009)
#133As a corollary, typing ^D twice on a non-empty line will also send EOF on the input, allowing you to provide a program with input not ending with \n from the command line. I knew about this behavior, but not why it worked, but this article's explanation clarifies this behavior as well. The first ^D terminates the read() call, passing the line so far, without terminating \n, to the program. The second causes read() to…
I asked about this on StackOverflow a few years ago, and got a great answer. http://stackoverflow.com/questions/15666923/sys-stdin-does-n...
Re: What typing ^D does on Unix (2009)
#134Earlier quoted context omitted.
How did modems deal with pluses in data? Was there a way to escape the escape sequence, or was there just an ATSnnn or similar sequence to disable escapes?
There were a bunch of different mechanisms depending on vendor. Some required a specific time interval in between the + signs, so that typing very slowly, or instantly, wouldn't trigger the escape. Some vendors had bugs in which when +++ appeared as part of the incoming data it would also trigger the firmware escape. And of course programmable terminals had hilarious exploits where you'd get someone to run your progr…
So do they do scheduled collections of failed units? Or just let them sit there indefinitely?
Re: What typing ^D does on Unix (2009)
#135Earlier quoted context omitted.
There were a bunch of different mechanisms depending on vendor. Some required a specific time interval in between the + signs, so that typing very slowly, or instantly, wouldn't trigger the escape. Some vendors had bugs in which when +++ appeared as part of the incoming data it would also trigger the firmware escape. And of course programmable terminals had hilarious exploits where you'd get someone to run your progr…
> "let it sit in the rack" So do they do scheduled collections of failed units? Or just let them sit there indefinitely?
For most of the SMB clients I have, I don't build new servers any longer. I can buy rackmount servers pulled out of a data center that are a few years old at about 1/3 the price. I just put new disks in them and a new OS.
Re: What typing ^D does on Unix (2009)
#136It's so beautiful. I think I'm going to cry :)
Re: What typing ^D does on Unix (2009)
#137Earlier quoted context omitted.
Fun trick: If somebody is watching you type in your login password or SSH pubkey password, spaz wildly on the keyboard, frantically typing random characters, and then hit ^U and type in your real password. Then you give them a puzzled look once you successfully log in as if nothing out of the ordinary just happened and say something like "What, don't you have a sufficiently complex password?".
As long as you don't hit space you can do the same thing with ^W, as ^W will clear out the last 'word'. I use it all the time at password prompts, and more comfortable to hit than ^U.
Re: What typing ^D does on Unix (2009)
#138Neat. So when my terminal is spewing output because I ran "cat massivefile" instead of "cat massivefile | head", I can hit ctrl-D to stop it instead of repeatedly hitting ctrl-C and despairing.
No, thats what ctrl-s and ctrl-q are for. Here's the rest in one place: eof VEOF EOF character eol VEOL EOL character eol2 VEOL2 EOL2 character erase VERASE ERASE character erase2 VERASE2 ERASE2 character werase VWERASE WERASE character intr VINTR INTR character kill VKILL KILL character quit VQUIT QUIT character susp VSUSP SUSP character start VSTART START character stop VSTOP STOP character dsusp VDSUSP DSUSP chara…
Re: What typing ^D does on Unix (2009)
#139I wish articles like this would say what ^D means. I remember when I was new to Unix it took me a while to realize that I wasn't supposed to type a literal caret (^) followed by a D. For reference it means Ctrl+D, unless you you have a strange keyboard from Sun or something.
I just tried to search for it as if I didn't know and it was hard. Maybe wikipedia should describe that ^ is common representation among first lines, not in details section. Also macOS (former osx) uses this symbol everywhere: http://www.macinstruct.com/images/command.png
Re: What typing ^D does on Unix (2009)
#140Directly after reading the title the question "what does ^D do" was fired at a Old Unix Beard friend of Mine who happens to be here for coffee. Instant reply Without any latency: "It originally was meant to terminate the Tape drive"
[citation needed] I suspect they're misremembering what the T in EOT stands for.