<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="/default.xsl"?>
<fr:tree xmlns:fr="http://www.forester-notes.org" xmlns:html="http://www.w3.org/1999/xhtml" xmlns:xml="http://www.w3.org/XML/1998/namespace" root="false" base-url="/">
  <fr:frontmatter>
    <fr:authors>
      <fr:author>
        <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
      </fr:author>
    </fr:authors>
    <fr:date>
      <fr:year>2018</fr:year>
      <fr:month>8</fr:month>
      <fr:day>31</fr:day>
    </fr:date>
    <fr:date>
      <fr:year>2025</fr:year>
      <fr:month>7</fr:month>
      <fr:day>15</fr:day>
    </fr:date>
    <fr:uri>https://xw.is/001B/</fr:uri>
    <fr:display-uri>001B</fr:display-uri>
    <fr:route>/001B/</fr:route>
    <fr:title text="Linux › Fedora Linux Post Install Steps"><fr:link href="/linux-index/" title="Linux" uri="https://xw.is/linux-index/" display-uri="linux-index" type="local">Linux</fr:link> › Fedora Linux Post Install Steps</fr:title>
  </fr:frontmatter>
  <fr:mainmatter>
    <fr:tree show-metadata="false">
      <fr:frontmatter>
        <fr:authors>
          <fr:author>
            <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
          </fr:author>
        </fr:authors>
        <fr:date>
          <fr:year>2018</fr:year>
          <fr:month>8</fr:month>
          <fr:day>31</fr:day>
        </fr:date>
        <fr:date>
          <fr:year>2025</fr:year>
          <fr:month>7</fr:month>
          <fr:day>15</fr:day>
        </fr:date>
        <fr:title text="Introduction">Introduction</fr:title>
      </fr:frontmatter>
      <fr:mainmatter>
        <html:p>Everything on this page needs to be done as root unless otherwise specified, so <fr:link href="https://www.sudo.ws/docs/man/1.8.15/sudo.man/" type="external">sudo(8)</fr:link> to root.</html:p>
        <html:pre>sudo -i</html:pre>
      </fr:mainmatter>
    </fr:tree>
    <fr:tree show-metadata="false">
      <fr:frontmatter>
        <fr:authors>
          <fr:author>
            <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
          </fr:author>
        </fr:authors>
        <fr:date>
          <fr:year>2018</fr:year>
          <fr:month>8</fr:month>
          <fr:day>31</fr:day>
        </fr:date>
        <fr:date>
          <fr:year>2025</fr:year>
          <fr:month>7</fr:month>
          <fr:day>15</fr:day>
        </fr:date>
        <fr:title text="Cloud Init">Cloud Init</fr:title>
      </fr:frontmatter>
      <fr:mainmatter>
        <html:p>If your install uses cloud-init (e.g. Amazon EC2) do the following:</html:p>
        <fr:tree show-metadata="false">
          <fr:frontmatter>
            <fr:authors>
              <fr:author>
                <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
              </fr:author>
            </fr:authors>
            <fr:date>
              <fr:year>2018</fr:year>
              <fr:month>8</fr:month>
              <fr:day>31</fr:day>
            </fr:date>
            <fr:date>
              <fr:year>2025</fr:year>
              <fr:month>7</fr:month>
              <fr:day>15</fr:day>
            </fr:date>
            <fr:title text="Set hostname">Set hostname</fr:title>
          </fr:frontmatter>
          <fr:mainmatter>
            <html:pre>
echo 'preserve_hostname: yes' &gt;/etc/cloud/cloud.cfg.d/55-preseve-hostname.cfg
echo 'eden.mgk.ro' &gt;/etc/hostname
reboot</html:pre>
          </fr:mainmatter>
        </fr:tree>
        <fr:tree show-metadata="false">
          <fr:frontmatter>
            <fr:authors>
              <fr:author>
                <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
              </fr:author>
            </fr:authors>
            <fr:date>
              <fr:year>2018</fr:year>
              <fr:month>8</fr:month>
              <fr:day>31</fr:day>
            </fr:date>
            <fr:date>
              <fr:year>2025</fr:year>
              <fr:month>7</fr:month>
              <fr:day>15</fr:day>
            </fr:date>
            <fr:title text="Enable IPv6">Enable IPv6</fr:title>
          </fr:frontmatter>
          <fr:mainmatter>
            <html:pre>
