pi@blackknight:~ $ cat /lib/systemd/system/door_database.service [Unit] Description=Door Database Reader After=multi-user.target [Service] Type=idle ExecStart=/usr/bin/python3 /home/pi/apribot.py WorkingDirectory=/home/pi [Install] WantedBy=multi-user.target pi@blackknight:~ $ cat /lib/systemd/system/door_rfid_reader.service [Unit] Description=Door RFID Reader After=multi-user.target [Service] Type=idle ExecStart=/usr/bin/python /home/pi/doorlock.py WorkingDirectory=/home/pi [Install] WantedBy=multi-user.target pi@blackknight:~ $ pi@blackknight:~ $ journalctl -u door_database -- Logs begin at Thu 2016-11-03 17:16:43 UTC, end at Fri 2018-03-23 01:02:06 UTC. -- Mar 23 01:00:08 blackknight systemd[1]: Started Door Database Reader. Mar 23 01:00:11 blackknight python3[491]: ########################### requesting member data ############################ Mar 23 01:00:11 blackknight python3[491]: Traceback (most recent call last): Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/urllib/request.py", line 1254, in do_open Mar 23 01:00:11 blackknight python3[491]: h.request(req.get_method(), req.selector, req.data, headers) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/http/client.py", line 1107, in request Mar 23 01:00:11 blackknight python3[491]: self._send_request(method, url, body, headers) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/http/client.py", line 1152, in _send_request Mar 23 01:00:11 blackknight python3[491]: self.endheaders(body) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/http/client.py", line 1103, in endheaders Mar 23 01:00:11 blackknight python3[491]: self._send_output(message_body) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/http/client.py", line 934, in _send_output Mar 23 01:00:11 blackknight python3[491]: self.send(msg) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/http/client.py", line 877, in send Mar 23 01:00:11 blackknight python3[491]: self.connect() Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/http/client.py", line 1253, in connect Mar 23 01:00:11 blackknight python3[491]: super().connect() Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/http/client.py", line 849, in connect Mar 23 01:00:11 blackknight python3[491]: (self.host,self.port), self.timeout, self.source_address) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/socket.py", line 694, in create_connection Mar 23 01:00:11 blackknight python3[491]: for res in getaddrinfo(host, port, 0, SOCK_STREAM): Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/socket.py", line 733, in getaddrinfo Mar 23 01:00:11 blackknight python3[491]: for res in _socket.getaddrinfo(host, port, family, type, proto, flags): Mar 23 01:00:11 blackknight python3[491]: socket.gaierror: [Errno -3] Temporary failure in name resolution Mar 23 01:00:11 blackknight python3[491]: During handling of the above exception, another exception occurred: Mar 23 01:00:11 blackknight python3[491]: Traceback (most recent call last): Mar 23 01:00:11 blackknight python3[491]: File "/home/pi/apribot.py", line 352, in Mar 23 01:00:11 blackknight python3[491]: api.authenticate_with_contact_credentials("chadselish@gmail.com", "applehack!") Mar 23 01:00:11 blackknight python3[491]: File "/home/pi/apribot.py", line 79, in authenticate_with_contact_credentials Mar 23 01:00:11 blackknight python3[491]: response = urllib.request.urlopen(request) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/urllib/request.py", line 163, in urlopen Mar 23 01:00:11 blackknight python3[491]: return opener.open(url, data, timeout) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/urllib/request.py", line 466, in open Mar 23 01:00:11 blackknight python3[491]: response = self._open(req, data) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/urllib/request.py", line 484, in _open Mar 23 01:00:11 blackknight python3[491]: '_open', req) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/urllib/request.py", line 444, in _call_chain Mar 23 01:00:11 blackknight python3[491]: result = func(*args) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/urllib/request.py", line 1297, in https_open Mar 23 01:00:11 blackknight python3[491]: context=self._context, check_hostname=self._check_hostname) Mar 23 01:00:11 blackknight python3[491]: File "/usr/lib/python3.5/urllib/request.py", line 1256, in do_open Mar 23 01:00:11 blackknight python3[491]: raise URLError(err) Mar 23 01:00:11 blackknight python3[491]: urllib.error.URLError: Mar 23 01:00:11 blackknight systemd[1]: door_database.service: Main process exited, code=exited, status=1/FAILURE Mar 23 01:00:11 blackknight systemd[1]: door_database.service: Unit entered failed state. Mar 23 01:00:11 blackknight systemd[1]: door_database.service: Failed with result 'exit-code'. Mar 23 01:01:56 blackknight systemd[1]: Started Door Database Reader.