Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Net Shares

Status
Not open for further replies.

adiMasher

Programmer
Aug 31, 2001
144
US
I'm not a network admin so I don't know all the in's and outs of this stuff.... hopefully you guys know more tricks and stuff than the windows docs provide.

So here's what I'm looking to do. When I give the command "net share" it tells me c$, temp & so forth but I can't issue that command to look at what is all being shared on the other computers in the network.... yes I can use "net view" but that only lists the shared folders, and won't say if c$ is available.

Does anyone know how I can query a remote computer if it has c$ or more basically if it has network sharing turned on....

Thanks.
Martin
 
Well...you can always use 'net use g: \\remoteserver\c$' and you will find out quickly whether c$ exists. Between that and 'net view' you should be able to figure everything out. I think that 'net view' will only show what the remote system advertises as shares, and not the complete share list. This would be for security reasons.

A better way, if you have admin rights, is to use the Computer Management tool in the Administrative Tools to manage a remote system and look at its shares and share paths.

ShackDaddy
 
The C$ (and any other share named with a "$" at the end) are hidden shares, that are only used by administrators. They are there by default on win2k machines, but some users may have removed them.
 
You can tell if a system has network sharing turned on in at least two ways:

1) If it shows up in Network Neighborhood.
2) If it registers a (20h) record in the WINS database.

ShackDaddy
 
Thanks ShackDaddy,

I never would have thought of checking for 20h.

I used nbtstat -a servername and if file sharing is turned on you get a line that says something like
&quot;SERVERNAME <20> UNIQUE Registered&quot;

otherwise that line won't be there.

Thanks a ton, everyone

Martin
 
If you have the NT 4.0 Resource Kit, rmtshare.exe is the command you're looking for.

rmtshare \\servername

will list all of the share on the remote computer. You can also use this command to create shares on a remote computer. I'm not sure where this went in the Win2K RK if anyone knows the Win2k command please post it.
 
The W2K Resource Kit also has an app called Srvcheck. You would use it like &quot;srvcheck \\servername&quot;, and it will list the shares that exist on that system and the permissions assigned to the share. It doesn't show the hidden admin shares, but it does show other shares like &quot;print$,&quot; &quot;repl$,&quot; and &quot;connect$&quot;.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top