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 |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
02-05-2008, 01:54 PM
|
#1
|
Member
Registered: Jun 2004
Location: Ireland
Distribution: Zorin 6
Posts: 589
Rep:
|
basic commands
Hi, I need a quick answer and hope no one minds providing this to my doing some serious reading...
What is the the Linux equivalent to device manager to get a listing of all attached devices...Is there such a thing? Or do devices get listed in different directories according to their types. I.e. usb, ide, pci etc...
I would also be grateful for some networking commands such as linux's version of
ipconfig
netstat
netsh
The only network command that works with linux and windoz is ping.
Many thanks in advance
|
|
|
02-05-2008, 01:57 PM
|
#2
|
Moderator
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,982
|
Hi,
Not to be smart but you could search LQ or google and find that this has been asked numerous times.
You will find several references in my sig below.
Last edited by onebuck; 02-05-2008 at 05:50 PM.
|
|
|
02-05-2008, 01:59 PM
|
#3
|
Senior Member
Registered: Jun 2003
Location: California
Distribution: Slackware
Posts: 1,181
Rep:
|
How about lsusb (USB), lspci (PCI), and mount (IDE/SATA/Serial)?
I did a search here at LQ.org for "ipconfig" and found literally hundreds of threads all describing the linux equivalent -- ifconfig
Take a look around this site; there are plenty of resources available.
|
|
|
02-05-2008, 02:04 PM
|
#4
|
Member
Registered: Oct 2007
Location: New York City
Distribution: Gentoo, FC
Posts: 133
Rep:
|
for easy device info:
dmesg | grep whateveryouarelookingfor
also if you just plug a USB device into your machine and hit dmesg it will show you which device it will associate with:
(Just examples)
/dev/sdb1 2 3 4 etc for HD/Flash Drives
/dev/sg1 2 3 4 etc for Input Devices
Networking commands:
ipconfig -> ifconfig
man ifconfig will explain how to work with the command
netstat -> netstat
-weisso
|
|
|
02-05-2008, 02:19 PM
|
#5
|
LQ Veteran
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809
|
for hardware: lshw
for Linux applications: man -k <keyword>
|
|
|
02-05-2008, 04:22 PM
|
#6
|
Member
Registered: Jun 2004
Location: Ireland
Distribution: Zorin 6
Posts: 589
Original Poster
Rep:
|
That was great thank you all.
A question regarding the ifconfig command. I run only as root user and while it seems to give a lot more info than in windows I cannot see the gateway address.
Link encap:Ethernet HWaddr 00:10:A4:80:3C:7B
inet addr:192.168.0.2 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::210:a4ff:fe80:3c7b/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:46057 errors:0 dropped:0 overruns:0 frame:0
TX packets:45096 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:38308925 (36.5 MiB) TX bytes:3037352 (2.8 MiB)
Interrupt:11 Base address:0x1000
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:64 errors:0 dropped:0 overruns:0 frame:0
TX packets:64 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:4940 (4.8 KiB) TX bytes:4940 (4.8 KiB)
Regarding device manager, as suspected in Linux there deos't seem one specific locatiion where all device are listed. I.e. different location for different device types...?
|
|
|
02-05-2008, 04:34 PM
|
#7
|
LQ Addict
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian stable
Posts: 5,908
|
I strongly urge you to get out of the habit of loging in as root. That's a very serious breach of security. When you log in as root, a careless command from you can trach the system. You also leave your system wide open to attack when connected to the internet.
Start loging in as normal user, and learn to use the su and sudo commands to gain temporary root authority to make configurations, install software, etc, where root authority is needed.
|
|
|
02-05-2008, 04:43 PM
|
#8
|
Member
Registered: Jun 2004
Location: Ireland
Distribution: Zorin 6
Posts: 589
Original Poster
Rep:
|
Thanks for that. But what about the earlier question? I.e. why i dont see the gateway address using ifconfig?
|
|
|
02-05-2008, 05:03 PM
|
#9
|
Member
Registered: Jun 2004
Location: Ireland
Distribution: Zorin 6
Posts: 589
Original Poster
Rep:
|
lshw command
Quote:
Originally Posted by pixellany
for hardware: lshw
for Linux applications: man -k <keyword>
|
this command seems to be disto specific. In my PC Linux it says "command not found"...
even as root user..
|
|
|
02-05-2008, 05:06 PM
|
#10
|
Member
Registered: Feb 2005
Distribution: Ubuntu, CentOS
Posts: 585
Rep:
|
How about the route command?
That works on my distros.
|
|
|
02-05-2008, 05:57 PM
|
#11
|
Moderator
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,982
|
Hi,
Quote:
Originally Posted by siawash
Thanks for that. But what about the earlier question? I.e. why i dont see the gateway address using ifconfig?
|
To get the routing table; 'route -n'.
As I stated before my sig has several command line guides. The first to links are for ways to assist you in posting then the next two are good command and system guides.
|
|
|
02-05-2008, 06:00 PM
|
#12
|
Moderator
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,982
|
Hi,
Quote:
Originally Posted by siawash
this command seems to be disto specific. In my PC Linux it says "command not found"...
even as root user..
|
Not distribution specific. 'man man';
Quote:
excerpt from 'man man'
-k Equivalent to apropos.
|
'man' is your friend.
|
|
|
02-05-2008, 06:46 PM
|
#13
|
Member
Registered: Jan 2006
Distribution: Ubuntu 9.04, Fedora 10
Posts: 76
Rep:
|
Quote:
Originally Posted by bigrigdriver
I strongly urge you to get out of the habit of loging in as root. That's a very serious breach of security. When you log in as root, a careless command from you can trach the system. You also leave your system wide open to attack when connected to the internet.
Start loging in as normal user, and learn to use the su and sudo commands to gain temporary root authority to make configurations, install software, etc, where root authority is needed.
|
And to think, when I first started using Linux, Slackware specifically, I was always logged in as root! I never actually made a second account. However, it was on an old laptop that didn't have an ethernet adapter, and thus was standalone, so no problems from the internet, and I really didn't want to keep having to su all the time to mount a drive, shut down the machine, etc. That, and I was learning, and the best way to learn is to make mistakes! (Note: I never trashed the system as root, I got enough of a handle before I learned how to do rm -rf /)
When I got it installed on my desktop, however, I almost instantly stopped using root for everything, and started picking up some security practices.
|
|
|
All times are GMT -5. The time now is 07:20 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|