So to connect to a screen session, I use <br><br>screen -x JNOS<br><br>To detach from a screen session, press CTRL A, release those and then hit D <br><br><br>Sent from ProtonMail mobile<br><br><br><br>-------- Original Message --------<br>On Oct 19, 2021, 18:37, Sky < sky@aa6ax.us> wrote:<blockquote class="protonmail_quote"><br><html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body>Precisely! Thank you.<div class=""><br class=""></div><div class="">I've never used 'screen' before, and had to install it, and I am finding is hard to decipher the command-line switches/args.</div><div class=""><br class=""></div><div class="">I launch with this command within the systemd script...</div><div class=""><br class=""></div><div class=""><font face="Andale Mono" class=""><span style="font-style: normal;" class="">screen -S jnos -Dm /jnos/startnos</span></font></div><div class=""><br class=""></div><div class="">...which works fine and launches my JNOS as a service. It runs fine and does everything it's supposed to. That was goal #1.</div><div class=""><br class=""></div><div class="">However, I don't know the switches to connect to the process via screens later on. I will continue reading the dox, but if you know this just right off the top of your head, it might save some time here. Do not go spend a lot of time yourself -- I should be able to read if I absolutely have to.</div><div class=""><br class=""></div><div class="">—Sky</div><div class=""><br class=""></div><div class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Oct 18, 2021, at 2:59 PM, debiani386 via nos-bbs <<a href="mailto:nos-bbs@lists.tapr.org" class="">nos-bbs@lists.tapr.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">My solution was to create a systemd script which launches JNOS in screen (as the JNOS system is remote and I am not the only one who monitors the JNOS console remotely).<br class=""></div><div class=""><br class=""></div><div class="">This is what I have, you can change it as needed:<br class=""></div><div class=""><br class=""></div><div class="">[Unit]<br class=""></div><div class="">Description=Jnos<br class=""></div><div class="">After=network.target<br class=""></div><div class=""><br class=""></div><div class="">[Service]<br class=""></div><div class="">Type=simple<br class=""></div><div class="">User=root<br class=""></div><div class="">WorkingDirectory=/home/jnos/jnos<br class=""></div><div class="">ExecStart=/usr/bin/screen -S JNOS -Dm /home/jnos/jnos/jnos<br class=""></div><div class="">ExecStop=/usr/bin/kill jnos<br class=""></div><div class=""><br class=""></div><div class="">[Install]<br class=""></div><div class="">WantedBy=multi-user.target<br class=""></div><div class=""><br class=""></div><div class="">HTH and 73, de KG7UJH<br class=""></div><div class="">Christopher Kelley<br class=""></div><div class=""><br class=""></div><div class="protonmail_signature_block"><div class="protonmail_signature_block-user protonmail_signature_block-empty"></div><div class="protonmail_signature_block-proton">Sent with <a rel="noopener noreferrer" href="https://protonmail.com/" target="_blank" class="">ProtonMail</a> Secure Email.</div></div><div class=""><br class=""></div><div class="protonmail_quote">
        ‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐<br class="">
        On Monday, October 18th, 2021 at 2:54 PM, Andrew Pepper <<a href="mailto:anpepper@gmail.com" class="">anpepper@gmail.com</a>> wrote:<br class="">
        <blockquote class="protonmail_quote" type="cite">
            <div dir="auto" class=""><div class="">I followed the raspberry pi3 how-to on this site. To automatically start jnos on say tty7 and if the machine is restarted everything fires back up.<div dir="auto" class="">Those instructions should work for any debian based systems.<br class=""><div dir="auto" class=""><a href="http://server1.nuge.com/~drg/jnos.html" rel="noreferrer nofollow noopener" target="_blank" class="">http://server1.nuge.com/~drg/jnos.html</a></div></div><div dir="auto" class=""><br class=""></div>Andrew, K1YMI<br class=""><br class=""><div class="gmail_quote"><div dir="ltr" class="">On Mon, Oct 18, 2021, 17:30 Sky via nos-bbs <<a href="mailto:nos-bbs@lists.tapr.org" rel="noreferrer nofollow noopener" target="_blank" class="">nos-bbs@lists.tapr.org</a>> wrote:<br class=""></div><blockquote style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex" class="gmail_quote"><div style="word-wrap:break-word;line-break:after-white-space" class="">Gosh, I should know this stuff, but I got deep into it and so far no solution, so let me ask if others have soled this problem already.<div class=""><br class=""></div><div class="">I want to automatically launch JNOS after a power failure.</div><div class=""><br class=""></div><div class="">At the moment I do this by going to the computer and bringing up <b class="">Terminal</b> and then launching JNOS in that session and I just leave it open. Works great until the power fails. If I am away or out of town, JNOS won't run again until I notice the failure and fire up the display and keyboard. (I do have an automated cron that notices the failure and emails me, but it can be several hours before I notice, and as I said, I may be out of town.)</div><div class=""><br class=""></div><div class="">So from crontab preferably I would like to launch JNOS and let it run indefinitely. But also I'd like to do it from Python because that's what I'm using as my base for writing additional JNOS support.</div><div class=""><br class=""></div><div class="">I know how to detect whether it is running already and all of that and then try to launch it if not already running, what I can't get is how to launch JNOS without Terminal. Meaning there is no 'environment' for it to run in. If I do that, it launches but immediately just exits. Nothing in syslog that I can find to help me know. I presume I have to have cron launch JNOS with some kind of environment specified, but so far I can't figure that out.</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><u class="">If someone has already solved this, I would prefer to know your solution, not necessarily to debug mine.</u></div><div class=""><br class=""></div><div class="">I'm not going to put the code here because you will be tempted to try to debug it. Just suffice it to say it does launch the process, gets a PID in return, but that process will exit without actually completing the JNOS launch. And I presume this is because JNOS needs an 'environment' to run in and cannot run by itself.</div><div class=""><br class=""></div><div class="">—Sky</div><br class=""><br class=""><div class="">
