In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly explains "how to use Oxfs". The content in the article is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn how to use Oxfs.
When do you need a network file system?
Embedded students often use NFS to mount a directory on host to the development board, so that it can be compiled and built on host and run directly on the board, reducing manual copy operations.
When developing the website, after developing with IDE on host, and sending it to the online machine to run the test, using the network file system can faster reduce data synchronization and improve the development efficiency.
When the team uses a unified development organization to build the code, when the team uses the network file system to mount the development machine files to the local, you can easily use the easy-to-use graphical editor to write the code.
You need to use a network file system for a variety of reasons, but is your network fast enough? Can the network file system go any faster?
NFS or SSHFS?
The editor has used NFS and SSHF, and they are all very good. However, when the network conditions are not ideal, the stutter phenomenon is very obvious.
It is a poor experience to use graphical software to edit remote files when the network conditions are not ideal, especially if you use a heavyweight plug-in like oh my zsh to work in a remote directory.
There has been a comparison between NFS and SSHFS (http://www.admin-magazine.com/HPC/Articles/Sharing-Data-with-SSHFS) online, and SSHFS is really relatively good.
Until Oxfs was used, the stutter problem was finally alleviated:)
Oxfs introduction
Oxfs is a user-mode network file system similar to SSHFS, and the underlying data transfer is based on SFTP protocol.
Oxfs introduces an asynchronous refresh strategy to solve the stutter problem caused by the mismatch between the network speed and the user's operating file reading speed.
When Oxfs writes to a file, it first writes to the local cache file and submits an asynchronous update task to update the contents to the remote host.
Similarly, when reading a file, priority is given to reading from the local cache file.
Oxfs's data cache ends up on disk, and even if it is remounted, the history cache can still be used.
Similarly, Oxfs also introduces file attributes, directory structure Memory caching, and functionally aligns SSHFS.
It can be said that Oxfs is a better alternative to SSHFS:)
Oxfs usage
The installation of Oxfs is simple.
$pip install oxfs
The use of Oxfs is also very simple.
$mkdir remote$ sudo oxfs-s user@xxx.xxx.xxx.xxx-m remote-r / home/oxfs-p / tmp/oxfs
-s configure the address and user accessed by the remote host, requiring the SSH public key of the current machine to be configured on the remote host.
-m sets the local mount point.
-r sets the remote host directory to be mounted locally.
-p sets the Oxfs runtime working directory for data caching
Thank you for your reading, the above is the content of "how to use Oxfs", after the study of this article, I believe you have a deeper understanding of how to use Oxfs, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.