setting-up-chimera-linux.html 9.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <!DOCTYPE html><head><meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" /><meta name="keywords" content="GNU, Emacs, Libre Software, Hurd, Guile, Guix" /><meta name="description" content="GNUcode.me is a website focusing on libre software projects, especially the GNU project." /><link type="application/atom+xml" rel="alternate" title="GNUcode.me -- Feed" href="/feed.xml" /><a rel="me" href="https://fosstodon.org/@thegnuguy"></a><link type="text/css" href="css/footer.min.css" rel="stylesheet"></link><link type="text/css" href="css/header.min.css" rel="stylesheet"></link><link type="text/css" href="css/main.min.css" rel="stylesheet"></link><title>Setting up Chimera Linux — GNUcode.me</title></head><body><header><nav><ul><li><a href="index.html">GNUcode.me</a></li><li><a href="services.html">Services</a></li><li><a href="about.html">About</a></li><li><a href="business-ideas.html">Business-ideas</a></li></ul></nav></header><h1>Setting up Chimera Linux</h1><main><section class="basic-section-padding"><article><h3>by Joshua Branson — August 09, 2023</h3><div><p>My friend ownes a <a href="https://www.raptorcs.com/TALOSII/">Talos II</a>, and he wanted some help setting it up. We have
  2. decided on setting up <a href="https://chimera-linux.org/">Chimera Linux</a>. Since Chimera Linux is new, we also installed the guix package manager as well. This blog post today is more of documentation and less story telling. You have been warned.</p><h1>upgrading chimera linux</h1><pre><code>doas apk update
  3. doas apk upgrade</code></pre><h1>DONE Getting X applications and gdm to run on chimera</h1><p>All Talos II machines have trouble running X, when a discrete GPU is installed.
  4. Basically the Talos II has an on board GPU, which when combined with an AMD GPU,
  5. X does not know which GPU to use. <a href="https://wiki.raptorcs.com/wiki/Troubleshooting/GPU#Xorg_will_not_start_.2F_crashes_when_a_discrete_GPU_is_installed">click here</a> to read more on the raptor wiki.</p><p>I did have trouble getting my friend’s Talos II to start gdm and X, but an
  6. update to chimera linux fixed the gdm issue. The below sections are for others
  7. that are using a Talos II with an AMD GPU. You do need to configure X to
  8. disable the onboard GPU and/or tell GDM to select a GPU at runtime.</p><h2>raptor pdf user’s guide:</h2><p><a href="https://wiki.raptorcs.com/w/images/e/e3/T2P9D01_users_guide_version_1_0.pdf">https://wiki.raptorcs.com/w/images/e/e3/T2P9D01_users_guide_version_1_0.pdf</a></p><h3>raptor wiki ways to fix this</h3><ol><li>Tell GDM to ignore a GPU</li></ol><p>In this case ignore the crappy onboard GPU.</p><pre><code> lspci | grep VGA
  9. 0005:02:00.0 VGA compatible controller: ASPEED Technology, Inc. ASPEED Graphics Family (rev 41)
  10. 0030:01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon Pro WX 7100]
  11. cat /etc/udev/udev.conf
  12. # see udev.conf(5) for details
  13. #
  14. # udevd is also started in the initrd. When this file is modified you might
  15. # also want to rebuild the initrd, so that it will include the modified configuration.
  16. #udev_log=info
  17. #children_max=
  18. #exec_delay=
  19. #event_timeout=180
  20. #timeout_signal=SIGKILL
  21. #resolve_names=early
  22. TAG-=&quot;seat&quot;, ENV{ID_FOR_SEAT}==&quot;drm-pci-0005_02_00_0&quot;
  23. TAG-=&quot;seat&quot;, ENV{ID_FOR_SEAT}==&quot;graphics-pci-0005_02_00_0&quot;
  24. Do this to re-generate the initramfs.
  25. `doas apk fix linux-lts`</code></pre><ol><li><p>Xorg will not start / crashes when a discrete GPU is installed</p><p>We chose to do the workaround 2: select a desired GPU at runtime, which means
  26. that if we change the slot of the GPU, then we will have to re-create the Xorg
  27. configuration file.</p><pre><code>lspci | grep VGA
  28. 0005:02:00.0 VGA compatible controller: ASPEED Technology, Inc. ASPEED Graphics Family (rev 41)
  29. 0030:01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon Pro WX 7100]
  30. cat /etc/X11/xorg.conf.d/21-gpu-driver.conf
  31. # AST2500
  32. Section &quot;Device&quot;
  33. Identifier &quot;GPU0&quot;
  34. Driver &quot;modesetting&quot;
  35. BusID &quot;PCI:2@5:0:0&quot;
  36. VendorName &quot;ASpeed Corporation&quot;
  37. EndSection
  38. # WX7100
  39. Section &quot;Device&quot;
  40. Identifier &quot;GPU1&quot;
  41. Driver &quot;modesetting&quot; # or amdgpu if you have xf86-video-amdgpu installed
  42. BusID &quot;PCI:1@48:0:0&quot;
  43. VendorName &quot;AMD Corporation&quot;
  44. EndSection
  45. # this is absolutely necessary, it tells xorg which GPU to use for the screen
  46. Section &quot;Screen&quot;
  47. Identifier &quot;Screen0&quot;
  48. Device &quot;GPU1&quot;
  49. EndSection</code></pre></li><li><p>upgrade the openBMC bios/firmware and disable onboard GPU via</p><p>I decided not to do this one. It's way too complicated. See the raptor wiki if you don't believe me.</p></li></ol><h2>Where to find X logs</h2><p><em>var/log/gdm/greeter.log
  50. /var/lib/gdm</em>.local/share/xorg/Xorg.1.log</p><h2>toggling gdm to use X/wayland</h2><p>This does not appear to work.</p><pre><code>cat /etc/gdm/custom.conf | grep 'Wayland'
  51. #WaylandEnable=false
  52. WaylandEnable=true</code></pre><h2>DONE install icewm, and put that in ~/.xinitrc &amp; startx</h2><p>Originally this did not work, because X refused to start. But after I upgraded
  53. Chimera linux one day, it worked.</p><h1>Setting up Bitcoin knots/bitcoin core</h1><p>My friend is an avid bitcoin user. He wanted me to help him set up bitcoin on
  54. his Talos II. If possible, he wanted me to set up bitcoin-knots, which was
  55. forked from bitcoin-core.</p><h2>github repo for bitcoin-knots</h2><p>The github repo has lots of good information to help me out:</p><p><a href="https://bitcoinknots.org/#download">https://bitcoinknots.org/#download</a></p><p><a href="https://github.com/bitcoinknots/bitcoin">https://github.com/bitcoinknots/bitcoin</a></p><p><a href="https://github.com/bitcoinknots/bitcoin/tree/23.x-knots/doc">https://github.com/bitcoinknots/bitcoin/tree/23.x-knots/doc</a></p><p><a href="https://github.com/bitcoinknots/bitcoin/blob/23.x-knots/doc/build-unix.md">https://github.com/bitcoinknots/bitcoin/blob/23.x-knots/doc/build-unix.md</a></p><p><a href="https://github.com/bitcoinknots/bitcoin/blob/23.x-knots/doc/build-freebsd.md">https://github.com/bitcoinknots/bitcoin/blob/23.x-knots/doc/build-freebsd.md</a></p><p><a href="https://github.com/bitcoinknots/bitcoin/blob/23.x-knots/doc/dependencies.md">https://github.com/bitcoinknots/bitcoin/blob/23.x-knots/doc/dependencies.md</a></p><p>I can get help from webchat.freenode.net #bitcoin-dev</p><p>luke-jr says that I can compile bitcoin knots from source fairly easily.</p><p>download a release. Install dependencies:</p><p><a href="https://download.qt.io/official_releases/qt/">https://download.qt.io/official_releases/qt/</a></p><pre><code>doas apk add libevent </code></pre><p><code>./configure gmake &amp;&amp; gmake check &amp;&amp; gmake install</code></p><h2>NO Packaging bitcoin knots for chimera linux</h2><p>q66 is NOT ok with me packaging bitcoin-coin for chimera linux, because it
  56. depends on qt5, which is soon to be replaced by qt6. So why bother packaging
  57. qt5 when qt6 is soon to supplant it?</p><p>This is the documentation for packaging in chimera.</p><p><a href="https://github.com/chimera-linux/cports">https://github.com/chimera-linux/cports</a>
  58. <a href="https://github.com/chimera-linux/chimerautils">https://github.com/chimera-linux/chimerautils</a></p><h2>Alternatively I can package bitcoin knots for guix and install</h2><p>guix on chimera linux. And guix already has qt packaged. Do they have
  59. 5.15.2 packaged? Why yes they do: They have qtbase version 5.15.8.</p><p>I have not packaged bitcoin-knots for guix yet. Instead my friend decided to
  60. run bitcoin-core.</p><h2>DONE Or I can just install bitcoin-core from guix and run that</h2><h1>guix stuff</h1><h2>installing guix on chimera linux</h2><p>You can install guix via these commands:</p><pre><code>wget https://git.savannah.gnu.org/cgit/guix.git/plain/etc/guix-install.sh
  61. doas chmod u+x guix-install.sh
  62. doas ./guix-install.sh</code></pre><p>Add in the export line so I can use the guix binaries.</p><pre><code>cat ~/.profile
  63. #!/usr/bin/bash
  64. export GUIX_LOCPATH=&quot;$HOME/.guix-profile/lib/locale&quot;
  65. gnome-shell --wayland</code></pre><h2>starting the guix daemon manually</h2><pre><code> ~root/.config/guix/current/bin/guix-daemon &amp;#x2013;build-users-group=guixbuild</code></pre><h2>set up guix daemon via dinit</h2><pre><code>cat /etc/dinit.d/guix-daemon
  66. # guix-daemon service
  67. type = process
  68. # run this command as root
  69. run-as = root
  70. command = /root/.config/guix/current/bin/guix-daemon --build-users-group=guixbuild
  71. # depends-on = bar
  72. # waits-for = baz
  73. # uncomment this next line once you know this works
  74. # before = login.target
  75. before = network.target</code></pre><p><a href="https://davmac.org/projects/dinit/man-pages-html/dinitcheck.8.html">https://davmac.org/projects/dinit/man-pages-html/dinitcheck.8.html</a></p><p><a href="https://davmac.org/projects/dinit/man-pages-html/dinit-service.5.html">https://davmac.org/projects/dinit/man-pages-html/dinit-service.5.html</a></p><p>So if you cannot get the daemon to autostart, then this will</p><p><code>doas dinitctl start guix-daemon</code> work.</p></div></article></section></main><footer><p>© 2020 Joshua Branson. The text on this site is free culture under the Creative Commons Attribution Share-Alike 4.0 International license.</p><p>This website is build with Haunt, a static site generator written in Guile Scheme. Source code is <a href="https://notabug.org/jbranso/gnucode.me">available.</a></p><p>The color theme of this website is based off of the famous <a href="#3f3f3f" target="_blank">zenburn</a> theme.</p></footer></body>