Forum
No internet connection
  1. Home
  2. Training and Certification

Error in IoT-Project in Dev1

By Nicholas Teo Yong Yeow @nicholastyy_wg18
    2021-07-11 14:00:00.185Z

    In the Iot-Project course I built the image as shown in the video but I get this error when I get the logs. Can't figure out how to troubleshoot this and hope for some help on the matter

    Sun Jul 11 2021 09:48:48 GMT+0000 (Coordinated Universal Time) -- Connected to IoTHub
    Sun Jul 11 2021 09:48:48 GMT+0000 (Coordinated Universal Time) -- Subscribed to livingroom/temperature/1625996928
    Sun Jul 11 2021 09:58:30 GMT+0000 (Coordinated Universal Time) -- Received data from livingroom/temperature/1625996928: aaa
    Error adding data... error: relation "livingroom.temperature" does not exist
    at Connection.parseE (/app/node_modules/pg/lib/connection.js:614:13)
    at Connection.parseMessage (/app/node_modules/pg/lib/connection.js:413:19)
    at Socket. (/app/node_modules/pg/lib/connection.js:129:22)
    at Socket.emit (events.js:310:20)
    at addChunk (_stream_readable.js:286:12)
    at readableAddChunk (_stream_readable.js:268:9)
    at Socket.Readable.push (_stream_readable.js:209:10)
    at TCP.onStreamRead (internal/stream_base_commons.js:186:23)
    Sun Jul 11 2021 09:59:42 GMT+0000 (Coordinated Universal Time) -- Received data from livingroom/temperature/1625996928: 22
    Error adding data... error: relation "livingroom.temperature" does not exist
    at Connection.parseE (/app/node_modules/pg/lib/connection.js:614:13)
    at Connection.parseMessage (/app/node_modules/pg/lib/connection.js:413:19)
    at Socket. (/app/node_modules/pg/lib/connection.js:129:22)
    at Socket.emit (events.js:310:20)
    at addChunk (_stream_readable.js:286:12)
    at readableAddChunk (_stream_readable.js:268:9)
    at Socket.Readable.push (_stream_readable.js:209:10)
    at TCP.onStreamRead (internal/stream_base_commons.js:186:23)

    • 5 replies
    1. S
      @sk_chen
        2021-07-12 02:56:49.851Z

        Hi nicholastyy_wg18

        Make sure your number(1625996928) is generated through edge-mock-temperature, every one is different

        1. N

          Doesn't edge-mock-temperature only generate the double digit temperature values?

          This number (1625996928) is being generated here I think

          1. S
            @sk_chen
              2021-07-13 09:29:10.444Z

              Hi
              mqtt pushes data, but we have to distinguish that each student pushes it by himself, so a random number will be added to the mqtt topic to identify the student, and the random number will be displayed when running the edge temperature, please refer to the github instructions

              https://github.com/WISE-PaaS/IoT-Project

              1. N

                Hi, I checked the server deployment and found this error also

                C:\Users\Nicholas Teo>kubectl logs server-nicholas-teo-5c95756f8d-xv7fd
                yarn run v1.22.4
                $ node index.js
                Tue Jul 13 2021 09:10:13 GMT+0000 (Coordinated Universal Time) -- Server started on port 3000
                Error creating the table... error: role "groupFamily" does not exist
                at Connection.parseE (/app/node_modules/pg/lib/connection.js:614:13)
                at Connection.parseMessage (/app/node_modules/pg/lib/connection.js:413:19)
                at Socket. (/app/node_modules/pg/lib/connection.js:129:22)
                at Socket.emit (events.js:310:20)
                at addChunk (_stream_readable.js:286:12)
                at readableAddChunk (_stream_readable.js:268:9)
                at Socket.Readable.push (_stream_readable.js:209:10)
                at TCP.onStreamRead (internal/stream_base_commons.js:186:23)

                Could this be related to my problem? I looked at the github page and I think I did everything there already

                1. S@sk_chen
                    2021-07-13 10:01:58.582Z

                    Hi

                    i think you got it