• 0 Posts
  • 14 Comments
Joined 1 year ago
cake
Cake day: June 13th, 2023

help-circle

  • start with basics:

    • install iperf on every device you can between an external device and your internal host(s) and use it to find any bottlenecks
    • use tools like tcpdump to analyze packets flowing over the network. you can often find surprising results this way
    • start with a simple test best (again, iperf) with the most simple config (no nginx etc) and add the complexity of your config bit by bit until the issue returns








  • assuming you have a GNU toolchain you can use the find command like so:

    find . -type f -executable -exec sh -c '
    case $( file "$1" ) in (*Bourne-Again*) exit 0; esac
    exit 1' sh {} \; -print0 | xargs -0 -I{} cp {} target/
    

    This first finds all executable files in the current directory (change the “.” arg in find to search other dirs), uses the file command to test if it’s a bash file, and if it is, pipes the file name to xargs which calls cp on each file.

    note: if “target” is inside the search directory you’ll get output from cp that it skipped copying identical files. this is because find will find them a free you copy them so be careful!

    note 2: this doesn’t preserve the directory structure of the files, so if your scripts are nested and might have duplicate names, you’ll get errors.



  • you need to look at the routing tables on your computer. these tables store the prioritized rules for how packets leave your host machine.

    it might be that something is adding rules, or, there is some overly broad rule taking priority (like a rule that says all 10.0.0.0/8 traffic go to your home router over 192.168.69.0/24, etc)

    it’s also suspect that you can reach the NAS over the 1gb card. That to me means one of two things:

    1. something is not actually using the IP you’ve configured in your fstab and is using some IP that is on the 1gb interface
    2. you have some weird network routes configured that is leading to this issue. if 10.42.69.0/24 is accessible over the 192.168.69.0/24 network, then you might need to create a static route explicitly telling your OS to send packets out the 40gb card

    ultimately, i suggest you run something like tcpdump or wireshark on your computer (ideally on the NAS too) so you can start to visualize how the packets are being addressed and transferred over your networks.

    sincerely, a fellow 10.0.69.0/24 enjoyer


  • no, and that’s be a pretty bad idea, you’re opening up all your internal hosts to the public internet.

    a VPN is specifically designed to keep all your internal hosts off the public internet. When you authenticate with the VPN server the remote device you are using effectively “joins” the internal network, using the VPN to act like a tunnel between you and your network.

    it has the benefits of better security as well as the fact that once you set it up, you can access any services you host, not just HTTP ones.