Using SMB Protocol to Realize the Sharing of Device Files in LAN

References

Use SMB protocol to realize fast file transfer of iPad, iPhone and Windows in LAN

illustrate

Through the SMB protocol, the shared folder of the main device can be realized, and the shared folder can be accessed by external devices.
The main device here can be a windows system or a macOS system. External devices can be windows system, macOS system, ipad, iphone, etc.
The following takes windows as the main device and ipad as the external device for example

Step 1: [windows] Enable the SMB protocol

Method 1: Open the control panel (select large icons as the view method),
insert image description here
click to enable or disable windows features
insert image description here
to find SMB 1.0/CIFS 文件共享支持, and check it, then click OK and restart the computer.
insert image description here
Method Two:

Run command prompt as administrator
insert image description here

Step 2: [windows] Create a new user account

Purpose: This user account is used by other devices for subsequent login and viewing of shared files.

Open the Control Panel -> Click "User Accounts" -> Click "Manage Other Accounts"
insert image description here
and then click Add New User on the Computer, then you will jump to "Settings-Accounts-Family and Other Users", click Add Account and click
insert image description here
"My Account" There is no login information for this person", and the "personal data export permission" pops up, click agree and continue
insert image description here
insert image description here
Click "Add a user without a Microsoft account"
insert image description here
and enter the account name and password (be sure to remember)
insert image description here

Step 3: [windows] shared folder

For folders on the desktop, you need to use "Properties-Sharing-Sharing". For folders on the system disk (such as the folder of D disk), you only need to select "Advanced Sharing". If you use "Advanced Sharing" for desktop files, you will be prompted "The content of the folder is not available".

properties-share-share

Find the folder you want to share, right-click the property, click the "Share" tab, then click the "Share" button under the network path and
insert image description here
add the new user account you just created, and you can modify the user permission to "Read ” or “Read/Write,” then tap Share, then tap Done.

Properties - Sharing - Advanced Sharing

For the shared folder, right-click properties, click the "Sharing" tab, then click "Advanced Sharing" and check
insert image description here
"Share this folder", and then click Permissions
insert image description here
to select which users can view the shared folder by adding and deleting. Check Allow in the permissions to select which operations are allowed. Then click OK to complete the setup.
insert image description here

Step 4: [windows] View the IP address of the host computer sharing the file in the LAN

Windows system enters ipconfigto view the ip address at the command line
insert image description here

Step 5: [ipad] open the file, connect the main device (server)

First, you must ensure that the ipad and the main device are in the same LAN.
Then open the file on the ipad, click "connect to server"
insert image description here
and enter in the connection server smb://步骤4得到的IP地址(if the external device is a windows system, you don't need to bring smb), and click connect,
insert image description here
then enter the user name and password, click connect, and you can view the shared folder up.

Connection of other master devices and external devices

You can refer to the video: LAN sharing: With this setting, you can easily copy files from any computer.

Advanced operation: [External device windows] set windows credentials

Purpose: Every time you connect to the main device, you need to enter the ip address, user name and password. It will be a little troublesome. A more convenient way is to set windows credentials. Specifically:
1. For the shared folder, record the network path, such as \LAPTOP-GH5FHBIJ\myshare
insert image description here
2. On the external device windows computer, open the control panel, click user account, then click "manage your credentials", and then click "Windows Credentials", and then click "Add Windows Credentials"
insert image description here
and then enter the network path, the local user name and password established by the master device, and then click OK.
insert image description here
Find My Computer, click Network (to enable network discovery and file sharing), then enter the network path of the shared folder in the address bar, and press Enter to see the shared folder.

Right-click the folder, click "Map Network Drive", and then click Finish. You can view the shared folder on My Computer.

important

1. To view shared files on external devices, you must log in with the created user name and password. An external device must correspond to a user account. If there are multiple devices, multiple user accounts are required.
2. When a user account is being logged in by a device and accessing shared files, other devices cannot log in to the server through the user account. The device in front needs to log out of the "pop-up" user account, and the device in the back can log in to the server through this user account.
3. If you cannot connect to the server through an external device, the possible reasons are:

  • The name of the user account cannot be passed (it is recommended to use plain English)

4. When the external device is connected to the server, if a new folder is shared at this time, the external device needs to log in to the server again to view the new shared folder.

Supongo que te gusta

Origin blog.csdn.net/zhangyifeng_1995/article/details/128816255
Recomendado
Clasificación