-
Notifications
You must be signed in to change notification settings - Fork 9
Description
Hi,
I'm trying to use your module to manage several proxmox servers and I get an error when getting info from more than one of them. If I do:
function searchDumps(host, user, type, password){
px = new proxmox(host, user, type, password);
px.get('/nodes', function(data){
px.get('/nodes/' + data[0].node + '/storage/backup/content', function(data){
data.forEach(function(item, index){
console.log(item);
})
});
});
}
var server1 = new searchDumps('server1', 'root', 'pam', 'XXXXXXXXXXXX');
var server2 = new searchDumps('server2', 'root', 'pam', 'YYYYYYYYYYYY');
`
the process hangs with an error:
events.js:160
throw er; // Unhandled 'error' event
^
Error: socket hang up
at createHangUpError (_http_client.js:252:15)
at TLSSocket.socketOnEnd (_http_client.js:344:23)
at emitNone (events.js:91:20)
at TLSSocket.emit (events.js:185:7)
at endReadableNT (_stream_readable.js:934:12)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
at process._tickCallback (internal/process/next_tick.js:98:9)
I suppose the system tries to send calls to the wrong server or overwrites its own login information to the proxmox server...
If I comment first or second call, it goes fine. It's just using 2 servers at the same time.
Do you think that could be solved easily?