cat &lt;&lt;EOF &gt;/etc/cloud/cloud.cfg.d/56-custom-networking.cfg
network:
  version: 1
  config:
  - type: physical
    name: eth0
    subnets:
      - type: dhcp
      - type: dhcp6
EOF
reboot</html:pre>
          </fr:mainmatter>
        </fr:tree>
        <fr:tree show-metadata="false">
          <fr:frontmatter>
            <fr:authors>
              <fr:author>
                <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
              </fr:author>
            </fr:authors>
            <fr:date>
              <fr:year>2018</fr:year>
              <fr:month>8</fr:month>
              <fr:day>31</fr:day>
            </fr:date>
            <fr:date>
              <fr:year>2025</fr:year>
              <fr:month>7</fr:month>
              <fr:day>15</fr:day>
            </fr:date>
            <fr:title text="Scaleway">Scaleway</fr:title>
          </fr:frontmatter>
          <fr:mainmatter>
            <html:p>If you're on a braindead platform like <fr:link href="https://www.scaleway.com/" type="external">Scaleway</fr:link>, you might also need to disable this:</html:p>
            <html:pre>systemctl disable scw-set-hostname</html:pre>
          </fr:mainmatter>
        </fr:tree>
      </fr:mainmatter>
    </fr:tree>
    <fr:tree show-metadata="false">
      <fr:frontmatter>
        <fr:authors>
          <fr:author>
            <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
          </fr:author>
        </fr:authors>
        <fr:date>
          <fr:year>2018</fr:year>
          <fr:month>8</fr:month>
          <fr:day>31</fr:day>
        </fr:date>
        <fr:date>
          <fr:year>2025</fr:year>
          <fr:month>7</fr:month>
          <fr:day>15</fr:day>
        </fr:date>
        <fr:title text="Update the software">Update the software</fr:title>
      </fr:frontmatter>
      <fr:mainmatter>
        <html:pre>dnf -y upgrade-minimal
reboot</html:pre>
      </fr:mainmatter>
    </fr:tree>
    <fr:tree show-metadata="false">
      <fr:frontmatter>
        <fr:authors>
          <fr:author>
            <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
          </fr:author>
        </fr:authors>
        <fr:date>
          <fr:year>2018</fr:year>
          <fr:month>8</fr:month>
          <fr:day>31</fr:day>
        </fr:date>
        <fr:date>
          <fr:year>2025</fr:year>
          <fr:month>7</fr:month>
          <fr:day>15</fr:day>
        </fr:date>
        <fr:title text="Create a user">Create a user</fr:title>
      </fr:frontmatter>
      <fr:mainmatter>
        <html:p>Create a user with a locked password that can then do passwordless <fr:link href="https://www.sudo.ws/docs/man/1.8.15/sudo.man" type="external">sudo(8)</fr:link>:</html:p>
        <html:pre>useradd -c 'Aram Hăvărneanu' -G wheel,users -m -s /bin/bash -U aram
passwd -l aram</html:pre>
        <html:p>Enable passwordless sudo for the wheel group:</html:p>
        <html:pre><![CDATA[echo '%wheel ALL=(ALL) NOPASSWD:ALL' > /etc/sudoers.d/91-wheel-no-password]]></html:pre>
        <fr:tree show-metadata="false">
          <fr:frontmatter>
            <fr:authors>
              <fr:author>
                <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
              </fr:author>
            </fr:authors>
            <fr:date>
              <fr:year>2018</fr:year>
              <fr:month>8</fr:month>
              <fr:day>31</fr:day>
            </fr:date>
            <fr:date>
              <fr:year>2025</fr:year>
              <fr:month>7</fr:month>
              <fr:day>15</fr:day>
            </fr:date>
            <fr:title text="SSH">SSH</fr:title>
          </fr:frontmatter>
          <fr:mainmatter><html:p>For <fr:link href="/ssh.1" title="ssh(1)" uri="https://xw.is/ssh.1" display-uri="ssh.1" type="local">ssh(1)</fr:link> access, first use <fr:link href="https://man7.org/linux/man-pages/man1/su.1.html" type="external">su(1)</fr:link> to switch from root to the user:</html:p><html:pre>su - aram</html:pre><html:p>And then populate the <fr:link href="/ssh-keys/" title="OpenSSH › Public SSH Keys" uri="https://xw.is/ssh-keys/" display-uri="ssh-keys" type="local">ssh keys</fr:link>:</html:p>
  <html:pre>
