Mihomo/en: Difference between revisions

FuzzyBot (talk | contribs)
Updating to match new version of source page
 
FuzzyBot (talk | contribs)
Updating to match new version of source page
Tags: Mobile edit Mobile web edit
 
Line 1: Line 1:
<languages/>
<languages/>
'''[https://github.com/MetaCubeX/mihomo/tree/Alpha mihomo]''' <span lang="en" dir="ltr">(formerly known as clash-meta), is a widely-used anti-censorship proxy application.</span>
'''[https://github.com/MetaCubeX/mihomo/tree/Alpha mihomo]''' (formerly known as clash-meta), is a widely-used anti-censorship proxy application.


<span lang="en" dir="ltr">Enable mihomo service on NixOS:</span>
Enable mihomo service on NixOS:


<syntaxhighlight lang="nix">
<syntaxhighlight lang="nix">
Line 12: Line 12:
</syntaxhighlight>
</syntaxhighlight>


=== <span lang="en" dir="ltr">TUN Mode</span> ===
=== TUN Mode ===


<span lang="en" dir="ltr">NOTICE: The [https://search.nixos.org/options?channel=unstable&show=services.mihomo.tunMode&from=0&size=50&sort=relevance&type=packages&query=mihomo tunMode option] in NixOS module only grants necessary permissions for the service. To actually enable TUN, you need to edit the '''configFile'''. See [https://wiki.metacubex.one/config/inbound/listeners/tun/?h=tun official documentation].</span>
NOTICE: The [https://search.nixos.org/options?channel=unstable&show=services.mihomo.tunMode&from=0&size=50&sort=relevance&type=packages&query=mihomo tunMode option] in NixOS module only grants necessary permissions for the service. To actually enable TUN, you need to edit the '''configFile'''. See [https://wiki.metacubex.one/config/inbound/listeners/tun/?h=tun official documentation].


=== <span lang="en" dir="ltr">Troubleshooting</span> ===
=== Troubleshooting ===


<span lang="en" dir="ltr">If encountering issues with transparent proxy:</span>
If encountering issues with transparent proxy:
* <span lang="en" dir="ltr">Check kernel logs with <code>dmesg</code></span>
* Check kernel logs with <code>dmesg</code>
* <span lang="en" dir="ltr">If seeing massive "refuse" messages for specific network devices:</span>
* If seeing massive "refuse" messages for specific network devices:
** <span lang="en" dir="ltr">NixOS enables firewall by default, try disabling firewall</span>
** NixOS enables firewall by default, try disabling firewall
** <span lang="en" dir="ltr">If problem is solved, try sequentially:</span>
** If problem is solved, try sequentially:
*** <span lang="en" dir="ltr">Add tun device to <code>trustedInterfaces</code></span>
*** Add tun device to <code>trustedInterfaces</code>
*** <span lang="en" dir="ltr">Disable <code>checkReversePath</code></span>
*** Disable <code>checkReversePath</code>
* <span lang="en" dir="ltr">If seeing massive "refuse" messages for specific ports:</span>
* If seeing massive "refuse" messages for specific ports:
** <span lang="en" dir="ltr">Try allow the tproxy port in firewall if you're trying tproxy transparent proxy.</span>
** Try allow the tproxy port in firewall if you're trying tproxy transparent proxy.


== <span lang="en" dir="ltr">See also</span> ==
== See also ==


* [https://blog.nyaw.xyz/nixos-inwall-install <span lang="en" dir="ltr">NixOS installation and usage under a censored network (zh-cn)</span>]
* [https://blog.nyaw.xyz/nixos-inwall-install NixOS installation and usage under a censored network (zh-cn)]
 
[[Category:Applications]]
[[Category:Networking]]