-
-
Notifications
You must be signed in to change notification settings - Fork 878
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
Undefined offset: 1 #1880
Comments
Can you get me the SSH logs? You can get them by doing Thanks! |
Attaching SSH log right after
|
I also have to mention that this is long running script. However it produces this error only for 1 out many linux boxes. |
Out of curiosity, what does I created a branch on my own fork of the phpseclib repo that makes the error message a little more useful here: That said, assuming that this is all correct then you should probably look at the server logs. Like enable verbose logging on the server and see what the server logs are saying. Normally I do that by doing |
@terrafrost ty for reply. Yes you are right it's a timeout and execution maches setTimeout($seconds) |
Correct. Per your logs it's timing out before phpseclib has even had a chance to send the command. So the way SSH2 works is... you, the client, open up a channel. Once the server confirms that the channel has been opened you, the client, send an "exec" channel request with the command you're wanting executed. The server isn't even responding with the confirmation that the channel has been opened so phpseclib is error'ing out before it would normally send the command. |
Ok that makes sense. Anyways I don't care about error message anymore as I know what this means. Thank you for all the help |
@terrafrost I used your suggestion and did Do you have anything to suggest/recommend? On top of that I can mention that I'm running |
idk a ton about the internals of OpenSSH / Linux's PAM. I've posted your question on the [email protected] mailing list to see if the people there might have some insights. It could be interesting to see more of the logs as well. Like where it's opening the channel. The screenshot you posted is just showing the key exchange debug info. Like phpseclib, by default, will time out after 10s, so there's prob still some time consuming stuff going on outside of the screenshot that you sent. |
@terrafrost thank you for helping out. It's super easy for me to reproduce this. I get same thing in max 20 tries. |
Haven't gotten any responses from my email yet but I did a Google search for |
Hmm based on that thread I also have to mention that this hang-up takes exactly 9-10 seconds. And changing phpseclib timeout doesn't change anything. |
Hey there. I'm getting this error from one of the linux machine only.
Happens on this line:
https://github.com/phpseclib/phpseclib/blob/3.0/phpseclib/Net/SSH2.php#L4328
Any help would be highly appreciated.
The text was updated successfully, but these errors were encountered: