How to use SeaFile to build a local private cloud disk and combine it with cpolar to achieve remote access

1 Introduction

Nowadays, there are more and more smart devices around us. Various smart phones, tablets, smart watches and digital cameras are all around us. The data that needs to be stored is also getting larger and larger. A photo taken by a mobile phone may be more than ten megabytes. Movies and videos are calculated on a G basis. The storage space of smart devices is also stretched. The most suitable computer that can store a large number of files is a home computer. However, home computers have the problem of being unable to access files and information anytime and anywhere. But with just a few simple steps, you can turn your home computer into a private cloud disk where you can access files anytime and anywhere. Today, the author will introduce to you how to use two simple software to turn your home computer into a safe and efficient private cloud disk.

2. SeaFile cloud disk settings

SeaFile is a self-hosted open source file synchronization and sharing server. Simply put, it is a personal cloud disk server. We can install SeaFile software on a home computer to turn the home computer into a data storage server, and then use Cpolar's intranet penetration function. Publish this data storage server to the public Internet to achieve our purpose of setting the home computer as a private cloud disk.

2.1 SeaFile installation environment settings

To install SeaFile software on the most common Windows system on home computers, we need to pay attention to two key points. The first is that SeaFile needs to build a necessary operating environment, that is, it needs to be installed. The Pythonsecond is that Python needs to choose version 2.7 and install it. Check the Path option.
Python is a relatively well-known software. You can download it from its official website ( https://www.python.org ), or you can search for the software name in a search engine to download it.

20230329090601

20230329090602

After the download is complete, click the file directly .exeto enter the installation program. It should be noted that 勾选Add python.exe to PATHthe options should be remembered during the installation process.

20230329090603

20230329090604

20230329090605

After the Python installation is complete, you can continue with the installation of SeaFile.

2.2 Download and install SeaFile

Next, we can install it seafile服务器端(special attention needs to be paid here, what is to be downloaded is the seafile server, not the seafile client). Since the author did not find the Windows version of seafile server download on the official website of seafile, I found one in the search engine ( https://www.jb51.net/softs/413008.html )

After the corresponding version of SeaFile server is downloaded, it needs to be decompressed to a folder on a certain disk. Here I decompress the file to the SeafileProgram folder on drive D (it should be noted that the path to the decompressed file should not be too long).

20230329090606

Then double-click the file in the unzipped folder run.bat, and the seafile server will automatically start installing.

20230329090607

After the installation program is completed, you can see that the seafile server has been started in the system tray of the Windows taskbar.

20230329090608

2.3 SeaFile configuration

Although the seafile server has been installed, seafile still lacks a user administrator at this time, and the Windows service has not yet been started, so we right-click the seafile server diagram in the tray, select 安装为Windows服务and 添加管理员账号options.

20230329090609

Next, we can complete these two settings according to the prompts of the seafile server. It should be noted that when setting up an administrator account, you need to enter a username in email format in order to successfully add an administrator.

20230329090610

After completing the settings of the administrator account and Windows service, we open the browser of the local computer and enter http://(seafile server所在的电脑IP地址):8000. In this example, we enter the address http://192.168.157.1:8000/ to open the seafile server web page. After entering your username and password, you can log in to the seafile web page.

20230329090611

20230329090612

At this time, we set up a server on the local computer that can provide shared file information for devices within the LAN. Visitors can check the shared file information through their respective user names and passwords. Next, what we have to do is use cpolar intranet penetration to create a public Internet address for the local seafile server, so that we can access the seafile server in the LAN anytime and anywhere, making seafile truly a private cloud disk.

3. cpolar intranet penetration

3.1 Cpolar download and installation

First, we need to install cpolar intranet penetration software on the computer with seafile server installed. We can find the cpolar software corresponding to the operating system version on cpolar's official website ( https://www.cpolar.com/ ).

20230329090613

The author is using the Windows operating system, so I chose the Windows version of cpolar to download.

20230329090614

After the Cpolar intranet penetration download is completed, unzip the downloaded compressed package and double-click .msithe file to enter the cpolar installation program. We Nextcan complete the installation directly.

20230329090615

20230329090616

3.2 Registration of Cpolar

Since cpolar will establish a separate data tunnel for each user and ensure the data security of each user through the user password and the token code generated individually by the user, we also need to register our own account on the official website. The registration procedure is also very simple. Just click on the upper right corner of the official website 用户注册to enter the new user registration interface.

20230329090617

20230329090618

After filling in the required information, you can click 创建账号to complete the new user registration.

3.3 Cpolar cloud settings

After completing the seafile settings, installing and registering cpolar, the remaining work is very simple. Just use cpolar intranet penetration to establish a data tunnel, and connect the entrance of the data tunnel generated by cpolar to the seafile server port of the local computer. It can form an intranet penetration data tunnel dedicated to seafile, allowing us to access the local seafile server anytime and anywhere.

Since the need to retrieve files from the private cloud disk may occur at any time, and I am too lazy to set up a data tunnel every day (the data tunnel created by the free version of cpolar will be reset every 24 hours), I upgraded cpolar to the VIP version so that I can Preserve data tunnels that can exist stably for a long time.

After upgrading cpolar to vip, we first log in to the cpolar cloud, find 预留the button on the left side of the customer's main interface, click to enter the reservation page, and find保留

20230329090619

20230329090620

In 保留二级子域名the fields, you need to make simple settings for several pieces of information.

  • 地区: The area where the server is located, just select the nearest one
  • 二级域名: Will eventually appear in the generated public Internet address as one of the identifiers of the network address
  • 描述: can be regarded as a description of this data tunnel, as long as it can be distinguished from other tunnels)

After completing these settings, you can click 保留the button on the right to retain this data tunnel.

20230329090621

If you no longer plan to use this data tunnel, you can click on the right xto delete it easily to save valuable tunnel quota.

20230329090622

3.4 Cpolar local settings

After completing the settings of cpolar cloud, half of the data tunnel that can penetrate the LAN is completed. Next, we return to the local computer and log in to the cpolar intranet penetration client (you can enter it in the browser localhost:9200or click the cpolar shortcut in the start menu)

20230329090623

After logging in to the cpolar client, click on the left side of the client's main interface 隧道管理- 创建隧道to enter the local tunnel creation page (if you want to create a temporary data tunnel that does not reset the address for 24 hours, you can set it directly here, without setting it blank on the cpolar official website) data tunnel).

On this page, you also need to make several information settings, which include:

1. 隧道名称– It can be regarded as cpolar’s ​​local tunnel information annotation, as long as it is convenient for us to distinguish;
2. 协议– Since Serv-U outputs a web page, the http protocol is selected here;
3. 本地地址– The local address is the seafile server website Output port number, so fill in the default port number 8000 of seafile server here;
4. 域名类型– Since we have reserved the data tunnel of the second-level subdomain name in the cpolar cloud and generated the public Internet second-level domain name of the seafile web page, so here We check "Second-level subdomain name" (if the reserved domain name is a custom domain name, check the custom domain name), and fill in the reserved second-level subdomain name in the "Sub Domain" column on the next line, in this example "seafile1". Of course, if you create a temporary data tunnel, just check "Random domain name" directly, and the cpolar client will generate the network address by itself without having to set it up in the cpolar cloud;
5. 地区- This line is the same as the setting in the cpolar cloud. It is the choice of server region. We can fill it in according to the actual place of use;

20230329090624

After completing the filling in the information required for the cpolar client to create a tunnel, you can click 创建the button at the bottom of the page to complete the data tunnel that penetrates the local LAN, allowing us to access the local seafile server on the public Internet.

After the tunnel is created, cpolar will automatically transfer to 隧道管理the - 隧道列表page. On this page, we can manage the created tunnel, such as starting, pausing, and deleting it. If we need to modify the information of this data tunnel, we can also do so here. Click the Edit button to enter the data tunnel information modification page.

20230329090625

4. Public network access test

In the last step, we click on the left side of the cpolar client 状态- 在线隧道列表to enter the online tunnel list page and obtain the public Internet access address that can connect to the local seafile server.

20230329090626

We only need to paste this address into the browser of other devices to access the seafile server.

20230329090627

Of course, we can also use this address to access the seafile server from various versions of seafile clients.

20230329090628

20230329090629

5 Conclusion

At this point, we have completed all operations of turning local seafile into a private cloud disk. We can freely penetrate the data tunnel through the intranet created by cpolar, easily access the seafile server in the LAN, and retrieve the required data from it. Information and documents.

Guess you like

Origin blog.csdn.net/m0_73879806/article/details/135345463
Recommended