LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-14-2006, 05:05 AM   #1
knuff
LQ Newbie
 
Registered: Aug 2006
Posts: 2

Rep: Reputation: 0
shell command, computer name


Hi, is there a way to find out the computername in the shell. Something like ./me or something similar?

Thanks for your time.

Knuff
 
Old 08-14-2006, 05:12 AM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Hi,

And welcome to LQ!


hostname ?



Cheers,
Tink
 
Old 08-14-2006, 05:29 AM   #3
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387
Hi,

Or uname -n

And: Welcome!

Hope this helps.
 
Old 08-14-2006, 06:49 AM   #4
oskar
Senior Member
 
Registered: Feb 2006
Location: Austria
Distribution: Ubuntu 12.10
Posts: 1,142

Rep: Reputation: 49
or ifconfig


for network address that is.

welcome
 
Old 08-14-2006, 08:49 AM   #5
knuff
LQ Newbie
 
Registered: Aug 2006
Posts: 2

Original Poster
Rep: Reputation: 0
Hello, and thanks for fast replies. Im not able to execute ./hostname nor ./uname
 
Old 08-14-2006, 09:37 AM   #6
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387
Hi,

The ./ part is not needed, it even prevents finding the command(s). Your path setting (echo $PATH) is searched and the commands are found (both commands recide in /bin). If you use ./<command> only the current dir is looked at.

Hope this helps.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Is there a command to change your computer name?? lonecrow Linux - Newbie 3 03-30-2006 10:06 PM
Installation of Fedora on Computer with only Command.com on it ketansuri Linux - Newbie 4 12-08-2005 07:14 PM
Shuting computer down in bash shell zWaR Linux - Newbie 4 12-03-2005 01:22 PM
Turning off computer with a single command xuper Linux - Newbie 11 05-27-2005 12:41 PM
changing computer name in shell hamster001 Linux - Newbie 8 10-29-2003 06:12 PM


All times are GMT -5. The time now is 09:16 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration