marcopovitch / sl2influxdb

Fetch seedlink data and store them into InfluxDB
30 stars 13 forks source link

ERROR: cannot open state file: [Errno 2] No such file or directory: 'eost.statefile.txt' #7

Closed vlauciani closed 5 years ago

vlauciani commented 5 years ago

Hi

Run the project with:

$ docker-compose up -d grafana

looking the log, I receive this error:

$ docker-compose logs -f sl2generic
Attaching to sl2influxdb_sl2generic_1
sl2generic_1         | + exec
sl2generic_1         | + set -e
sl2generic_1         | + EXTRA=
sl2generic_1         | + '[' -z eost ']'
sl2generic_1         | + '[' -z '"yes"' ']'
sl2generic_1         | + EXTRA=' --recover'
sl2generic_1         | + '[' -z '' ']'
sl2generic_1         | + EXTRA=' --recover'
sl2generic_1         | + '[' -z '' ']'
sl2generic_1         | + EXTRA=' --recover'
sl2generic_1         | + '[' -z 1 ']'
sl2generic_1         | + '[' -z 192.168.2.10 ']'
sl2generic_1         | + '[' -z http://webservices.ingv.it ']'
sl2generic_1         | + pid=0
sl2generic_1         | + trap 'kill ${!}; term_handler' SIGTERM
sl2generic_1         | + cd /data
sl2generic_1         | + pid=7
sl2generic_1         | + true
sl2generic_1         | + seedlink2influxdb --dbserver influxdb --dbport 8086 --slserver 192.168.2.10 --fdsnserver http://webservices.ingv.it --streams '[('\''MN'\'','\''.*'\'','\''(SHZ|EHZ|HHZ)'\'','\''.*'\'')]' --db eost --keep 1 --recover
sl2generic_1         | + wait 8
sl2generic_1         | + tail -f /dev/null
                       2019-02-28 10:05:20  obspy.clients.seedlink [192.168.2.10:18000]: ERROR: cannot open state file: [Errno 2] No such file or directory: 'eost.statefile.txt'

what does it mean?

marcopovitch commented 5 years ago

If you stops and restarts sl2influxd later on, the data acquisition will restart from the state file eost.statefile.txt (sorry hardcoded filename) which keeps the latest id of the mseed packed received. This behavior is related to --recover on the command line.

Does it prevent sl2influxdb_sl2generic_1 to start ? (I don't think so ... then I should remove the corresponding message).

vlauciani commented 5 years ago

If I understand correctly, this "error" appears only "first time"; If I stop and start this message disappear.

marcopovitch commented 5 years ago

Thats's right. When stopping the state file is recorded (if --recover is enabled). I definitely have to remove the "ERROR" log message which is a little bit frightening.