Answer the question
In order to leave comments, you need to log in
Answer the question
In order to leave comments, you need to log in
Do you have such a variable in the environment at all?
To begin with, add to the script
printenv
. In general, to begin with, type hostname or cat /etc/hostname in the console, perhaps the script is doing everything right.
Perhaps everything is simpler and he was trying to simply declare this variable
hm=$(hostname); echo $hm
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question