mkdir -p $HOME/.ssh
chmod 700 $HOME/.ssh
cat &lt;&lt;EOF &gt;&gt;$HOME/.ssh/authorized_keys
<![CDATA[ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBHRJsbKlE9QWIQnC1YQPHV8C6cIx32Fjju7VQaKI67TPPm+FySrbJPsM6j4zm9IobTCQ0YOtVmlvXYlRtKdHm0I= pkcs11:id=%62%31%39%32%66%32%33%31%32%66%65%36%66%33%64%37;token=ssh;manufacturer=STMicro;serial=0000000000000000%0D%04?module-path=/usr/lib64/pkcs11/libtpm2_pkcs11.so aram@silverleaf.local
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHwq6SeyHhRRtiMmsBABHYgwqaOwwgBZEMgrRfoSpvzz aram@horizon.local
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMRc0UWKrFpCv/EOUo2jpEQt+C/pa0tc1rUWKgjbKTp7 aram@edengate.local
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPsg+utDc9GRb/n91r0j5vFsn+gVYPawpEbaNCuIhYmE aram@z800.mgk.ro]]>
EOF
chmod 644 $HOME/.ssh/authorized_keys
sort -u -o $HOME/.ssh/authorized_keys $HOME/.ssh/authorized_keys</html:pre>
</fr:mainmatter>
        </fr:tree>
      </fr:mainmatter>
    </fr:tree>
    <fr:tree show-metadata="false">
      <fr:frontmatter>
        <fr:authors>
          <fr:author>
            <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
          </fr:author>
        </fr:authors>
        <fr:date>
          <fr:year>2018</fr:year>
          <fr:month>8</fr:month>
          <fr:day>31</fr:day>
        </fr:date>
        <fr:date>
          <fr:year>2025</fr:year>
          <fr:month>7</fr:month>
          <fr:day>15</fr:day>
        </fr:date>
        <fr:title text="Enable NTP service">Enable NTP service</fr:title>
      </fr:frontmatter>
      <fr:mainmatter>
        <html:p>If not already enabled, enable NTP:</html:p>
        <html:pre>systemctl enable --now ntpd.service</html:pre>
      </fr:mainmatter>
    </fr:tree>
    <fr:tree show-metadata="false">
      <fr:frontmatter>
        <fr:authors>
          <fr:author>
            <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
          </fr:author>
        </fr:authors>
        <fr:date>
          <fr:year>2018</fr:year>
          <fr:month>8</fr:month>
          <fr:day>31</fr:day>
        </fr:date>
        <fr:date>
          <fr:year>2025</fr:year>
          <fr:month>7</fr:month>
          <fr:day>15</fr:day>
        </fr:date>
        <fr:title text="Install packages">Install packages</fr:title>
      </fr:frontmatter>
      <fr:mainmatter>
        <html:p>For home installations you might want to install avahi:</html:p>
        <html:pre>dnf install nss-mdns avahi
systemctl enable --now avahi-daemon.service</html:pre>
        <html:p>For development systems you might want to install:</html:p>
        <html:pre>dnf -y groupinstall 'Development Tools'
