Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

node / TCG (qemu) issues #403

Closed
fpapalardo opened this issue Oct 31, 2019 · 7 comments
Closed

node / TCG (qemu) issues #403

fpapalardo opened this issue Oct 31, 2019 · 7 comments
Assignees

Comments

@fpapalardo
Copy link

Trying to send logs to cloudwatch logs it's not possible to connect to cloudwatch logs. I tried 2 well-known frameworks and also I created manual logs using aws js sdk and I could get these logs from them:

{ NetworkingError: The value "4294967295" is invalid for option "family"
    at lookup (dns.js:113:11)
    at net.js:979:5
    at defaultTriggerAsyncIdScope (internal/async_hooks.js:294:19)
    at lookupAndConnect (net.js:978:3)
    at TLSSocket.Socket.connect (net.js:913:5)
    at Object.connect (_tls_wrap.js:1248:12)
    at Agent.createConnection (https.js:119:22)
    at Agent.createSocket (_http_agent.js:227:26)
    at Agent.addRequest (_http_agent.js:185:10)
    at new ClientRequest (_http_client.js:261:16)
  message: 'The value "4294967295" is invalid for option "family"',
  code: 'NetworkingError',
  region: 'us-west-1',
  hostname: 'logs.us-west-1.amazonaws.com',
  retryable: true,
  time: 2019-10-31T04:10:42.607Z }

This would suggest that it's not possible to connect outside the running process, create any REST request

@eyberg
Copy link
Contributor

eyberg commented Oct 31, 2019

do you have something I can toss to an engineer to repro? this looks like an overflow cause of your 4294967295

@eyberg
Copy link
Contributor

eyberg commented Oct 31, 2019

this is prob a nanos issue that needs investigation

@eyberg
Copy link
Contributor

eyberg commented Oct 31, 2019

nvr mind, was able to replicate, looking into it

➜  o  cat hi.js
const https = require('https');

https.get('https://api.nasa.gov/planetary/apod?api_key=DEMO_KEY', (resp) => {
  let data = '';

  // A chunk of data has been received.
  resp.on('data', (chunk) => {
    data += chunk;
  });

  // The whole response has been received. Print out the result.
  resp.on('end', () => {
    console.log(JSON.parse(data).explanation);
  });

}).on("error", (err) => {
  console.log("Error: " + err.message);
});
➜  o  ops load node_v11.5.0 -p 8083 -a hi.js
[node hi.js]
booting /Users/eyberg/.ops/images/node.img ...
assigned: 10.0.2.15
dns.js:113
    throw new ERR_INVALID_OPT_VALUE('family', family);
    ^

TypeError [ERR_INVALID_OPT_VALUE]: The value "4294967295" is invalid for option "family"
    at lookup (dns.js:113:11)
    at net.js:979:5
    at defaultTriggerAsyncIdScope (internal/async_hooks.js:294:19)
    at lookupAndConnect (net.js:978:3)
    at TLSSocket.Socket.connect (net.js:913:5)
    at Object.connect (_tls_wrap.js:1248:12)
    at Agent.createConnection (https.js:119:22)
    at Agent.createSocket (_http_agent.js:227:26)
    at Agent.addRequest (_http_agent.js:185:10)
    at new ClientRequest (_http_client.js:261:16)
exit status 3

@eyberg
Copy link
Contributor

eyberg commented Oct 31, 2019

appears we might be hitting this -> nodejs/node#19348 as it works as expected on t2 (xen) but not local qemu

➜  t  cat hi.js
var http = require('http');
http.createServer(function (req, res) {
    res.writeHead(200, {'Content-Type': 'text/plain'});
    a = undefined
    res.end((a >>> 0).toString(10));
}).listen(80, "0.0.0.0");
console.log('Server running at http://127.0.0.1:80/');

we might just monkey-patch node for now to work around this - still looking

@eyberg eyberg changed the title Running service can't connect to another services node / TCG issues Oct 31, 2019
@eyberg eyberg added the qemu label Nov 1, 2019
@eyberg eyberg changed the title node / TCG issues node / TCG (qemu) issues Nov 1, 2019
@eyberg
Copy link
Contributor

eyberg commented Nov 1, 2019

as mentioned in another tkt turning on hardware accel via '-x' gets past the tcg issue && also this particular pkg is missing libresolv which we can add w/the new node patch

@eyberg
Copy link
Contributor

eyberg commented Nov 5, 2019

#407

@eyberg
Copy link
Contributor

eyberg commented Apr 13, 2020

going to close this as we by default try to install latest qemu and warn the user if we find one that is too old causing this bug

@eyberg eyberg closed this as completed Apr 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants