plan9.txt (5983B) [raw]
1 == Plan 9 Journal == 2 3 tags: plan9 4 5 My journey in installing and using the 9front fork of plan9 on 6 bare metal hardware (an old Thinkpad X220). Mostly just musings 7 and intermittent problem solving. Mildly interesting at best. 8 9 [Thu Mar 24 02:54:53 EDT 2022] 10 11 This is my third time booting this system. Still can't get 12 wifi to work. There's a message at boot about missing firmware. 13 Something like /lib/firmware/iwn-6005 maybe? Need to check to 14 see if theres proprietary blobs I'm missing... 15 16 Writing in acme(1) of course. It's maybe the most familiar 17 interface to the system (from my time poking around plan9port). 18 19 Goals for tonight: 20 21 - read intro(1) and linked pages 22 23 My date is wrong by 4hr exactly. Wonder if there's an ntp equivalent? 24 It's showing the UTC time as EDT, but when I run `date -u` it's got 25 the wrong GMT... hm. Probably should set my timezone to UTC and see 26 if that helps on reboot? 27 28 ... 29 30 Found $home/lib/profile. Realized $path doesn't exist. Just a series 31 of bind mounts into /bin . Why not? One mechanism that works. Let the 32 kernel search the union directory... 33 34 ... 35 36 Figured out my wireless issues -- I was right! I need firmware. Found 37 the relevant portion in plan9.ini(8): 38 39 iwl Intel Wireless WiFi Link mini PCI-Express adapters 40 require firmware from 41 http://firmware.openbsd.org/firmware/*/iwn-firmware*.tgz 42 to be present on attach in /lib/firmware or /boot. 43 44 Now just to figure out how to get the drivers on a thumbdrive... maybe 45 it'd be easier to reboot with ethernet plugged in first. 46 47 48 [Fri Mar 25 01:04:01 EDT 2022] 49 50 I booted tonight with ethernet connected. Time still wrong. But we 51 have webfs(4)! 52 53 Things automagically worked--I was able to use mothra(1) to connect 54 to 9front.org, so that felt great. 55 56 The next logical step seemed to be to leave the system using ssh(1). 57 First take failed. Maybe factotum(4) isn't running? 58 59 Looking for answers here: 60 61 https://pspodcasting.net/dan/blog/2019/plan9_desktop.html 62 63 Hm seems it should just work. Why do I get the following? 64 65 term% ssh <user>@sdf.org 66 ssh: read1: eof 67 68 69 [Sat Mar 26 02:27:37 EDT 2022] 70 71 Another day another boot. I put /etc/firmware/iwn* from my OpenBSD 72 install on a USB and successfully got it to mount on 9front (not 73 hard--just plug and check /shr)... but even with the firmware in 74 /lib/firmware it didn't work! hmm maybe I'll copy to /boot too? 75 76 At least the desktop guide above taught me about /dev/kmesg! I 77 no longer have to remember what it said at boot time :) 78 79 [Mon Apr 11 03:35:57 EDT 2022] 80 81 Been a hot sec. Life got busy. Went on a company trip to Asheville, 82 NC and then a bachelor party in Vegas. Caught a stomach bug and 83 ended up spending most of the party in the hotel room. Still a story, 84 I guess. Just not the one I expected to be telling. 85 86 Anyways, I'm not quite sure where I left off. src/net.sh and src/res.sh 87 both worked so I was up, fullscreen, and on wifi in about 3 min. 88 89 Maybe I'll try to take a whack at ircrc(1) or email? Probably good to get 90 SSH up too... 91 92 end of night update: ircrc(1) worked great, no issues! ssh(1) still 93 not working. I checked the server logs and it said "unable to negotiate, 94 client offered: ssh-rsa", so I wonder if the client's cipher's are 95 too old? The 9front fqa says that it supports chacha20-poly1305, which 96 I think openssh should support on the server side... so why is the 97 handshake failing? unclear. 98 99 maybe I'll ask in #cat-v on IRC next time I boot :) 100 101 Some other things I tried: 102 103 1. Creating a SSH key (as documented in rsa(8)): 104 105 term% auth/rsagen -t 'service=ssh' >ssh.key 106 term% cat ssh.key >/mnt/factotum/ctl 107 term% ssh ajk@sdf.org 108 ssh: read1: eof 109 110 That should have added it to factotum(4) for retrieval. hm.. I mean 111 obviously the SSH server doesn't expect the key, but it shows that it's 112 not like ssh(1) is keeling over because of lack of key (I don't think.). 113 114 [Tue Apr 12 03:27:55 EDT 2022] 115 116 I did it! At long last, a working ssh(1). 117 118 I browsed the mailing list for a while and finally stumbled upon 119 this patch [1] that linked to the fact that in 2021-09 openssh 120 deprecated the ssh-rsa cipher (which from the sshd logs was what 121 I was offering...). 122 123 I'm not sure _why_ this patch didn't seem to make it into my install, 124 but sure enough I was able to do a system update and rebuild from 125 source and my new ssh(1) works out of the box! (I double checked and 126 the patch is indeed applied). So the fix was: 127 128 term% sysupdate 129 term% cd / 130 term% . /sys/lib/rootstub 131 term% cd /sys/src 132 term% mk install 133 134 As described in the fqa: http://fqa.9front.org/fqa5.html#5.1 135 136 [1]: https://inbox.vuxu.org/9front/CD1ED7F51E72A0050786E39FADF6EBFE@felloff.net/ 137 138 139 [Thu Apr 14 02:46:06 EDT 2022] 140 141 Tonight's goal: move this blog to the interwebs. Up until now 142 it's lived on this thinkpad as /usr/glenda/notes.txt, but I 143 (1) want to back it up and (2) want to share it in case it 144 helps anyone else! 145 146 Now that I have ssh(1) working, and given that 9front recently 147 added git(1), it should be pretty trivial to publish to my 148 gopherhole, just add it to the repo and commit and push! 149 150 I had to first generate an ssh key as listed in rsa(8) and add 151 it to factotum(4) so that I could clone via ssh: 152 153 % auth/rsagen -t 'service=ssh role=client' > ssh.key 154 % cat ssh.key >/mnt/factotum/ctl 155 % auth/rsa2ssh ssh.key # copy to clipboard, add to authorized_keys 156 157 Then: 158 159 % git/clone git@alexkarle.com:alexkarle.com akcom 160 % cd akcom 161 % mv /usr/glenda/notes.txt gopher/notes/all/plan9.txt 162 % git/commit gopher/notes/all/plan9.txt 163 <do the weird dance with 9term in blue hold mode> 164 % git/push 165 166 By the "weird dance" I mean: 167 168 1. Type my commit message 169 2. Type CTRL-D and newline 170 3. Hit escape? 171 172 Whacky. 173 174 I couldn't get git/diff <sha> to show the diff, so instead I checked 175 my diff with git/export HEAD, which worked great. 176 177 Oh and I put my git config in $home/lib/git/config (name/email). 178 179 The date is still 4hr off, so sourcehut rendered the commit as "3hr in 180 the future" :) whoops!