Code Monkey home page Code Monkey logo

Comments (4)

BjarniRunar avatar BjarniRunar commented on August 17, 2024

Thanks for reporting this!

After giving it a fair bit of thought, I've decided this is a "wontfix" - pagekitec constantly (re)creating that file strikes me as potentially bad behavior, and not really necessary. Outside processes deleting the status file is no more pagekitec's problem than something deleting a pidfile or logfile - Unix daemons generally don't reopen and recreate such files unless they receive a signal explicitly asking them to.

Note that even if you remove the file, pagekitec still has an open file descriptor and the OS will allow it to keep writing to it, fprintf wouldn't have returned an error anyway. Ignoring errors there is deliberate - even if I caught an error, there's no obvious thing that can be done about it except just retry later, which is what the app already does.

from libpagekite.

karlp avatar karlp commented on August 17, 2024

10:52 BjarniRunar: hving more real world instances of #76 btw
10:53 the file is in /tmp, and I suspect it might get opened "too early" in boot, and before tmpfs is mounted there?
10:53 just a theory
10:53 but it's making for some wonky diags :|
11:09 <@BjarniRunar> That sounds plausible
11:10 <@BjarniRunar> If it's a problem we just fix it :) I didn't believe it was a problem but you are convincing me.
11:12 so the solution is "more systemd" to get boot deps, (iff that's the case) or just to keep rewriting it....

from libpagekite.

karlp avatar karlp commented on August 17, 2024

JUst been looking at working around this, and I saw that the status file was written, but then later wasn't there. presumably one instance, or I saw it while it was weirdly mounted? Tryign to get more log of it.

Update: I've got the log since boot, and it only shows one pk instance, but one time in this boot, I had "ls" show me the file existed, and now it doesn't :|

root@eg-0366BD:/# ls /tmp/remake*
et-remote.status.json  hwc.mlifter.json
root@eg-0366BD:/
# later...
root@eg-0366BD:/# ls -l /tmp/remake.d/
-rw-r--r--    1 root     root          2651 Oct 30 15:02 hwc.mlifter.json
root@eg-0366BD:/#

from libpagekite.

karlp avatar karlp commented on August 17, 2024

log

root@eg-0366BD:~# logread | grep remote
Fri Oct 30 14:59:15 2020 daemon.info monit[1199]: 'et-remote' monitor on user request
Fri Oct 30 14:59:16 2020 user.notice et-remote: tid=77f1ce84; ll=0; msg=Initialized et-remote manager v0.91.200718C/0.91.200718C (using 1775121 bytes)
Fri Oct 30 14:59:17 2020 user.err et-remote: tid=77f1ce84; ll=1; msg=pkm_lookup_and_add_frontend: getaddrinfo(fe6_091c.myetactica.com, 443) failed: Name does not resolve
Fri Oct 30 14:59:17 2020 user.notice et-remote: tid=77f1ce84; ll=2; msg=Starting manager in new thread
Fri Oct 30 14:59:17 2020 user.notice et-remote: tid=779ddd74; ll=3; msg=Tick!  [repeating=yes, next=16, status=10, tunnels=0, v=0.91.200718C]
Fri Oct 30 14:59:18 2020 user.err et-remote: tid=779bad74; ll=4; msg=pkm_lookup_and_add_frontend: getaddrinfo(fe6_091c.myetactica.com, 443) failed: Name does not resolve
Fri Oct 30 14:59:18 2020 user.notice et-remote: tid=779bad74; ll=5; msg=Connecting to [185.112.146.199]:443 (session=new, in DNS)
Fri Oct 30 14:59:24 2020 user.notice et-remote: tid=779bad74; ll=6; msg=7: TLSv1.2 connection established: ECDHE-RSA-CHACHA20-POLY1305 TLSv1.2 Kx=ECDH Au=RSA Enc=CHACHA20/POLY1305(256) Mac=AEAD
Fri Oct 30 14:59:24 2020 user.notice et-remote: tid=779bad74; ll=7; msg=Connecting to [185.112.146.199]:443 (session=5f9c2a4c:dfc606f460440662bf20c53bf35b572302dac068, in DNS)
Fri Oct 30 14:59:27 2020 daemon.info monit[1199]: 'et-remote' monitor action done
Fri Oct 30 14:59:27 2020 user.notice et-remote-monitor[2626]: Monitoring /tmp/remake.d/et-remote.status.json, for LED: eg200:red:etactica
Fri Oct 30 14:59:27 2020 user.notice et-remote: tid=779bad74; ll=8; msg=7: TLSv1.2 connection established: ECDHE-RSA-CHACHA20-POLY1305 TLSv1.2 Kx=ECDH Au=RSA Enc=CHACHA20/POLY1305(256) Mac=AEAD
Fri Oct 30 14:59:27 2020 user.notice et-remote: tid=779bad74; ll=9; msg=7: Connected!
Fri Oct 30 14:59:30 2020 daemon.info monit[1199]: 'et-remote' monitor on user request
Fri Oct 30 14:59:30 2020 daemon.info monit[1199]: 'et-remote' monitor action done
Fri Oct 30 14:59:33 2020 user.notice et-remote: tid=779ddd74; ll=a; msg=Tick!  [repeating=yes, next=21, status=40, tunnels=1, v=0.91.200718C]
Fri Oct 30 14:59:54 2020 user.notice et-remote: tid=779ddd74; ll=b; msg=Tick!  [repeating=yes, next=28, status=40, tunnels=1, v=0.91.200718C]
Fri Oct 30 14:59:55 2020 user.err et-remote: tid=779bad74; ll=c; msg=pkm_lookup_and_add_frontend: getaddrinfo(fe6_091c.myetactica.com, 443) failed: Name does not resolve
Fri Oct 30 14:59:59 2020 daemon.info monit[1199]: 'et-remote' monitor on user request
Fri Oct 30 15:00:00 2020 daemon.info monit[1199]: 'et-remote' monitor action done
Fri Oct 30 15:00:23 2020 user.notice et-remote: tid=779ddd74; ll=d; msg=Tick!  [repeating=yes, next=37, status=40, tunnels=1, v=0.91.200718C]
Fri Oct 30 15:00:23 2020 user.err et-remote: tid=77997d74; ll=e; msg=pkm_lookup_and_add_frontend: getaddrinfo(fe6_091c.myetactica.com, 443) failed: Name does not resolve
Fri Oct 30 15:01:00 2020 user.notice et-remote: tid=779ddd74; ll=f; msg=Tick!  [repeating=yes, next=49, status=40, tunnels=1, v=0.91.200718C]
Fri Oct 30 15:01:00 2020 user.err et-remote: tid=779bad74; ll=10; msg=pkm_lookup_and_add_frontend: getaddrinfo(fe6_091c.myetactica.com, 443) failed: Name does not resolve
Fri Oct 30 15:01:49 2020 user.notice et-remote: tid=779ddd74; ll=11; msg=Tick!  [repeating=yes, next=65, status=40, tunnels=1, v=0.91.200718C]
Fri Oct 30 15:01:49 2020 user.err et-remote: tid=77997d74; ll=12; msg=pkm_lookup_and_add_frontend: getaddrinfo(fe6_091c.myetactica.com, 443) failed: Name does not resolve
Fri Oct 30 15:01:54 2020 daemon.err uhttpd[1181]: luci: accepted login on /home/wizard/et-remote for root from 192.168.88.210
Fri Oct 30 15:02:54 2020 user.notice et-remote: tid=779ddd74; ll=13; msg=Tick!  [repeating=yes, next=86, status=40, tunnels=1, v=0.91.200718C]
Fri Oct 30 15:02:54 2020 user.err et-remote: tid=779bad74; ll=14; msg=pkm_lookup_and_add_frontend: getaddrinfo(fe6_091c.myetactica.com, 443) failed: Name does not resolve
Fri Oct 30 15:04:20 2020 user.notice et-remote: tid=779ddd74; ll=15; msg=Tick!  [repeating=yes, next=114, status=40, tunnels=1, v=0.91.200718C]
Fri Oct 30 15:04:20 2020 user.err et-remote: tid=77997d74; ll=16; msg=pkm_lookup_and_add_frontend: getaddrinfo(fe6_091c.myetactica.com, 443) failed: Name does not resolve
Fri Oct 30 15:06:14 2020 user.notice et-remote: tid=779ddd74; ll=17; msg=Tick!  [repeating=yes, next=152, status=40, tunnels=1, v=0.91.200718C]
Fri Oct 30 15:06:16 2020 user.err et-remote: tid=779bad74; ll=18; msg=pkm_lookup_and_add_frontend: getaddrinfo(fe6_091c.myetactica.com, 443) failed: Name does not resolve
root@eg-0366BD:~# 

Command line

# pgrep -lfa pagekite
2627 pagekitec -s -a et-remote -w myetactica.com -Y json:/tmp/remake.d/et-remote.status.json 80 http XXXX.myetactica.com 0 MYPASSWORD 22 raw-22 XXXX.myetactica.com 0 MYPASSWORD 8083 websocket-8083 XXXX.myetactica.com 0 MYPASSWORD

from libpagekite.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.