下载工具
cmake-3.23.0-rc3-macos10.10-universal.dmg
tuntap_20150118.tar.gz
https://codeload.github.com/meyerd/n2n/zip/refs/heads/master
编译
cd n2n_v2
mkdir build
cd build
cmake ..
make
执行
在云服务器上执行supernode
supernode -l 5000 -v -f
-l 指定服务端口
-v -f 调试模式
在本地执行edge
edge -a 10.0.0.10 -c lgy -k lgy -l 1.2.3.4:5000 -v -f
-a 指定的虚拟ip
-c 组名
-k 组密码 -K 可指定秘钥文件
-l supernode 地址加端口、v2版本可指定两个,高可用
遇到的问题和解决方法
- edge命令正确、运行成功但是ping不通VLAN内的主机;
答:检查edge版本与supernode版本是否一致;
2.edge运行总是open /dev/tap0失败,报错:
Unable to open any tap devices /dev/tap0 through /dev/tap254.
sudo也解决不了,按照提示打开关于macOS.md按提示执行
brew tap homebrew/cask
brew cask install tuntap
结果报错:
Follow the instructions here:
https://github.com/Homebrew/homebrew-cask#reporting-bugs
Warning: Unexpected method 'livecheck' called on Cask macrorecorder.
Follow the instructions here:
https://github.com/Homebrew/homebrew-cask#reporting-bugs
Error: Cask 'macrorecorder' definition is invalid: invalid 'depends_on macos' value: ">= :big_sur"
答:最后通过安装tuntap_20150118.tar.gz解决。
3. cmake报找不到openssl的文件
答:根据CMakeLists.txt中的提示执行
cmake -DOPENSSL_ROOT_DIR=/usr/local/opt/openssl ..
问题解决;
4.macos如何使用类似mstsc的方法远程Windows
答:安装Microsoft remote desktop for mac。
转载请注明来源:https://www.cnblogs.com/bugutian/
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· winform 绘制太阳,地球,月球 运作规律
· AI与.NET技术实操系列(五):向量存储与相似性搜索在 .NET 中的实现
· 超详细:普通电脑也行Windows部署deepseek R1训练数据并当服务器共享给他人
· 上周热点回顾(3.3-3.9)
· AI 智能体引爆开源社区「GitHub 热点速览」
2021-03-15 验证c++11里面的future是否是新开一个线程实现的异步