dnf -y install rsync clang clang-tools-extra gcc-go golang</html:pre>
      </fr:mainmatter>
    </fr:tree>
  </fr:mainmatter>
  <fr:backmatter>
    <fr:tree show-metadata="false" hidden-when-empty="true">
      <fr:frontmatter>
        <fr:authors />
        <fr:title text="References">References</fr:title>
      </fr:frontmatter>
      <fr:mainmatter />
    </fr:tree>
    <fr:tree show-metadata="false" hidden-when-empty="true">
      <fr:frontmatter>
        <fr:authors />
        <fr:title text="Context">Context</fr:title>
      </fr:frontmatter>
      <fr:mainmatter />
    </fr:tree>
    <fr:tree show-metadata="false" hidden-when-empty="true">
      <fr:frontmatter>
        <fr:authors />
        <fr:title text="Backlinks">Backlinks</fr:title>
      </fr:frontmatter>
      <fr:mainmatter />
    </fr:tree>
    <fr:tree show-metadata="false" hidden-when-empty="true">
      <fr:frontmatter>
        <fr:authors />
        <fr:title text="Related">Related</fr:title>
      </fr:frontmatter>
      <fr:mainmatter>
        <fr:tree show-metadata="true" expanded="false" toc="false" numbered="false">
          <fr:frontmatter>
            <fr:authors />
            <fr:uri>https://xw.is/ssh.1</fr:uri>
            <fr:display-uri>ssh.1</fr:display-uri>
            <fr:route>/ssh.1</fr:route>
            <fr:title text="ssh(1)">ssh(1)</fr:title>
            <fr:taxon>Manual</fr:taxon>
            <fr:meta name="external">https://man.openbsd.org/ssh.1</fr:meta>
          </fr:frontmatter>
          <fr:mainmatter>
            <html:p>OpenSSH remote login client.</html:p>
          </fr:mainmatter>
        </fr:tree>
        <fr:tree show-metadata="true" expanded="false" toc="false" numbered="false">
          <fr:frontmatter>
            <fr:authors>
              <fr:author>
                <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
              </fr:author>
            </fr:authors>
            <fr:date>
              <fr:year>2025</fr:year>
              <fr:month>7</fr:month>
              <fr:day>15</fr:day>
            </fr:date>
            <fr:uri>https://xw.is/ssh-keys/</fr:uri>
            <fr:display-uri>ssh-keys</fr:display-uri>
            <fr:route>/ssh-keys/</fr:route>
            <fr:title text="OpenSSH › Public SSH Keys"><fr:link href="/ssh-index/" title="OpenSSH" uri="https://xw.is/ssh-index/" display-uri="ssh-index" type="local">OpenSSH</fr:link> › Public SSH Keys</fr:title>
          </fr:frontmatter>
          <fr:mainmatter>
            <fr:tree show-metadata="false">
              <fr:frontmatter>
                <fr:authors>
                  <fr:author>
                    <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
                  </fr:author>
                </fr:authors>
                <fr:date>
                  <fr:year>2025</fr:year>
                  <fr:month>7</fr:month>
                  <fr:day>15</fr:day>
                </fr:date>
                <fr:title text="SSH Keys">SSH Keys</fr:title>
              </fr:frontmatter>
              <fr:mainmatter>
                <fr:tree show-metadata="false">
                  <fr:frontmatter>
                    <fr:authors>
                      <fr:author>
                        <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
                      </fr:author>
                    </fr:authors>
                    <fr:date>
                      <fr:year>2025</fr:year>
                      <fr:month>7</fr:month>
                      <fr:day>15</fr:day>
                    </fr:date>
                    <fr:title text="Authentication">Authentication</fr:title>
                  </fr:frontmatter>
                  <fr:mainmatter><html:p>These are the public SSH keys that I use for authentication:</html:p>
  <html:pre><![CDATA[ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBHRJsbKlE9QWIQnC1YQPHV8C6cIx32Fjju7VQaKI67TPPm+FySrbJPsM6j4zm9IobTCQ0YOtVmlvXYlRtKdHm0I= pkcs11:id=%62%31%39%32%66%32%33%31%32%66%65%36%66%33%64%37;token=ssh;manufacturer=STMicro;serial=0000000000000000%0D%04?module-path=/usr/lib64/pkcs11/libtpm2_pkcs11.so aram@silverleaf.local
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHwq6SeyHhRRtiMmsBABHYgwqaOwwgBZEMgrRfoSpvzz aram@horizon.local
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMRc0UWKrFpCv/EOUo2jpEQt+C/pa0tc1rUWKgjbKTp7 aram@edengate.local
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPsg+utDc9GRb/n91r0j5vFsn+gVYPawpEbaNCuIhYmE aram@z800.mgk.ro]]></html:pre>
</fr:mainmatter>
                </fr:tree>
                <fr:tree show-metadata="false">
                  <fr:frontmatter>
                    <fr:authors>
                      <fr:author>
                        <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
                      </fr:author>
                    </fr:authors>
                    <fr:date>
                      <fr:year>2025</fr:year>
                      <fr:month>7</fr:month>
                      <fr:day>15</fr:day>
                    </fr:date>
                    <fr:title text="Signing">Signing</fr:title>
                  </fr:frontmatter>
                  <fr:mainmatter>
                    <html:p>These are the public SSH keys (in <fr:link href="https://man.openbsd.org/ssh-keygen.1ALLOWED_SIGNERS" type="external"><html:code>allowed_signers</html:code></fr:link> format) that I use for <fr:link href="https://man.openbsd.org/ssh-keygen.1" type="external">signing</fr:link>:</html:p>
                    <html:pre>aram@mgk.ro ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMRc0UWKrFpCv/EOUo2jpEQt+C/pa0tc1rUWKgjbKTp7 aram@edengate.local</html:pre>
                  </fr:mainmatter>
                </fr:tree>
              </fr:mainmatter>
            </fr:tree>
            <fr:tree show-metadata="false">
              <fr:frontmatter>
                <fr:authors>
                  <fr:author>
                    <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
                  </fr:author>
                </fr:authors>
                <fr:date>
                  <fr:year>2025</fr:year>
                  <fr:month>7</fr:month>
                  <fr:day>15</fr:day>
                </fr:date>
                <fr:title text="Install">Install</fr:title>
              </fr:frontmatter>
              <fr:mainmatter><html:p>Run the following commands to populate <html:code>~/.ssh/authorized_keys</html:code> (see <fr:link href="/ssh.1" title="ssh(1)" uri="https://xw.is/ssh.1" display-uri="ssh.1" type="local">ssh(1)</fr:link>), creating it with necessary permissions if required:</html:p>
  <html:pre>
