Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Can someone please explain the difference between these commands.

net view
net view /all
net view /domain
net view /all /domain
share|improve this question

migrated from Nov 25 '11 at 9:13

This question came from our site for information security professionals.

up vote 4 down vote accepted

From net help view:

C:\Users\shufler>net help view
The syntax of this command is:

[\\computername [/CACHE] | [/ALL] | /DOMAIN[:domainname]]

NET VIEW displays a list of resources being shared on a computer. When used
without options, it displays a list of computers in the current domain or

\\computername             Is a computer whose shared resources you want
                           to view.
/DOMAIN:domainname         Specifies the domain for which you want to
                           view the available computers. If domainname is
                           omitted, displays all domains in the local area
/CACHE                     Displays the offline client caching settings for
                           the resources on the specified computer
/ALL                             Displays all the shares including the $ shares

So let's look at each.

net view returns the computers in the current domain or network. This list will only show computers that have file and printer sharing enabled.
net view /all shows all shares available, including administrative shares like C$ and admin$
net view / will list all of the sharing computers in the domain
net view /all /domain shows all shares (regular and administrative) in the domain

I'm not currently connected to a domain so unfortunately I can't provide you with examples.

share|improve this answer
Wow didn't even notice the help command. I kept doing "net view ?" wasn't as detailed. – Mike Nov 25 '11 at 8:44
@Mike If you tried net /? you may have noticed the help option. Follow the rabbit hole from there. – Iszi Nov 25 '11 at 9:14
+1 great answer shufler – HaydnWVN Nov 25 '11 at 11:41
To be fair, NET is one of maybe a handful of Microsoft console applications that doesn't follow the same input model as other commands. Yes, NET /? shows HELP as an option, but you normally wouldn't expect an additional help system beyond /? for most cmd utilites. – shufler Nov 25 '11 at 12:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .