I entered same command with a variable host. During 2nd time I entered blank space between host,= and $. Why it was trying to connect to a server ? Also, when I write like $(host name), I am getting error Host = not found: 3(NXDOMAIN) centos
There must not be any spaces between a variable name and the equation mark. When there are spaces, the variable name is interpreted as a command, in this case the command |
||||
|
hostname
? – Julie Pelletier yesterday