<div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; text-decoration: none; word-wrap: break-word; line-break: after-white-space;" dir="auto" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; text-decoration: none; word-wrap: break-word; line-break: after-white-space;" dir="auto" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; text-decoration: none; word-wrap: break-word; line-break: after-white-space;" dir="auto" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; text-decoration: none; word-wrap: break-word; line-break: after-white-space;" dir="auto" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word; line-break: after-white-space;" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word; line-break: after-white-space;" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word; line-break: after-white-space;" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word; line-break: after-white-space;" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word; line-break: after-white-space;" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word; line-break: after-white-space;" class=""><span style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; border-spacing: 0px;" class=""><div style="word-wrap:break-word;line-break:after-white-space" class=""><span style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-variant-east-asian: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; border-spacing: 0px;" class=""><div style="word-wrap:break-word;line-break:after-white-space" class=""><div class=""><div style="font-family:Helvetica" class="">- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -</div><div style="font-family:Helvetica" class="">"Sky" (Jim Schuyler)</div><div style="font-family:Helvetica" class=""><span style="text-align:-webkit-auto" class="">—</span>Amateur Radio AA6AX</div><div style="font-family:Helvetica" class=""><div style="font-family:Arial" class="">Online at <a rel="noreferrer nofollow noopener" target="_blank" href="https://aa6ax.us/" class="">aa6ax.us</a><span style="font-family:Helvetica;text-align:-webkit-auto" class=""> </span></div></div></div><div class=""><br class=""></div></div></span></div></span></div></div></div></div></div></div></div></div></div><br class=""></div><br class=""><br class="">
</div><br class=""></div>_______________________________________________<br class="">
nos-bbs mailing list<br class="">
<a rel="noreferrer nofollow noopener" target="_blank" href="mailto:nos-bbs@lists.tapr.org" class="">nos-bbs@lists.tapr.org</a><br class="">
<a target="_blank" rel="noreferrer nofollow noopener" href="http://lists.tapr.org/mailman/listinfo/nos-bbs_lists.tapr.org" class="">http://lists.tapr.org/mailman/listinfo/nos-bbs_lists.tapr.org</a><br class="">
</blockquote></div></div></div>

        </blockquote><br class="">
    </div>_______________________________________________<br class="">nos-bbs mailing list<br class=""><a href="mailto:nos-bbs@lists.tapr.org" class="">nos-bbs@lists.tapr.org</a><br class="">http://lists.tapr.org/mailman/listinfo/nos-bbs_lists.tapr.org<br class=""></div></blockquote></div><br class=""></div></body></html></div>