<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Ssh on SANJAY REGMI</title>
    <link>https://sanjayregmi.com/tags/ssh/</link>
    <description>Recent content in Ssh on SANJAY REGMI</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    
    <lastBuildDate>Thu, 15 Jan 2026 16:29:04 -0800</lastBuildDate><atom:link href="https://sanjayregmi.com/tags/ssh/index.xml" rel="self" type="application/rss+xml" />
    
    <item>
      <title>How to Get the Best Throughput - Both Upload and Download - From Remote Servers When Connected via Tailscale and Using Pfsense Firewall</title>
      <link>https://sanjayregmi.com/posts/how-to-get-the-best-throughput-both-upload-and-download-from-remote-servers-when-connected-via-tailscale-and-using-pfsense-firewall/</link>
      <pubDate>Thu, 15 Jan 2026 16:29:04 -0800</pubDate>
      
      <guid>https://sanjayregmi.com/posts/how-to-get-the-best-throughput-both-upload-and-download-from-remote-servers-when-connected-via-tailscale-and-using-pfsense-firewall/</guid>
      <description>&lt;p&gt;If you’ve had a VPS with Hetzner in Europe (very competitive hosting rates) and you’re a &lt;a href=&#34;https://sanjayregmi.com/tags/tailscale/&#34; &gt;Tailscale aficionado&lt;/a&gt; you’ve probably &lt;a href=&#34;https://sanjayregmi.com/posts/how-to-install-tailscale-on-freebsd/&#34; &gt;used Tailscale&lt;/a&gt; and been unhappy with upload/download speeds in kilobytes when connected via Tailscale over SSH. It turns out one reason for the low throughput is that you use &lt;a href=&#34;https://sanjayregmi.com/tags/pfsense/&#34; &gt;pfSense&lt;/a&gt; as your firewall, and it can be difficult for Tailscale to punch a hole through pfSense. As a result, it falls back to its DERP servers, which are shared resources for all Tailscale users and often have poor throughput. With that said, here’s a quick change to apply on pfSense to alleviate the problem.&lt;/p&gt;</description>
      
    </item>
    
    <item>
      <title>If You Are Constantly on SSH and Having to Run Long-Running Processes Then Use Tmux</title>
      <link>https://sanjayregmi.com/posts/if-you-are-constantly-on-ssh-and-having-to-run-long-running-processes-use-tmux/</link>
      <pubDate>Mon, 03 Nov 2025 21:14:57 -0800</pubDate>
      
      <guid>https://sanjayregmi.com/posts/if-you-are-constantly-on-ssh-and-having-to-run-long-running-processes-use-tmux/</guid>
      <description>&lt;p&gt;If you&amp;rsquo;re like me, always running ssh to connect to servers and having to run processes and wanting to know what you ran earlier in one combined session, run tmux. No backgrounding of commands, no using nohup, and even if the ssh session breaks, which most of the time it does if you&amp;rsquo;re running something that takes a long time, tmux is the best.&lt;/p&gt;</description>
      
    </item>
    
    <item>
      <title>Replacement for Ssh - Mosh (Mobile Shell) Is the Modern Secure Shell - use it starting today</title>
      <link>https://sanjayregmi.com/posts/replacement-for-ssh-mosh-mobile-shell-is-the-modern-secure-shell/</link>
      <pubDate>Tue, 12 Mar 2024 08:10:43 -0700</pubDate>
      
      <guid>https://sanjayregmi.com/posts/replacement-for-ssh-mosh-mobile-shell-is-the-modern-secure-shell/</guid>
      <description>&lt;p&gt;If you are a regular user of ssh, you&amp;rsquo;re aware of some of its issues:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;ssh breaks when there&amp;rsquo;s a disconnection and it doesn&amp;rsquo;t reconnect. I use tmux as a stopgap so I can go back to what I was doing.&lt;/li&gt;&#xA;&lt;li&gt;typing on ssh terminal when the remote server is faraway is downright painful because the response times are so slow. One has to wait for the characters to be acknowledged by the server.&lt;/li&gt;&#xA;&lt;li&gt;and when that time you want to hit a CTRL + C because you ran the RSYNC command wrong, it doesn&amp;rsquo;t accept Control C in time. Worse, the SSH terminal then breaks down.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Enter Mosh and it solves all the said problems and some more. It allows for:&lt;/p&gt;</description>
      
    </item>
    
    <item>
      <title>How to Install Tailscale on FreeBSD</title>
      <link>https://sanjayregmi.com/posts/how-to-install-tailscale-on-freebsd/</link>
      <pubDate>Thu, 15 Feb 2024 22:33:23 -0800</pubDate>
      
      <guid>https://sanjayregmi.com/posts/how-to-install-tailscale-on-freebsd/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://tailscale.com&#34;  target=&#34;_blank&#34; rel=&#34;noreferrer&#34;&gt;Tailscale.com&lt;/a&gt;&amp;rsquo;s download page doesn&amp;rsquo;t list if it&amp;rsquo;s available for FreeBSD. But it does work on FreeBSD (tested on Release 14). Here&amp;rsquo;s how:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Install the package: &lt;code&gt;pkg install tailscale&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;Edit &lt;code&gt;/etc/rc.conf&lt;/code&gt; to add &lt;code&gt;tailscaled_enable=&amp;quot;YES&amp;quot;&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;Run &lt;code&gt;service tailscaled start&lt;/code&gt;. If you get an error, reboot.&lt;/li&gt;&#xA;&lt;li&gt;After reboot, run &lt;code&gt;tailscale login&lt;/code&gt;. Grab the url, copy paste in a browser and approve the connection.&lt;/li&gt;&#xA;&lt;li&gt;You can now ssh into the machine from another &amp;rsquo;tailscaled&amp;rsquo; machine from within your LAN or outside your home/office.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&#xA;&lt;h2 class=&#34;relative group&#34;&gt;How to update Tailscale&#xA;    &lt;div id=&#34;how-to-update-tailscale&#34; class=&#34;anchor&#34;&gt;&lt;/div&gt;&#xA;    &#xA;    &lt;span&#xA;        class=&#34;absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none&#34;&gt;&#xA;        &lt;a class=&#34;text-primary-300 dark:text-neutral-700 !no-underline&#34; href=&#34;#how-to-update-tailscale&#34; aria-label=&#34;Anchor&#34;&gt;#&lt;/a&gt;&#xA;    &lt;/span&gt;&#xA;    &#xA;&lt;/h2&gt;&#xA;&lt;p&gt;Once installed, when you run the command &lt;code&gt;tailscale&lt;/code&gt; on FreeBSD as root, you get a list of all the commands. Use &lt;code&gt;tailscale update&lt;/code&gt; to update.&lt;/p&gt;</description>
      
    </item>
    
    <item>
      <title>How to configure SSH for a passwordless login into your remote machine</title>
      <link>https://sanjayregmi.com/posts/ssh-without-password/</link>
      <pubDate>Fri, 26 Jan 2024 21:44:06 -0800</pubDate>
      
      <guid>https://sanjayregmi.com/posts/ssh-without-password/</guid>
      <description>&lt;ul&gt;&#xA;&lt;li&gt;On local machine, run&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;div class=&#34;highlight-wrapper&#34;&gt;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;ssh-keygen&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;This creates two files &lt;code&gt;/.ssh/id_rsa.pub&lt;/code&gt; (public key) and &lt;code&gt;/.ssh/id_rsa&lt;/code&gt; (private key).&lt;/li&gt;&#xA;&lt;li&gt;Still on local machine, run&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;div class=&#34;highlight-wrapper&#34;&gt;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;ssh-copy-id remoteusername@remoteserver&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;This copies your public key to remote server.&lt;/li&gt;&#xA;&lt;li&gt;Now try doing ssh to remote machine, no password should be required.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&#xA;&lt;h4 class=&#34;relative group&#34;&gt;if ssh-copy-id fails&#xA;    &lt;div id=&#34;if-ssh-copy-id-fails&#34; class=&#34;anchor&#34;&gt;&lt;/div&gt;&#xA;    &#xA;    &lt;span&#xA;        class=&#34;absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none&#34;&gt;&#xA;        &lt;a class=&#34;text-primary-300 dark:text-neutral-700 !no-underline&#34; href=&#34;#if-ssh-copy-id-fails&#34; aria-label=&#34;Anchor&#34;&gt;#&lt;/a&gt;&#xA;    &lt;/span&gt;&#xA;    &#xA;&lt;/h4&gt;&#xA;&lt;p&gt;Sometimes, ssh-copy-id gives an error and doesn&amp;rsquo;t copy the files. In that case, use this one liner but replace the remoteuser and servername:&lt;/p&gt;</description>
      
    </item>
    
  </channel>
</rss>