mkdir -p $HOME/.ssh
chmod 700 $HOME/.ssh
cat &lt;&lt;EOF &gt;&gt;$HOME/.ssh/authorized_keys
<![CDATA[ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBHRJsbKlE9QWIQnC1YQPHV8C6cIx32Fjju7VQaKI67TPPm+FySrbJPsM6j4zm9IobTCQ0YOtVmlvXYlRtKdHm0I= pkcs11:id=%62%31%39%32%66%32%33%31%32%66%65%36%66%33%64%37;token=ssh;manufacturer=STMicro;serial=0000000000000000%0D%04?module-path=/usr/lib64/pkcs11/libtpm2_pkcs11.so aram@silverleaf.local
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHwq6SeyHhRRtiMmsBABHYgwqaOwwgBZEMgrRfoSpvzz aram@horizon.local
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMRc0UWKrFpCv/EOUo2jpEQt+C/pa0tc1rUWKgjbKTp7 aram@edengate.local
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPsg+utDc9GRb/n91r0j5vFsn+gVYPawpEbaNCuIhYmE aram@z800.mgk.ro]]>
EOF
chmod 644 $HOME/.ssh/authorized_keys
sort -u -o $HOME/.ssh/authorized_keys $HOME/.ssh/authorized_keys</html:pre>
<html:p>These commands are idempotent and will preserve existing keys.</html:p></fr:mainmatter>
            </fr:tree>
            <fr:tree show-metadata="false">
              <fr:frontmatter>
                <fr:authors>
                  <fr:author>
                    <fr:link href="/aram/" title="Aram Hăvărneanu" uri="https://xw.is/aram/" display-uri="aram" type="local">Aram Hăvărneanu</fr:link>
                  </fr:author>
                </fr:authors>
                <fr:date>
                  <fr:year>2025</fr:year>
                  <fr:month>7</fr:month>
                  <fr:day>15</fr:day>
                </fr:date>
                <fr:title text="Macros">Macros</fr:title>
              </fr:frontmatter>
              <fr:mainmatter>
                <html:p>This page exports the <html:code><![CDATA[\ssh-keys]]></html:code> and <html:code><![CDATA[\ssh-keys-install]]></html:code> macros. To use them from other pages import this page with <html:code><![CDATA[\import{ssh-keys}]]></html:code>.</html:p>
              </fr:mainmatter>
            </fr:tree>
          </fr:mainmatter>
        </fr:tree>
      </fr:mainmatter>
    </fr:tree>
    <fr:tree show-metadata="false" hidden-when-empty="true">
      <fr:frontmatter>
        <fr:authors />
        <fr:title text="Contributions">Contributions</fr:title>
      </fr:frontmatter>
      <fr:mainmatter />
    </fr:tree>
  </fr:backmatter>
</fr:tree>
