Home

Network Administration: Net Use Command

By
No items found.
Updated
2016-03-26 19:37:55
From the book
No items found.
Share
DNS For Dummies
Explore Book
Buy NowSubscribe on Perlego

In the Windows Server 2008 environment the Net Use command connects to or disconnects from a shared resource on another computer and maps the resource to a drive letter. Here’s the complete syntax:

net use [{<i>drive</i> | *}]
        [{<i>ComputerName</i><i>ShareName</i>]
        [{<i>Password</i> | *}]]
        [/user:[<i>DomainName</i>]<i>UserName</i>]
        [/savecred]
        [/smartcard]
        [{/delete | /persistent:{yes | no}}]

To set up a home directory, use this syntax:

net use [<i>drive</i> [/home[{<i>password</i> | *}] 
        [/delete:{yes | no}]]

And to control whether connections should be persistent, use this:

net use [/persistent:{yes | no}]

Here’s what the parameters do:

  • DeviceName: Specifies the drive letter. (Note that for a printer, you should specify a printer device such as LPT1: here instead of a drive letter.) If you specify an asterisk, Windows will determine what drive letter to use.

  • \ComputerNameShareName: The server and share name to connect to.

  • Password: The password needed to access the shared resource. If you use an asterisk, you’re prompted for the password.

  • User: Specifies the username to use for the connection.

  • Savecred: Saves the credentials for reuse later if the user is prompted for a password.

  • Smartcard: Specifies that the connection should use a smart card for authorization.

  • Delete: Deletes the specified connection. If you specify an asterisk (*), all network connections are canceled.

  • Persistent: Specifies whether connections should be persistent.

  • Home: Connects to the home directory.

To display all current connections, type net use with no parameters.

The following example shows how to create a persistent connection to a drive named Acct on a server named Server01, using drive K:

C:>net use k: \Server01Acct /persistent: yes

The following example drops the connection:

C:>net use k: /delete

About This Article

This article is from the book: 

No items found.

About the book author:

No items found.
No items found.